aboutsummaryrefslogtreecommitdiffstats
path: root/target
diff options
context:
space:
mode:
authorLuka Perkov <luka@openwrt.org>2013-11-18 22:23:40 +0000
committerLuka Perkov <luka@openwrt.org>2013-11-18 22:23:40 +0000
commit5fc33c5d887f7ae9bdf24f33e937fa14365b18da (patch)
treeef50b29e4dc774573eed2809cc5a9625539fa89e /target
parentd8a2d058a41f13b13694d21c1f452476e2cd2185 (diff)
downloadupstream-5fc33c5d887f7ae9bdf24f33e937fa14365b18da.tar.gz
upstream-5fc33c5d887f7ae9bdf24f33e937fa14365b18da.tar.bz2
upstream-5fc33c5d887f7ae9bdf24f33e937fa14365b18da.zip
imx6: add support for more then one nand type per profile
Signed-off-by: Luka Perkov <luka@openwrt.org> git-svn-id: svn://svn.openwrt.org/openwrt/trunk@38857 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target')
-rw-r--r--target/linux/imx6/image/Makefile30
-rw-r--r--target/linux/imx6/profiles/120-gateworks.mk3
2 files changed, 22 insertions, 11 deletions
diff --git a/target/linux/imx6/image/Makefile b/target/linux/imx6/image/Makefile
index d49c180daa..6cdb6c9fba 100644
--- a/target/linux/imx6/image/Makefile
+++ b/target/linux/imx6/image/Makefile
@@ -80,18 +80,28 @@ define Image/mkfs/targz
$(TAR) -czpf $(BIN_DIR)/$(IMG_PREFIX)-$(call sanitize_profile_name)-rootfs.tar.gz --numeric-owner --owner=0 --group=0 -C $(TARGET_DIR)/ .
endef
-define Image/Build/ubifs
+define ubifs_imx_gateworks_ventana
+ # Micron MT29F1G08ABAD/MT29F2G08ABAE/MT29F4G08ABAD/MT29F8G08ADAD NAND
+ $(eval IMX6Q_GW54XX_UBIFS_OPTS:="-m 2048 -e 124KiB -c 8124")
+ $(eval IMX6Q_GW54XX_UBI_OPTS:="-m 2048 -p 128KiB -s 2048")
+ $(call Image/mkfs/ubifs)
+ $(CP) $(KDIR)/root.ubifs $(BIN_DIR)/$(IMG_PREFIX)-$(call sanitize_profile_name)-rootfs_normal.ubifs
+ $(CP) $(KDIR)/root.ubi $(BIN_DIR)/$(IMG_PREFIX)-$(call sanitize_profile_name)-rootfs_normal.ubi
+
+ # Micron MT29F8G08ABAC/MT29F16G08ADAC 1GB/2GB NAND
+ $(eval IMX6Q_GW54XX_UBIFS_OPTS:="-m 4096 -e 248KiB -c 8124")
+ $(eval IMX6Q_GW54XX_UBI_OPTS:="-m 4096 -p 256KiB -s 4096")
+ $(call Image/mkfs/ubifs)
+ $(CP) $(KDIR)/root.ubifs $(BIN_DIR)/$(IMG_PREFIX)-$(call sanitize_profile_name)-rootfs_large.ubifs
+ $(CP) $(KDIR)/root.ubi $(BIN_DIR)/$(IMG_PREFIX)-$(call sanitize_profile_name)-rootfs_large.ubi
+endef
- ifneq ($($(PROFILE)_UBIFS_OPTS),)
- $(CP) $(KDIR)/root.ubifs $(BIN_DIR)/$(IMG_PREFIX)-$(call sanitize_profile_name)-rootfs.ubifs
- endif
+define Image/Build/ubifs
+ true
endef
define Image/Build/ubi
-
- ifneq ($($(PROFILE)_UBI_OPTS),)
- $(CP) $(KDIR)/root.ubi $(BIN_DIR)/$(IMG_PREFIX)-$(call sanitize_profile_name)-rootfs.ubi
- endif
+ true
endef
@@ -106,6 +116,7 @@ Image/InstallKernel/Template/IMX6Q_GW5400_A=$(call Image/InstallKernel/Template,
Image/BuildKernel/Template/IMX6Q_GW54XX=$(call Image/BuildKernel/Template,imx6q-gw54xx)
Image/InstallKernel/Template/IMX6Q_GW54XX=$(call Image/InstallKernel/Template,imx6q-gw54xx)
+Image/ubifs/IMX6Q_GW54XX=$(call ubifs_imx_gateworks_ventana)
define Image/BuildKernel
@@ -114,6 +125,9 @@ endef
define Image/InstallKernel
$(call Image/InstallKernel/Template/$(PROFILE))
+ $(if $(Image/ubifs/$(PROFILE)), \
+ $(call Image/ubifs/$(PROFILE))
+ )
endef
define Image/Build
diff --git a/target/linux/imx6/profiles/120-gateworks.mk b/target/linux/imx6/profiles/120-gateworks.mk
index 454c100518..a62fd1e81a 100644
--- a/target/linux/imx6/profiles/120-gateworks.mk
+++ b/target/linux/imx6/profiles/120-gateworks.mk
@@ -54,7 +54,4 @@ define Profile/IMX6Q_GW54XX/Description
* Gateworks System Controller
endef
-IMX6Q_GW54XX_UBIFS_OPTS:="-m 2048 -e 124KiB -c 1912"
-IMX6Q_GW54XX_UBI_OPTS:="-m 2048 -p 128KiB -s 2048"
-
$(eval $(call Profile,IMX6Q_GW54XX))