Skip to contentSkip to conversation

ARM: imx6q_logic: Allow storing environment in FAT on eMMC

PATCH In review Adam Ford 2 participants 2 messages Apr 11, 2019 – Apr 26, 2019 Arm i.MX and Layerscape

lore
Share & tools
lore

Adam Ford

author
#0 lore raw

PATCH 1/1 ARM: imx6q_logic: Allow storing environment in FAT on eMMC

Some variations of the imx6q_logic board have eMMC instead of NAND. Rather than creating a separate defconfig, this patch adds the ability to read/write to eMMC (mmc 0:1) when NAND doesn't exist.

configs/imx6q_logic_defconfig +3 -1
index 385efcec4e..a006d33311 100644
@@ -54,7 +54,10 @@ CONFIG_MTDIDS_DEFAULT="nand0=gpmi-nand"
 CONFIG_MTDPARTS_DEFAULT="mtdparts=gpmi-nand:2m(spl),2m(uboot),1m(env),16m(kernel),1m(dtb),-(fs)"
 CONFIG_CMD_UBI=y
 CONFIG_DEFAULT_DEVICE_TREE="imx6q-logicpd"
+CONFIG_ENV_IS_IN_FAT=y
 CONFIG_ENV_IS_IN_NAND=y
+CONFIG_ENV_FAT_INTERFACE="mmc"
+CONFIG_ENV_FAT_DEVICE_AND_PART="0:1"
 CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG=y
 CONFIG_PCF8575_GPIO=y
 CONFIG_LED=y
@@ -84,4 +87,3 @@ CONFIG_USB_GADGET_VENDOR_NUM=0x0525
 CONFIG_USB_GADGET_PRODUCT_NUM=0xa4a5
 CONFIG_CI_UDC=y
 CONFIG_USB_GADGET_DOWNLOAD=y
-CONFIG_FAT_WRITE=y
Signature · 1 line
2.17.1
#1 lore raw
Quoted 21 lines

Some variations of the imx6q_logic board have eMMC instead of NAND. Rather than creating a separate defconfig, this patch adds the ability to read/write to eMMC (mmc 0:1) when NAND doesn't exist.

configs/imx6q_logic_defconfig +3 -0
index 385efcec4e..a006d33311 100644
@@ -54,7 +54,10 @@ CONFIG_MTDIDS_DEFAULT="nand0=gpmi-nand"
 CONFIG_MTDPARTS_DEFAULT="mtdparts=gpmi-nand:2m(spl),2m(uboot),1m(env),16m(kernel),1m(dtb),-(fs)"
 CONFIG_CMD_UBI=y
 CONFIG_DEFAULT_DEVICE_TREE="imx6q-logicpd"
+CONFIG_ENV_IS_IN_FAT=y
 CONFIG_ENV_IS_IN_NAND=y
+CONFIG_ENV_FAT_INTERFACE="mmc"
+CONFIG_ENV_FAT_DEVICE_AND_PART="0:1"
 CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG=y
 CONFIG_PCF8575_GPIO=y
 CONFIG_LED=y

configs/imx6q_logic_defconfig CONFIG_USB_GADGET_VENDOR_NUM=0x0525 · line 87

Quoted 4 lines
configs/imx6q_logic_defconfig +0 -1
@@ -84,4 +87,3 @@ CONFIG_USB_GADGET_VENDOR_NUM=0x0525
 CONFIG_USB_GADGET_PRODUCT_NUM=0xa4a5
 CONFIG_CI_UDC=y
 CONFIG_USB_GADGET_DOWNLOAD=y
-CONFIG_FAT_WRITE=y

Applied to u-boot-imx, master, thanks !

Best regards,
Stefano Babic

Signature · 5 lines
=====================================================================
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de
=====================================================================