Hi all,

I'm trying to integrate our board and the Stamp9G20 EVB[1] into the at91 platform target directory. I would like to know how people do to generate their kernel config file (which are usually very small). Should I do a kernel_menuconfig manually and select the very minimum that allow to boot the board, or is there any "magic script" that could extract this file for me given a "generic" config?

I would like to know as well, what is the strategy concerning the partitioning of the (NAND) flash. Should I try to get OpenWRT to reuse the existing partioning or is it common to redefine a new partioning that fits the OpenWRT requirements (especially concerning the squahfs over jffs2).

This is the out-of-factory layout of my NAND flash (32MB):
mtd0: "at91bootstrap"
mtd1: "uboot"
mtd2: "env1"
mtd3: "env2"
mtd4: "Linux"
mtd5: "rootfs" (JFFS2)

And I was thinking of going for something like this:
mtd0: "at91bootstrap"
mtd1: "uboot"
mtd2: "env"
mtd6: "firmware"
mtd3:  +- "kernel"
mtd4   +- "rootfs"           mounted as /         type mini_fo
           +-                mounted as /rom      type squasfs
mtd5:      +- "rootfs_data"  mounted as /overlay  type jffs2

I like this idea of having a firmware.bin for kernel+rootfs on one hand and then having the /rom ro and /overlay rw. Thought I'm surprised that /etc/config doesn't have it's own partition, maybe i misunderstood the role of the /overlay (it's both for packages installed manually and the current persistent config).

Still concerning a bit the partitioning, I'm now moving to the image format of the final "firmware.bin". Especially concerning the splitting of rootfs into /rom and /overlay. For what I understood, there's a magic value "0xdeadc0de" that needs to be placed at "the right place". Is it something handled by OpenWRT or do I have to write the boiler plate myself in the target/at91 directory? Any point out would be very welcome! I've just spend days reading and reading the online documentation and looking at the other plaform makefiles, and I'm still missing some pieces of the puzzle! ;)

Last but not least, I had a look at the target/linux subdirectory and I'm having difficulties to find several "good" candidates to mimic. I know the at91 already exists, but (sorry in advance to the maintainers), it doesn't seem to follow the "best practice" to me. What would be the "best" platforms implementation in terms of Makefile and config files?

Best regards,
Chris

[1] http://www.taskit.de/en/products/stamp9g20/starterkit.htm



--
Christian Gagneraud,
Embedded systems engineer.
Techworks Marine
1 Harbour road
Dun Laoghaire
Co. Dublin
Ireland
Tel: + 353 (0) 1 236 5990
Web: http://www.techworks.ie/
_______________________________________________
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel

Reply via email to