Cool.
On Thu, 2008-08-14 at 11:06 -0400, Daniel Drake wrote:
Hi,
As mentioned yesterday, me and Bobby spent a few hours working towards
scripting the process of fixing up a SD-based regular distribution
install to work on XOs...
We started with Fedora 9 and had to make the following changes:
- OLPC kernel (testing branch) and modules with a slightly modified
config (building stuff into the image to avoid needing an initramfs)
- /dev/console needs to be added to Fedora install when you aren't
booting with an initramfs
- /boot/olpc.fth boot script needed
- Display settings from XO's xorg.conf required to avoid things
looking really funky
Things work quite well from that point. Wireless works, suspend too,
mouse/keyboard just fine, ...
More on the initramfs thing:
Fedora doesn't like being booted direct from disk when the disk is
mounted read-only (it tries to write to various files). So we had to
drop the 'ro' boot parameter. That makes Fedora attempt to e2fsck the
root partition when it is mounted read-write, so you get something like
the following prompt on each boot:
running e2fsck on a mounted partition is really dangerous, continue?
(y/n)
We then used the F9 initramfs, which worked (despite about 20 errors
that it couldn't find modules or modules.dep, as you might expect). The
best solution may be rolling a minimal initramfs for our case.
After figuring out the above, I wrote scripts that will take a SD card
where F9 has been vanilla-installed, and it will make the above changes.
TOTALLY UNTESTED but if you want to look, its at
git://dev.laptop.org/~dsd/XO-alt-distro
Will probably spend a few more hours on this on Friday or Monday
evening. We also want to look at the latest alphas for F10 and Ubuntu
intrepid.
I also looked at the USB key that Jim gave me, with his custom minimal
fedora spin. I added my OLPC kernel from above and booted manually using
openfirmware. The initramfs is absolutely needed here because there is
no root fs on the card - the initramfs presumably mounts the squashfs
image and then pivots into that. I reused the existing initramfs
unmodified.
That initramfs tried to load various modules and failed as expected, but
it has logic to abort when such failures are detected. Didn't get any
further than that. It'll certainly require modifying or re-rolling the
initramfs to get this booting on XO.
Yes, it probably loads some modules from the image, and loses; we need
to respin the image so the modules and the booted kernel matches, I
suspect.
If the live CD image then boots, install to disk would be one way to get
it onto the SD card.
Another funky bug: sometimes sdhci fails to initialize during boot,
giving an odd error message which we didn't write down (some kind of
command timeout). This is odd given that we're using an OLPC kernel and
I don't think we've seen this on the XO?
Interesting. Deepak, any clue?
- Jim
--
Jim Gettys <jg(a)laptop.org>
One Laptop Per Child