20170928_jeffrey - silenceuncrio/diary GitHub Wiki
review
來把之前的進度先 commit
異動的部分都落在 meta-proscend/conf/distro
資料夾
➜ distro git:(develop) ✗ pwd
/home/jeffrey/M300_git/M300/meta-proscend/conf/distro
異動的摘要如下
➜ distro git:(develop) ✗ git status
On branch develop
Your branch is up-to-date with 'origin/develop'.
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git checkout -- <file>..." to discard changes in working directory)
modified: include/proscend-base.inc
modified: planet-m300.conf
modified: proscend-m300.conf
Untracked files:
(use "git add <file>..." to include in what will be committed)
include/image_emmc.inc
include/image_nandflash.inc
proscend-m300e.conf
no changes added to commit (use "git add" and/or "git commit -a")
目前的 machine configuration 有兩個
- m300.conf
- m300e.conf
distribution configuration 有三個
- proscend-m300.conf
- proscend-m300e.conf
- planet-m300.conf
利用 proenv.sh 連動 local.conf
有三種方式
- source proenv.sh m300 proscend-m300
- machine configuration =
meta-proscend/conf/machine/m300.conf
- distribution configuration =
meta-proscend/conf/distro/proscend-m300.conf
- machine configuration =
- source proenv.sh m300 planet-m300
- machine configuration =
meta-proscend/conf/machine/m300.conf
- distribution configuration =
meta-proscend/conf/distro/planet-m300.conf
- machine configuration =
- source proenv.sh m300e proscend-m300e
- machine configuration =
meta-proscend/conf/machine/m300e.conf
- distribution configuration =
meta-proscend/conf/distro/proscend-m300.conf
- machine configuration =
distribution files 共用的 file 為 meta-proscend/conf/distro/include/proscend-base.inc
我需要把不屬於共用的部分先從 proscend-base.inc
抽出來
diff --git a/meta-proscend/conf/distro/include/proscend-base.inc b/meta-proscend/conf/distro/include/proscend-base.inc
index 2570123..3052540 100644
--- a/meta-proscend/conf/distro/include/proscend-base.inc
+++ b/meta-proscend/conf/distro/include/proscend-base.inc
@@ -11,8 +11,6 @@ include conf/distro/include/fsl-imx-preferred-env.inc
NO_RECOMMENDATIONS = "1"
ENABLE_BINARY_LOCALE_GENERATION = "0"
-IMAGE_FSTYPES += "nandflash"
-
#MKLIBS_OPTIMIZED_IMAGES ?= "core-image-minimal"
DISTRO_FEATURES_LIBC = " \
@@ -111,5 +109,3 @@ EXTERNALSRC_pn-prosrc = "${BSPDIR}/proscend"
EXTERNALSRC_BUILD_pn-prosrc = "${BSPDIR}/proscend"
ACCEPT_FSL_EULA = ""
-
-UBOOT_CONFIG = "nand"
meta-proscend/conf/distro/proscend-m300.conf
異動如下
diff --git a/meta-proscend/conf/distro/proscend-m300.conf b/meta-proscend/conf/distro/proscend-m300.conf
index 5481f9e..b5bb70c 100644
--- a/meta-proscend/conf/distro/proscend-m300.conf
+++ b/meta-proscend/conf/distro/proscend-m300.conf
@@ -1,4 +1,5 @@
include conf/distro/include/proscend-base.inc
+include conf/distro/include/image_nandflash.inc
DISTRO = "proscend-m300"
meta-proscend/conf/distro/planet-m300.conf
異動如下
diff --git a/meta-proscend/conf/distro/planet-m300.conf b/meta-proscend/conf/distro/planet-m300.conf
index 08c436d..e24614b 100644
--- a/meta-proscend/conf/distro/planet-m300.conf
+++ b/meta-proscend/conf/distro/planet-m300.conf
@@ -1,4 +1,5 @@
include conf/distro/include/proscend-base.inc
+include conf/distro/include/image_nandflash.inc
DISTRO = "planet-m300"
這兩個跟 m300
machine 相關的 distribution configuration file 都需要 include image_nandflash.inc
include conf/distro/include/image_nandflash.inc
conf/distro/include/image_nandflash.inc
內容如下
IMAGE_FSTYPES += "nandflash"
UBOOT_CONFIG = "nand"
這一次的主角 proscend-m300e.conf
內容如下
include conf/distro/include/proscend-base.inc
include conf/distro/include/image_emmc.inc
DISTRO = "proscend-m300e"
EXTRA_USERS_PARAMS = "usermod -P 2wsx#EDC root; \
useradd -P 2wsx#EDC proscend;"
跟 proscend-m300.conf
的差別只在於
include conf/distro/include/image_emmc.inc
image_emmc.inc
內容如下
UBOOT_CONFIG = "sd"
目前先不考慮 IMAGE_FSTYPES
就先這樣做 commit 吧
commit ca9ea6c8d6f6b7a4e8122535955f53654e9b26c0
Refs: [develop], {origin/develop}
Author: jeffrey <[email protected]>
Date: Thu Sep 28 10:27:53 2017 +0800
Support emmc design:
We have 2 machine configurations:
- m300.conf
- m300e.conf
3 distribution configurations:
- proscend-m300.conf
- proscend-m300e.conf
- planet-m300.conf
Current we have 3 ways to use 'proenv.sh' to initialize the compiling environment:
- source proenv.sh m300 proscend-m300
- source proenv.sh m300e proscend-m300e
- source proenv.sh m300 planet-m300
meta-proscend/conf/distro/include/image_emmc.inc | 3 +++
meta-proscend/conf/distro/include/image_nandflash.inc | 4 ++++
meta-proscend/conf/distro/include/proscend-base.inc | 4 ----
meta-proscend/conf/distro/planet-m300.conf | 1 +
meta-proscend/conf/distro/proscend-m300.conf | 1 +
meta-proscend/conf/distro/proscend-m300e.conf | 7 +++++++
6 files changed, 16 insertions(+), 4 deletions(-)
用正規的方式來修改 u-boot-imx 的 include\configs\mx6ul_14X14_evk.h
加入 #define CONFIG_MX6UL_EVK_EMMC_REWORK
這樣一來 u-boot 便能認得 mmc 了
紀錄一下步驟
- bitbake u-boot-imx -c devshell
- quilt new add_emmc_rework.patch
- quilt add include/configs/mx6ul_14x14_evk.h
- 修改
include/configs/mx6ul_14x14_evk.h
- 加入
#define CONFIG_MX6UL_EVK_EMMC_REWORK
- 加入
- quilt refresh
此時我們已經得到 patches/add_emmc_rework.patch
Index: git/include/configs/mx6ul_14x14_evk.h
===================================================================
--- git.orig/include/configs/mx6ul_14x14_evk.h
+++ git/include/configs/mx6ul_14x14_evk.h
@@ -20,6 +20,8 @@
#define CONFIG_DISPLAY_CPUINFO
#define CONFIG_DISPLAY_BOARDINFO
+#define CONFIG_MX6UL_EVK_EMMC_REWORK
+
#if !defined(CONFIG_MX6UL_9X9_LPDDR2)
/* DCDC used on 14x14 EVK, no PMIC */
#undef CONFIG_LDO_BYPASS_CHECK
把 patches/add_emmc_rework.patch
複製到 meta-proscend/recipes-bsp/u-boot/files/
去
修改 meta-proscend\recipes-bsp\u-boot\u-boot-imx_2015.04.bbappend
diff --git a/meta-proscend/recipes-bsp/u-boot/u-boot-imx_2015.04.bbappend b/meta-proscend/recipes-bsp/u-boot/u-boot-imx_2015.04.bbappend
index b9cbc85..c9b126b 100644
--- a/meta-proscend/recipes-bsp/u-boot/u-boot-imx_2015.04.bbappend
+++ b/meta-proscend/recipes-bsp/u-boot/u-boot-imx_2015.04.bbappend
@@ -14,3 +14,7 @@ SRC_URI_append_m300 = " \
file://remove_fsl_usdhc_and_vedio.patch \
file://use_usdhc_pad_ctrl_in_gpmi_pad_ctrl.patch \
"
+
+SRC_URI_append_m300e = " \
+ file://add_emmc_rework.patch \
+"
先使用 bitbake u-boot-imx -c clean
將 u-boot-imx
作 clean
再使用 bitbake u-boot-imx
會發現在 build_small\tmp\work\m300e-poky-linux-gnueabi\u-boot-imx\2015.04-r0\temp\
有 log.do_patch
DEBUG: Executing python function do_patch
DEBUG: Executing python function patch_do_patch
DEBUG: Searching for 000_enable_ENET_CLK_when_booting.patch in paths:
...
DEBUG: Searching for add_mx6ul_14x14_evk_nand_config.patch in paths:
...
DEBUG: Searching for set_do_default_low.patch in paths:
...
DEBUG: Searching for modify_bootup_temperature_limit.patch in paths:
...
DEBUG: Searching for fix_thermal.patch in paths:
...
DEBUG: Searching for add_emmc_rework.patch in paths:
...
NOTE: Applying patch '000_enable_ENET_CLK_when_booting.patch' (../meta-proscend/recipes-bsp/u-boot/files/000_enable_ENET_CLK_when_booting.patch)
NOTE: Applying patch 'add_mx6ul_14x14_evk_nand_config.patch' (../meta-proscend/recipes-bsp/u-boot/files/add_mx6ul_14x14_evk_nand_config.patch)
NOTE: Applying patch 'set_do_default_low.patch' (../meta-proscend/recipes-bsp/u-boot/files/set_do_default_low.patch)
NOTE: Applying patch 'modify_bootup_temperature_limit.patch' (../meta-proscend/recipes-bsp/u-boot/files/modify_bootup_temperature_limit.patch)
NOTE: Applying patch 'fix_thermal.patch' (../meta-proscend/recipes-bsp/u-boot/files/fix_thermal.patch)
NOTE: Applying patch 'add_emmc_rework.patch' (../meta-proscend/recipes-bsp/u-boot/files/add_emmc_rework.patch)
DEBUG: Python function patch_do_patch finished
DEBUG: Python function do_patch finished
確實有上了 patch add_emmc_rework.patch
commit 9a1207da2513afae277fe3fdafa3ee4ea883eaca
Refs: [develop], {origin/develop}
Author: jeffrey <[email protected]>
Date: Thu Sep 28 11:28:41 2017 +0800
Patch uboot for supporting emmc
.../recipes-bsp/u-boot/files/add_emmc_rework.patch | 13 +++++++++++++
.../recipes-bsp/u-boot/u-boot-imx_2015.04.bbappend | 4 ++++
2 files changed, 17 insertions(+)
用正規的方式來修改 kernel 的 imx6ul-14x14-evk.dts
先用 bitbake linux-imx -c clean
清一下
利用 bitbake linux-imx -c devshell
找到 linux kernel temporary source code
- build_small\tmp\work-shared\m300e\kernel-source
建立新的 patch
quilt new imx6ul-14x14-evk.dts.emmc.patch
notify Quilt about the files you plan to edit
quilt add arch/arm/boot/dts/imx6ul-14x14-evk.dts
參考 MX6UL_Development_database_2017.4.21_V7.doc 來作修改
/* SD card */
&usdhc2 {
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_usdhc2>;
no-1-8-v;
keep-power-in-suspend;
bus-width = <8>
non-removable;
status = "okay";
};
pinctrl_usdhc2: usdhc2grp {
fsl,pins = <
MX6UL_PAD_NAND_RE_B__USDHC2_CLK 0x10069
MX6UL_PAD_NAND_WE_B__USDHC2_CMD 0x17059
MX6UL_PAD_NAND_DATA00__USDHC2_DATA0 0x17059
MX6UL_PAD_NAND_DATA01__USDHC2_DATA1 0x17059
MX6UL_PAD_NAND_DATA02__USDHC2_DATA2 0x17059
MX6UL_PAD_NAND_DATA03__USDHC2_DATA3 0x17059
//add to support 8bit eMMC
MX6UL_PAD_NAND_DATA04__USDHC2_DATA4 0x17059
MX6UL_PAD_NAND_DATA05__USDHC2_DATA5 0x17059
MX6UL_PAD_NAND_DATA06__USDHC2_DATA6 0x17059
MX6UL_PAD_NAND_DATA07__USDHC2_DATA7 0x17059
//end
>;
};
generate the final patch that contains all your modifications
quilt refresh
此時我們已經得到 patches/imx6ul-14x14-evk.dts.emmc.patch
Index: kernel-source/arch/arm/boot/dts/imx6ul-14x14-evk.dts
===================================================================
--- kernel-source.orig/arch/arm/boot/dts/imx6ul-14x14-evk.dts
+++ kernel-source/arch/arm/boot/dts/imx6ul-14x14-evk.dts
@@ -165,9 +165,9 @@
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_usdhc2>;
no-1-8-v;
- non-removable;
keep-power-in-suspend;
- enable-sdio-wakeup;
+ bus-width = <8>
+ non-removable;
status = "okay";
};
@@ -264,6 +264,14 @@
MX6UL_PAD_NAND_DATA01__USDHC2_DATA1 0x17059
MX6UL_PAD_NAND_DATA02__USDHC2_DATA2 0x17059
MX6UL_PAD_NAND_DATA03__USDHC2_DATA3 0x17059
+
+//add to support 8bit eMMC
+ MX6UL_PAD_NAND_DATA04__USDHC2_DATA4 0x17059
+ MX6UL_PAD_NAND_DATA05__USDHC2_DATA5 0x17059
+ MX6UL_PAD_NAND_DATA06__USDHC2_DATA6 0x17059
+ MX6UL_PAD_NAND_DATA07__USDHC2_DATA7 0x17059
+//end
+
>;
};
把 patches/imx6ul-14x14-evk.dts.emmc.patch
複製到 meta-proscend\recipes-kernel\linux\files
修改 meta-proscend\recipes-kernel\linux\linux-imx_4.1.15.bbappend
diff --git a/meta-proscend/recipes-kernel/linux/linux-imx_4.1.15.bbappend b/meta-proscend/recipes-kernel/linux/linux-imx_4.1.15.bbappend
index 61838f0..32bb89b 100644
--- a/meta-proscend/recipes-kernel/linux/linux-imx_4.1.15.bbappend
+++ b/meta-proscend/recipes-kernel/linux/linux-imx_4.1.15.bbappend
@@ -24,6 +24,10 @@ SRC_URI_append_m300 = " \
file://add_nandflash.patch \
"
+SRC_URI_append_m300e = " \
+ file://imx6ul-14x14-evk.dts.emmc.patch \
+"
+
do_copy_defconfig_append () {
cp ${WORKDIR}/m300_defconfig ${B}/.config
cp ${WORKDIR}/m300_defconfig ${B}/../defconfig
先使用 bitbake linux-imx -c clean
將 linux-imx
作 clean
再使用 bitbake linux-imx
這個光 do_unpack
都要有點時間 ...
等一下吧
發現在 build_small\tmp\work\m300e-poky-linux-gnueabi\linux-imx\4.1.15-r0\temp
有 log.do_patch
DEBUG: Executing python function do_patch
DEBUG: Executing python function patch_do_patch
DEBUG: Searching for m300_defconfig in paths:
...
DEBUG: Searching for m300_ra2_io.patch in paths:
...
DEBUG: Searching for fix_rs485_driver.patch in paths:
...
DEBUG: Searching for add_usbserial_ppp_support.patch in paths:
...
DEBUG: Searching for modify_working_temperature.patch in paths:
...
DEBUG: Searching for m301_lan_driver.patch in paths:
...
DEBUG: Searching for revert_alarm_active_low.patch in paths:
...
DEBUG: Searching for 09_m301_lan_driver_ksz8794_spi_vendor_driver_linux-3.18_ksz8795.patch in paths:
...
DEBUG: Searching for 10_m301_lan_driver_ksz8794_spi_built_bug_fixed.patch in paths:
...
DEBUG: Searching for 11_m300_m301_lan_driver_co_exist_by_redirect_mii_to_sw.patch in paths:
...
DEBUG: Searching for 12_m301_lan_driver_ksz8794_spi_bring_up.patch in paths:
...
DEBUG: Searching for 13_m301_lan_driver_ksz8794_spi_vendor_driver_linux-3.18_dsa.patch in paths:
...
DEBUG: Searching for 14_m301_lan_driver_ksz8794_spi_dsa_unimplement_function.patch in paths:
...
DEBUG: Searching for 15_m301_lan_driver_ksz8794_spi_allow_pwr_done_via_virtual_mdis_reg0.patch in paths:
...
DEBUG: Searching for 16_usbotg1_changed_as_host_for_wifi_8192du.patch in paths:
...
DEBUG: Searching for 17_Quentel_UG16_Use_GobiNet_or_QMI_WWAN.patch in paths:
...
DEBUG: Searching for 18_m301_lan_driver_ksz8794_dsa_per_port_interface.patch in paths:
...
DEBUG: Searching for imx6ul-14x14-evk.dts.emmc.patch in paths:
...
NOTE: Applying patch 'm300_ra2_io.patch' (../meta-proscend/recipes-kernel/linux/files/m300_ra2_io.patch)
NOTE: Applying patch 'fix_rs485_driver.patch' (../meta-proscend/recipes-kernel/linux/files/fix_rs485_driver.patch)
NOTE: Applying patch 'add_usbserial_ppp_support.patch' (../meta-proscend/recipes-kernel/linux/files/add_usbserial_ppp_support.patch)
NOTE: Applying patch 'modify_working_temperature.patch' (../meta-proscend/recipes-kernel/linux/files/modify_working_temperature.patch)
NOTE: Applying patch 'm301_lan_driver.patch' (../meta-proscend/recipes-kernel/linux/files/m301_lan_driver.patch)
NOTE: Applying patch 'revert_alarm_active_low.patch' (../meta-proscend/recipes-kernel/linux/files/revert_alarm_active_low.patch)
NOTE: Applying patch '09_m301_lan_driver_ksz8794_spi_vendor_driver_linux-3.18_ksz8795.patch' (../meta-proscend/recipes-kernel/linux/files/09_m301_lan_driver_ksz8794_spi_vendor_driver_linux-3.18_ksz8795.patch)
NOTE: Applying patch '10_m301_lan_driver_ksz8794_spi_built_bug_fixed.patch' (../meta-proscend/recipes-kernel/linux/files/10_m301_lan_driver_ksz8794_spi_built_bug_fixed.patch)
NOTE: Applying patch '11_m300_m301_lan_driver_co_exist_by_redirect_mii_to_sw.patch' (../meta-proscend/recipes-kernel/linux/files/11_m300_m301_lan_driver_co_exist_by_redirect_mii_to_sw.patch)
NOTE: Applying patch '12_m301_lan_driver_ksz8794_spi_bring_up.patch' (../meta-proscend/recipes-kernel/linux/files/12_m301_lan_driver_ksz8794_spi_bring_up.patch)
NOTE: Applying patch '13_m301_lan_driver_ksz8794_spi_vendor_driver_linux-3.18_dsa.patch' (../meta-proscend/recipes-kernel/linux/files/13_m301_lan_driver_ksz8794_spi_vendor_driver_linux-3.18_dsa.patch)
NOTE: Applying patch '14_m301_lan_driver_ksz8794_spi_dsa_unimplement_function.patch' (../meta-proscend/recipes-kernel/linux/files/14_m301_lan_driver_ksz8794_spi_dsa_unimplement_function.patch)
NOTE: Applying patch '15_m301_lan_driver_ksz8794_spi_allow_pwr_done_via_virtual_mdis_reg0.patch' (../meta-proscend/recipes-kernel/linux/files/15_m301_lan_driver_ksz8794_spi_allow_pwr_done_via_virtual_mdis_reg0.patch)
NOTE: Applying patch '16_usbotg1_changed_as_host_for_wifi_8192du.patch' (../meta-proscend/recipes-kernel/linux/files/16_usbotg1_changed_as_host_for_wifi_8192du.patch)
NOTE: Applying patch '17_Quentel_UG16_Use_GobiNet_or_QMI_WWAN.patch' (../meta-proscend/recipes-kernel/linux/files/17_Quentel_UG16_Use_GobiNet_or_QMI_WWAN.patch)
NOTE: Applying patch '18_m301_lan_driver_ksz8794_dsa_per_port_interface.patch' (../meta-proscend/recipes-kernel/linux/files/18_m301_lan_driver_ksz8794_dsa_per_port_interface.patch)
NOTE: Applying patch 'imx6ul-14x14-evk.dts.emmc.patch' (../meta-proscend/recipes-kernel/linux/files/imx6ul-14x14-evk.dts.emmc.patch)
DEBUG: Python function patch_do_patch finished
DEBUG: Python function do_patch finished
確實有上了 patch imx6ul-14x14-evk.dts.emmc.patch
先等一下 bitbake linux-imx
的結果
compile 出錯了
感覺是我的 dtb file 寫錯了
先還原 linux-imx_4.1.15.bbappend
用 bitbake linux-imx -c unpack
看看會部會省一些 compile 時間
利用 bitbake linux-imx -c devshell
找到 linux kernel temporary source code
- build_small\tmp\work-shared\m300e\kernel-source
建立新的 patch
quilt new imx6ul-14x14-evk.dts.emmc.patch
notify Quilt about the files you plan to edit
quilt add arch/arm/boot/dts/imx6ul-14x14-evk.dts
參考 MX6UL_Development_database_2017.4.21_V7.doc 來作修改
/* SD card */
&usdhc2 {
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_usdhc2>;
no-1-8-v;
keep-power-in-suspend;
bus-width = <8>;
non-removable;
status = "okay";
};
pinctrl_usdhc2: usdhc2grp {
fsl,pins = <
MX6UL_PAD_NAND_RE_B__USDHC2_CLK 0x10069
MX6UL_PAD_NAND_WE_B__USDHC2_CMD 0x17059
MX6UL_PAD_NAND_DATA00__USDHC2_DATA0 0x17059
MX6UL_PAD_NAND_DATA01__USDHC2_DATA1 0x17059
MX6UL_PAD_NAND_DATA02__USDHC2_DATA2 0x17059
MX6UL_PAD_NAND_DATA03__USDHC2_DATA3 0x17059
MX6UL_PAD_NAND_DATA04__USDHC2_DATA4 0x17059
MX6UL_PAD_NAND_DATA05__USDHC2_DATA5 0x17059
MX6UL_PAD_NAND_DATA06__USDHC2_DATA6 0x17059
MX6UL_PAD_NAND_DATA07__USDHC2_DATA7 0x17059
>;
};
generate the final patch that contains all your modifications
quilt refresh
此時我們已經得到 patches/imx6ul-14x14-evk.dts.emmc.patch
Index: kernel-source/arch/arm/boot/dts/imx6ul-14x14-evk.dts
===================================================================
--- kernel-source.orig/arch/arm/boot/dts/imx6ul-14x14-evk.dts
+++ kernel-source/arch/arm/boot/dts/imx6ul-14x14-evk.dts
@@ -165,9 +165,9 @@
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_usdhc2>;
no-1-8-v;
- non-removable;
keep-power-in-suspend;
- enable-sdio-wakeup;
+ bus-width = <8>;
+ non-removable;
status = "okay";
};
@@ -264,6 +264,10 @@
MX6UL_PAD_NAND_DATA01__USDHC2_DATA1 0x17059
MX6UL_PAD_NAND_DATA02__USDHC2_DATA2 0x17059
MX6UL_PAD_NAND_DATA03__USDHC2_DATA3 0x17059
+ MX6UL_PAD_NAND_DATA04__USDHC2_DATA4 0x17059
+ MX6UL_PAD_NAND_DATA05__USDHC2_DATA5 0x17059
+ MX6UL_PAD_NAND_DATA06__USDHC2_DATA6 0x17059
+ MX6UL_PAD_NAND_DATA07__USDHC2_DATA7 0x17059
>;
};
把 patches/imx6ul-14x14-evk.dts.emmc.patch
複製到 meta-proscend\recipes-kernel\linux\files
修改 meta-proscend\recipes-kernel\linux\linux-imx_4.1.15.bbappend
diff --git a/meta-proscend/recipes-kernel/linux/linux-imx_4.1.15.bbappend b/meta-proscend/recipes-kernel/linux/linux-imx_4.1.15.bbappend
index 61838f0..32bb89b 100644
--- a/meta-proscend/recipes-kernel/linux/linux-imx_4.1.15.bbappend
+++ b/meta-proscend/recipes-kernel/linux/linux-imx_4.1.15.bbappend
@@ -24,6 +24,10 @@ SRC_URI_append_m300 = " \
file://add_nandflash.patch \
"
+SRC_URI_append_m300e = " \
+ file://imx6ul-14x14-evk.dts.emmc.patch \
+"
+
do_copy_defconfig_append () {
cp ${WORKDIR}/m300_defconfig ${B}/.config
cp ${WORKDIR}/m300_defconfig ${B}/../defconfig
先使用 bitbake linux-imx -c clean
將 linux-imx
作 clean
先使用 bitbake linux-imx -c devshell
- 會先做 unpack
- 再做 patch
利用下述命令確認 dts 的修改無誤
- make imx_v7_mfg_defconfig
- make imx6ul-14x14-evk.dtb
執行 bitbake linux-imx
上 code 囉
commit 5438352db4c059a5f706036cb99dd01ecc5aa8dc
Refs: [develop], {origin/develop}
Author: jeffrey <[email protected]>
Date: Thu Sep 28 14:53:10 2017 +0800
Patch linux kernel for supporting emmc
.../linux/files/imx6ul-14x14-evk.dts.emmc.patch | 27 ++++++++++++++++++++++
.../recipes-kernel/linux/linux-imx_4.1.15.bbappend | 4 ++++
2 files changed, 31 insertions(+)
試著用 source proenv.sh m300e proscend-m300e
然後用 source bimage.sh
完整的走一次目前的 compile 流程
source bimage.sh
順利的走完了整個 compile 流程
看一下我有什麼可以讓 MfgTool2 利用
- build_small\images\u-boot-m300e.imx-sd
- build_small\images\zImage-imx6ul-14x14-evk.dtb
- build_small\images\zImage
- build_small\images\core-image-minimal-m300e.tar.bz2
對應到目前 MfgTool2 的 mfgtools\Profiles\Linux\OS Firmware\files
為
- u-boot-imx6ulevk_sd.imx
- imx6ul-14x14-evk.dtb
- zImage
- rootfs_nogpu.tar.bz2
先建一個 mfgtools\Profiles\Linux\OS Firmware\files\v01
來放目前的 mfgtools\Profiles\Linux\OS Firmware\files\*
再建一個 mfgtools\Profiles\Linux\OS Firmware\files\v02
來放 source bimage.sh
compile 出來的
- u-boot-m300e.imx-sd
- zImage-imx6ul-14x14-evk.dtb
- zImage
- core-image-minimal-m300e.tar.bz2
將 mfgtools\Profiles\Linux\OS Firmware\files\v02\*
複製到 mfgtools\Profiles\Linux\OS Firmware\files*
-
v02\u-boot-m300e.imx-sd
u-boot-imx6ulevk_sd.imx
-
v02\zImage-imx6ul-14x14-evk.dtb
imx6ul-14x14-evk.dtb
-
v02\zImage
zImage
-
v02\core-image-minimal-m300e.tar.bz2
rootfs_nogpu.tar.bz2
MfgTool2 燒錄成功
不過從 emmc 開機發生了問題
U-Boot 2015.04imx_v2015.04_4.1.15_1.2.0_ga+gede7538 (Sep 25 2017 - 01:12:24)
CPU: Freescale i.MX6UL rev1.2 at 396 MHz
CPU: Temperature 35 C
Reset cause: POR
Board: MX6UL 14x14 EVK
I2C: ready
DRAM: 512 MiB
force_idle_bus: sda=0 scl=0 sda.gp=0x1d scl.gp=0x1c
MMC: FSL_SDHC: 0, FSL_SDHC: 1
*** Warning - bad CRC, using default environment
Display: TFT43AB (480x272)
Video: 480x272x24
In: serial
Out: serial
Err: serial
MMC: no card present
Net: FEC1
Error: FEC1 address not set.
Normal Boot
Hit any key to stop autoboot: 0
MMC: no card present
MMC: no card present
Card did not respond to voltage select!
Booting from net ...
FEC1 Waiting for PHY auto negotiation to complete......... TIMEOUT !
*** ERROR: `ethaddr' not set
FEC1 Waiting for PHY auto negotiation to complete......... TIMEOUT !
FEC1 Waiting for PHY auto negotiation to complete......... TIMEOUT !
*** ERROR: `ethaddr' not set
FEC1 Waiting for PHY auto negotiation to complete......... TIMEOUT !
Bad Linux ARM zImage magic!
=>
從 morris 那邊拿了一片從來都沒燒過的 CPU 板再燒一次
這次從 emmc 開機連 uboot 都開不起來
感覺 ucl2.xml
還要再 review 一下