There are two paths we can use to construct a kernel and trx file.
Path one: Do the openwrt build. This creates a trx program (used to create the final trx image), lzma loader (boot loader that decompresses an lzma-compressed kernel), and linux kernel with initramfs root filesystem.
Path two: Do the build ourselves, using the same sources and build process for trx, lzma-loader, and kernel. The difference is that we're using a slightly different set of configuration options for the kernel, and we're using different root filesystem contents.
In either case, the linux kernel can be booted by activating the serial console and network-booting the device (by telling CFE to download the kernel file using tftp). This works whether it's our own kernel or the openwrt kernel.
When we lzma-compress the openwrt kernel and build a trx using the lzma-loader and compressed kernel, the result is a trx file that can be installed using the rescue mode and works fine.
When we lzma-compress our kernel and build a trx using the same lzma-loader (but our compressed kernel), the result is a trx file that doesn't work.
...Huh.
When we use the OpenWRT kernel with our root filesystem, it boots (although since our rootfs requires FPU emulation and the OpenWRT kernel doesn't provide it, it doesn't actually work properly).
Things to try:
- Describe this situation to the very smart people at OpenWRT, ask if they have any ideas.
- Use the OpenWRT kernel and configuration, substitute in just our root filesystem. See if it boots. (It seems to! But it dies because of the lack of FPU emulation in the kernel.)
- Maybe use the OpenWRT toolchain instead of ours? This would require building all of the root filesystem stuff (really this just means busybox) with a toolchain that supports softfloat.
- Maybe build the OpenWRT kernel using the OpenWRT toolchain but with FPU emulation turned on? (And eventually we'd want to have ext3 and so on in the root filesystem.)
A Solution Exists!¶
It turns out that there's a single kernel configuration setting that was shooting us in the foot, but Brett has temporarily forgotten what it was. Maybe Eric remembers. (Was it something about compressing the initramfs image, maybe?)