#
227926 |
|
24-Nov-2011 |
adrian |
Now that I've brought up FreeBSD via flash, I've discovered that the second-last 64k seems to be the default firmware board configuration area.
Since I have no idea whether uboot uses it or not - and it's prefixed with an atheros eeprom signature (0xaa55), I figure the safest thing to do is mark it as read-only.
I've modified my local tplink firmware building program to generate a board configuration section - which is separate to this partition. It's located in the 64k _before_ this particular 64k.
The firmware build program from OpenWRT never initialises those values and the firmware images from tplink also leave it 0x0, so I don't currently know what the exact, correct details should be.
|
#
227921 |
|
24-Nov-2011 |
adrian |
Flesh out a geom_map setup, so the kernel can be squeezed _onto_ the device.
The default flash layout gives only 1 megabyte for the kernel, gzipped. The uboot firmware running on this device only supports gzip, not lzma, so we actually _do_ have to try and slim the kernel down a bit.
But, since I can't actually do that at the present, I'm opting to:
* extend the kernel from 1mb to 2mb; * have rootfs fill the rest of that, save 64k; * eventually I'll hide a 64k config partition at the end, between the end of rootfs and the ART (radio configuration data.)
The uboot firmware doesn't care about the partition layout. It just expects the kernel application image to sit at 0xbf020000 (right after the 128k uboot image.) The uboot header isn't actually read either - it's "faked" from a "tplink" flash image header. So as long as the map configuration here matches what is being written out via the tplink firmware generator, everything is a-ok.
|