I'm working on adding a new platform/Device to OpenWRT platform. I had cloned chaos calmer and did patch the acrh/Cpu and driver patches specific to the board which is based on MIPS architecture. Now, I have couple of questions:
The board is not partitioned for any OVerlayFS and I ain't want to do this. How to support the config persistence across reboot and factory defaults of /etc/config. I can create similar directories in flash but I'm wondering what change has to be done to copy these during reset or factory reset?
Is there any special hooks needed for netifd (network interface daemon) and rpcd iwinfo to work with driver?
Thanks in Advance!
It makes no sense to start from the ancient cc15.05
If you want sensible answers, it pays off to show more details, e.g. facts about the device and target architecture, plus your changes as patches.
Thanks. its for MTK boards using MIPS 34KC CPU. it doesn't have any partition for Overlay FS. The WIFI,ethernet and GPON driver are up-streamed to support. However, My question is not related to Arch and is general.
i.e In general,
How to support the config persistence across reboot and factory defaults of /etc/config. I can create similar directories(like in OverlayFS) in flash but I’m wondering what change has to be done to copy these during reset or factory reset?
Is there any special hooks needed for netifd (network interface daemon) and rpcd iwinfo to work with the MTK75XX driver?
The "board" or bootloader does not need to be partitioned for overlayfs. OpenWrt is designed to work with one contiguous blob of flash called "firmware" and generate mtd partitions within it during boot. The first boot formats the empty space in the flash that is not kernel or rootfs into a jffs2 filesystem and mounts it at /overlay.
The bootloader only needs to know where to find the kernel, decompress it into RAM, then jump to the kernel code. The bootloader is never run again. The kernel has complete control of what it accesses in flash and where. On a MTK device, the partitioning would be hard-coded in the dts file. OpenWrt assembles the flash image with the kernel at the very start so it can be easily found.
The iwinfo and other wireless operations should be hardware-agnostic by working via the mac80211 layer above the hardware driver.