I have been modifying OpenWrt devices for a while now so I know my way around partitons, devicetree and reading/writing flash. I have been wondering why there is so much empty wasted space in the following partitions:
- UBOOT_DATA
this is the second half of the uboot partition. It usually only contains the MAC address and some other numbers that are not even used and in most cases uboot can't even save data here because it is read only
so there is an entire 64KiB partition to hold 6 bytes - ART
On Atheros routers this partition holds the calibration data for the wireless chip
again a 64KiB partition to hold ~1088 bytes - FACTORY
in the case of WR802N_V4 there is a partition with the MAC and some other parameters mostly empty
192KiB to hold ~1500bytes
I know that there is a limitation to the block size that can be erased on flash chips, so I am guessing this is a result of factories writing these blocks on the assembly line needing the full partition only for small device specific config.
As I am modifying stuff anyway I do not see any reason to keep it this way (most of the devices I tinker with are ewaste even by OpenWrt standards so it is custom compiled either way), can I just dump all data into a single 64KiB block? For example for a standard atheros router I can copy the ART data into UBOOT_DATA and just edit the device tree. or is there some limitation I am not aware of?
I am aware this is not worth the effort for most people, just want to find out if it works and possible to save a bit of space. I am just doing this for learning and fun.