Kernel development setup for XO-1.75

Paul Fox pgf at laptop.org
Wed Jun 6 19:10:14 EDT 2012


martin wrote:
 > { Maybe someone can polish it further and put it into a wikipage. Note
 > that the process and tools change over time a bit... }
 > 
 > Hi new kernel developer,
 > 
 > Here are some hints, meant for a self-sufficient kernel developer to
 > find her/his own way. Some you may know already :-)
 > 
 > - You will want to be on devel at lists.laptop.org for general hacking
 > questions. This is an open list, so no NDA topics. You will see build
 > announcements there.
 > 
 >  - We also use irc -- #olpc-devel on OFTC
 > 
 > - You need to know how to download and install a build (grab the zd
 > file, look in the install instructions for "fs-update").
 > 
 >  - You will want to have your XO setup with a serial port - search our
 > wiki for the Serial adapter page...
 > 
 >  - The kernel that _actually_ boots is in /bootpart/boot/vmlinuz, it
 > then uses an initramfs that invokes dark magic before it invokes a
 > "normal" userland. You can only boot into a usable system through this
 > magic initramfs.
 > 
 > Our current development practice is to provide a kernel via USB (or
 > even WLAN) so
 > that the XO ignores the one on the internal disk. Put the attached
 > olpc.fth file in a FAT formatted USB, inside a "boot" directory. Then
 > put a "zimage" file in the root of the USB disk.

[ alternatively, you can simply install your kernel in /bootpart/boot,
and adjust the vmlinuz symlink accordingly.  if you do this, and
your kernel config is _not_ monolithic, then you'll need to have
put a copy of your modules under /usr/lib/modules.  if you need
to make booting changes (i.e., adjust kernel commandline, etc), you'll
edit /bootpart/boot/olpc.fth. ]

 > 
 > This olpc.fth file controls the boot process, you can tweak boot
 > parameters in there, or tell it to boot a kernel fetched via http over
 > wlan. It is written in Forth.
 > 
 >  - You'll want our git tree: git://dev.laptop.org/olpc-kernel -
 > "master" there follows Linus' kernel. We are currently working on
 > arm-3.0-wip
 > for XO-1.75.
 > 
 >  - Our defconfig file is in arch/arm/configs/xo_175_defconfig. I
 > normally copy it to .config and then perl -pi -e 's/=m/=y/' to make a
 > monolithic kernel that Just Boots.
 > 
 >  - We currently crosscompile our kernels for development  --

if you're running ubuntu/debian, you can simply
    apt-get install gcc-arm-linux-gunabi
and set ARCH="arm" and CROSS_COMPILE="arm-linux-gnuabi-" before
running make as usual.  otherwise, you'll want to untar, as described
below.

paul

 >      Untar http://dev.laptop.org/~cjb/gcc-4.6.0-from-x86_64-to-armv7.tar.bz2
 > to /opt, then
 > 
 > PATH=$PATH:/opt/crosstool/gcc-4.6.0/bin/
 > make ARCH=arm CROSS_COMPILE=armv7-unknown-linux-gnueabi-  <your make
 > target here>
 > 
 >  - We have an autobuilder that makes nice RPMs of the kernels based
 > on our git branches. Once you have a well tested patch, spam someone
 > in our team to get it into the official git repo so that it gets into
 > our RPM'd kernels...
 > 
 > This is merely a start.
 > 
 > 
 > 
 > m
 > --
 >  martin at laptop.org -- Software Architect - OLPC
 >  - ask interesting questions
 >  - don't get distracted with shiny stuff  - working code first
 >  - http://wiki.laptop.org/go/User:Martinlanghoff
 > 
 > 
 > -- 
 >  martin at laptop.org -- Software Architect - OLPC
 >  - ask interesting questions
 >  - don't get distracted with shiny stuff  - working code first
 >  - http://wiki.laptop.org/go/User:Martinlanghoff
 > part 3     text/plain                 129
 > _______________________________________________
 > Devel mailing list
 > Devel at lists.laptop.org
 > http://lists.laptop.org/listinfo/devel

=---------------------
 paul fox, pgf at laptop.org



More information about the Devel mailing list