current u-boot with x-loader

Hello,

is u-boot mainline (with #undef CONFIG_SPL) supposed to work with x-loader
mainline on a beagle-xm?

x-loader mainline + older u-boot mainline (2011.06) -> OK

x-loader mainline + current u-boot mainline (#undef CONFIG_SPL) -> FAIL
Texas Instruments X-Loader 1.5.1 (Jan 24 2012 - 14:51:45)
Beagle xM
Reading boot sector
Loading u-boot.bin from mmc

MLO/SPL + current u-boot mainline (#define CONFIG_SPL) -> OK

in MLO/SPL + current u-boot mainline USB ethernet is not working

in x-loader mainline + older u-boot (git://github.com/koenkooi/u-boot.git,
~2011.06) with some patches USB ethernet is OK

I suppose MLO/SPL is missing some initialisation which are in x-loader to
make USB ethernet work

thanks, regards, p.

Confirmed, I ran into similar problems with my beaglebone. One of the (newer) MLO files (size 37151 instead of 37279 bytes) caused ethernet not to work.

-- Bas

> is u-boot mainline (with #undef CONFIG_SPL) supposed to work with x-loader
> mainline on a beagle-xm?

Confirmed, I ran into similar problems with my beaglebone. One of the
(newer) MLO files (size 37151 instead of 37279 bytes) caused ethernet
not to work.

Tom Rini had some good answers on the u-boot mail list

1. newer u-boot version (post v2011.09) do not work with x-loader even
with #undef CONFIG_SPL
2. USB ethernet works in recent mainline u-boot versions (v2011.09 and
up); one has to say 'dc off' (data cache off) before 'usb start'

p.

i'd really like some clarification on what is known to work and what
is known not to work since this is *exactly* the sort of thing i'm
trying to document.

  i (think) i can confirm that i can build, from the git clone of
u-boot, both an MLO and u-boot.img that works just fine on my xM, and
i documented the process here (along with some caveats courtesy of
robert nelson):

http://www.crashcourse.ca/wiki/index.php/BeagleBoard-xM#Rebuilding_MLO_and_u-boot.img_for_the_fun_of_it

  i haven't tested ethernet yet, so it's possible that that is still
an issue. but regarding what i've documented, does it seem
reasonable? it works reliably for me, so if there's still some
underlying problem with what i've tested, i'd like to know what it is
so i can mention it.

rday

p.s. if there's any variation someone wants me to test, i'd be happy
to do that. and, by the way, my MLO file as generated is 45444 bytes.

Thanks for the info. I haven't researched the matter because I found a working combination (that I can build from source). But now I've got an idea where to look if I run into problems again.

-- Bas

http://www.crashcourse.ca/wiki/index.php/BeagleBoard-xM#Rebuilding_ML
i haven't tested ethernet yet, so it's possible that that is still
an issue. but regarding what i've documented, does it seem
reasonable? it works reliably for me, so if there's still some
underlying problem with what i've tested, i'd like to know what it is
so i can mention it.

some comments on your wiki:

toolchains: I think the easiest to get/use are the stock Ubuntu and
Linaro ones, they are also fairly recent

Rebuilding MLO: I'd mention CROSS_COMPILE= for the 'make
omap3_beagle_config'

p.

> http://www.crashcourse.ca/wiki/index.php/BeagleBoard-xM#Rebuilding_ML
> i haven't tested ethernet yet, so it's possible that that is still
> an issue. but regarding what i've documented, does it seem
> reasonable? it works reliably for me, so if there's still some
> underlying problem with what i've tested, i'd like to know what it is
> so i can mention it.

some comments on your wiki:

toolchains: I think the easiest to get/use are the stock Ubuntu and
Linaro ones, they are also fairly recent

  the last time i looked, the stock ubuntu toolchain didn't work
(segmentation fault?) when compiling u-boot. i tried it again just
now, and now it seems fine. that would be the ubuntu
"gcc-arm-linux-gnueabi" package, for which:

$ arm-linux-gnueabi-gcc -v
Using built-in specs.
COLLECT_GCC=arm-linux-gnueabi-gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/arm-linux-gnueabi/4.6.1/lto-wrapper
Target: arm-linux-gnueabi
Configured with: ../src/configure -v --with-pkgversion='Ubuntu/Linaro
4.6.1-9ubuntu3'
--with-bugurl=file:///usr/share/doc/gcc-4.6/README.Bugs
--enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr
--program-suffix=-4.6 --enable-shared --enable-linker-build-id
--with-system-zlib --libexecdir=/usr/lib --without-included-gettext
--enable-threads=posix
--with-gxx-include-dir=/usr/arm-linux-gnueabi/include/c++/4.6.1
--libdir=/usr/lib --enable-nls --enable-clocale=gnu
--enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-plugin
--enable-objc-gc --enable-multilib --disable-sjlj-exceptions
--with-arch=armv7-a --with-float=softfp --with-fpu=vfpv3-d16
--with-mode=thumb --disable-werror --enable-checking=release
--build=x86_64-linux-gnu --host=x86_64-linux-gnu
--target=arm-linux-gnueabi --program-prefix=arm-linux-gnueabi-
--includedir=/usr/arm-linux-gnueabi/include
--with-headers=/usr/arm-linux-gnueabi/include
--with-libs=/usr/arm-linux-gnueabi/lib
Thread model: posix
gcc version 4.6.1 (Ubuntu/Linaro 4.6.1-9ubuntu3)
$

  i thought there was a known issue with the 4.6.1-based toolchain for
which there would be a fix in 4.6.2. but suddenly, things are fine --
was there an upgrade that i might have installed without noticing?

Rebuilding MLO: I'd mention CROSS_COMPILE= for the 'make
omap3_beagle_config'

  that was one of those things that i just assumed readers would know
about -- properly setting CROSS_COMPILE, either on the command line,
or in their environment.

  so now i'm curious about toolchains -- is there a canonical list of
toolchains that are known to work in this context? it would be nice
to have a reasonably complete list.

rday

ok, after a bit of testing ...

> http://www.crashcourse.ca/wiki/index.php/BeagleBoard-xM#Rebuilding_ML

> i haven't tested ethernet yet, so it's possible that that is still
> an issue. but regarding what i've documented, does it seem
> reasonable? it works reliably for me, so if there's still some
> underlying problem with what i've tested, i'd like to know what it
> is so i can mention it.

some comments on your wiki:

toolchains: I think the easiest to get/use are the stock Ubuntu and
Linaro ones, they are also fairly recent

  on my updated 64-bit ubuntu 11.10 system, i just tested with the
gcc-arm-linux-gnueabi package and the u-boot git repo and it seems to
build. i'm puzzled. i could have sworn that this didn't work several
days ago, which is why i reverted to an earlier ELDK toolchain. so
why does it work *now*? anyone recall the issue with ubuntu's stock
arm toolchain from just a couple weeks ago? i thought it was
something related specifically to gcc 4.6.1 that was going to be
resolved in 4.6.2. but it seems to work now. weird.

Rebuilding MLO: I'd mention CROSS_COMPILE= for the 'make
omap3_beagle_config'

  at the risk of being slightly repetitive, let me explain again why i
started those wiki pages. i'm not trying to duplicate what's out
there, i just want to summarize and coalesce stuff that is absolutely,
positively known to *work* so that others don't need to fight with
stuff.

  i don't want to get into the lengthy discussions of how one verifies
what works, i just want to describe the end result. and more to the
point, i don't want to repeat all of the perfectly respectable
newbie-level docs that are out there.

  that is, i don't want to start writing stuff like, "to install the
toolchain on ubuntu, type 'sudo apt-get install ...', then set the
CROSS_COMPILE variable to ...". i'd like to assume some working
knowledge so i can keep things brief. i want to be able to write
stuff like:

  * start with circuitco xM 4_25 image here
(http://circuitco.com/support/index.php?title=BeagleBoard-xM)

  * install ubuntu arm toolchain package 'gcc-arm-linux-gnueabi'
  * git clone u-boot from [link], set build environment

  $ make omap3_beagle_config
  $ make

  * results:
  new MLO
  new u-boot.img
  * copy to boot partition

that's it, that's all i want to document. i'll get into more detail
when i start writing the courseware based on that, but for now, i want
things concise that are known to work.

  so if you have bits of info you've discovered, feel free to send
them along. eventually, those wiki pages will get fairly
comprehensive but, for now, i'd like to just be able to hand out
recipes that should work for evryone.

rday

p.s. recall that my eventual goal is to write some courseware that
uses things like the beagle and panda for embedded linux classes.
because of that, i'm going to be very focused on writing recipes for
just two platforms:

  * bb xM Rev C
  * panda ES

so for better or worse, i'm not going to care much about what happens
with the original beagle or panda boards. i need to concentrate on
precisely the platforms i plan on using, so i should be able to
guarantee that recipes work. (i'm already going through mark yoder's
class and testing everything there as well.)

  anyway, feel free to read and critique what's on the wiki pages -- i
want to make sure it's correct.