This target will be used for Mikrotik devices using YAFFS2 flash.
The subtarget nand will support NAND devices on UBI/UBIFS.

Signed-off-by: Stefan Agner <[email protected]>
---
 target/linux/ar71xx/Makefile                       |  6 +---
 target/linux/ar71xx/nand-yaffs2/config-default     | 34
++++++++++++++++++++++
 .../ar71xx/nand-yaffs2/profiles/01-minimal.mk      | 16 ++++++++++
 .../linux/ar71xx/nand-yaffs2/profiles/02-ath5k.mk  | 16 ++++++++++
 target/linux/ar71xx/nand-yaffs2/target.mk          |  8 +++++
 5 files changed, 75 insertions(+), 5 deletions(-)
 create mode 100644 target/linux/ar71xx/nand-yaffs2/config-default
 create mode 100644
target/linux/ar71xx/nand-yaffs2/profiles/01-minimal.mk
 create mode 100644 target/linux/ar71xx/nand-yaffs2/profiles/02-ath5k.mk
 create mode 100644 target/linux/ar71xx/nand-yaffs2/target.mk

diff --git a/target/linux/ar71xx/Makefile b/target/linux/ar71xx/Makefile
index cabcf04..120328a 100644
--- a/target/linux/ar71xx/Makefile
+++ b/target/linux/ar71xx/Makefile
@@ -11,7 +11,7 @@ BOARD:=ar71xx
 BOARDNAME:=Atheros AR7xxx/AR9xxx
 FEATURES:=squashfs targz mips16
 CPU_TYPE=34kc
-SUBTARGETS:=generic nand
+SUBTARGETS:=generic nand nand-yaffs2
 
 LINUX_VERSION:=3.10.13
 
@@ -22,8 +22,4 @@ DEFAULT_PACKAGES += \
        kmod-ledtrig-default-on kmod-ledtrig-timer kmod-ledtrig-netdev \
        kmod-ath9k wpad-mini uboot-envtools
 
-define Target/Description
-       Build firmware images for Atheros AR7xxx/AR9xxx based boards.
-endef
-
 $(eval $(call BuildTarget))
diff --git a/target/linux/ar71xx/nand-yaffs2/config-default
b/target/linux/ar71xx/nand-yaffs2/config-default
new file mode 100644
index 0000000..efa562c
--- /dev/null
+++ b/target/linux/ar71xx/nand-yaffs2/config-default
@@ -0,0 +1,34 @@
+CONFIG_ATH79_MACH_RB2011=y
+CONFIG_ATH79_MACH_RB4XX=y
+CONFIG_ATH79_MACH_RB750=y
+CONFIG_ATH79_MACH_RB95X=y
+CONFIG_ATH79_ROUTERBOOT=y
+CONFIG_CMDLINE="rootfstype=yaffs noinitrd"
+# CONFIG_JFFS2_FS is not set
+CONFIG_LEDS_RB750=y
+CONFIG_MDIO_BITBANG=y
+CONFIG_MDIO_GPIO=y
+CONFIG_MTD_NAND=y
+CONFIG_MTD_NAND_AR934X=y
+CONFIG_MTD_NAND_ECC=y
+CONFIG_MTD_NAND_RB4XX=y
+CONFIG_MTD_NAND_RB750=y
+# CONFIG_MTD_SM_COMMON is not set
+# CONFIG_OVERLAYFS_FS is not set
+CONFIG_RLE_DECOMPRESS=y
+CONFIG_SPI_RB4XX=y
+CONFIG_SPI_RB4XX_CPLD=y
+# CONFIG_SQUASHFS is not set
+CONFIG_YAFFS_9BYTE_TAGS=y
+CONFIG_YAFFS_ALWAYS_CHECK_CHUNK_ERASED=y
+CONFIG_YAFFS_AUTO_YAFFS2=y
+# CONFIG_YAFFS_DISABLE_BACKGROUND is not set
+# CONFIG_YAFFS_DISABLE_BLOCK_REFRESHING is not set
+# CONFIG_YAFFS_DISABLE_TAGS_ECC is not set
+# CONFIG_YAFFS_DISABLE_WIDE_TNODES is not set
+# CONFIG_YAFFS_EMPTY_LOST_AND_FOUND is not set
+CONFIG_YAFFS_FS=y
+CONFIG_YAFFS_SHORT_NAMES_IN_RAM=y
+CONFIG_YAFFS_XATTR=y
+CONFIG_YAFFS_YAFFS1=y
+CONFIG_YAFFS_YAFFS2=y
diff --git a/target/linux/ar71xx/nand-yaffs2/profiles/01-minimal.mk
b/target/linux/ar71xx/nand-yaffs2/profiles/01-minimal.mk
new file mode 100644
index 0000000..3651c88
--- /dev/null
+++ b/target/linux/ar71xx/nand-yaffs2/profiles/01-minimal.mk
@@ -0,0 +1,16 @@
+#
+# Copyright (C) 2009 OpenWrt.org
+#
+# This is free software, licensed under the GNU General Public License
v2.
+# See /LICENSE for more information.
+#
+
+define Profile/DefaultNoWifi
+       NAME:=Default Profile (no WiFi)
+       PACKAGES:=
+endef
+
+define Profile/DefaultNoWifi/Description
+       Default package set compatible with most boards.
+endef
+$(eval $(call Profile,DefaultNoWifi))
diff --git a/target/linux/ar71xx/nand-yaffs2/profiles/02-ath5k.mk
b/target/linux/ar71xx/nand-yaffs2/profiles/02-ath5k.mk
new file mode 100644
index 0000000..a291ff6
--- /dev/null
+++ b/target/linux/ar71xx/nand-yaffs2/profiles/02-ath5k.mk
@@ -0,0 +1,16 @@
+#
+# Copyright (C) 2009-2012 OpenWrt.org
+#
+# This is free software, licensed under the GNU General Public License
v2.
+# See /LICENSE for more information.
+#
+
+define Profile/Ath5k
+       NAME:=Atheros WiFi (ath5k)
+       PACKAGES:=kmod-ath5k -kmod-ath9k
+endef
+
+define Profile/Ath5k/Description
+       Package set compatible with hardware using Atheros WiFi cards.
+endef
+$(eval $(call Profile,Ath5k))
diff --git a/target/linux/ar71xx/nand-yaffs2/target.mk
b/target/linux/ar71xx/nand-yaffs2/target.mk
new file mode 100644
index 0000000..756c9d0
--- /dev/null
+++ b/target/linux/ar71xx/nand-yaffs2/target.mk
@@ -0,0 +1,8 @@
+BOARDNAME:=Devices with NAND flash using YAFFS2
+
+define Target/Description
+       Build firmware images for Atheros AR71xx/AR913x based boards with 
+       NAND flash and YAFFS2 filesystem, e.g. MikroTik RB-4xx or RB-750
+endef
+
+
-- 
1.8.4
_______________________________________________
openwrt-devel mailing list
[email protected]
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel

Reply via email to