nv-U-Boot with TFTP boot over USB ethernet device?

945 views
Skip to first unread message

Bill Smith

unread,
Apr 17, 2013, 2:05:14 PM4/17/13
to chromium-...@chromium.org
Hi -

I wanted to try booting a custom kernel via the nv-U-Boot using a TFTP server - which is supposed to be supported.  See here.

However, when I enter the nv-U-Boot shell and try to detect the USB ethernet device, the network hardware is not detected.  Here's what I see in the U-Boot shell:

usb start
(Re)start USB...
USB:   Register 1313 MbrPorts 3
USB EHCI 1.00
2 USB Device(s) found
       scanning bus for storage devices... 0 Storage Device(s) found
       scanning bus for ethernet devices... 0 Ethernet Device(s) found
# usb tree

Device Tree:
  1  Hub (480 Mb/s, 0mA)
  |  u-boot EHCI Host Controller
  |
  +-2  Vendor specific (480 Mb/s, 450mA)
       ASIX Elec. Corp. AX88178  000002
#

Looking at the U-Boot source, there appears to be a driver for this particular device in the following file:

.../src/third_party/u-boot/files/drivers/usb/eth/asix.c

This was added by the "Chromium OS Authors" and should support "ASIX AX8817X based USB 2.0 Ethernet Devices" (from the source file).

I am using the pre-built version of nv-U-Boot downloaded from the page referenced above with this adapter.

Has anyone been able to successfully use nv-U-Boot to load a kernel via TFTP?

If so - what USB-to-ethernet device are you using?

Also - did you have to roll your own nv-U-Boot and enable the USB-ethernet device driver explicitly?  Or should it be supported form the stock nv-U-Boot image?

Thanks.

- Bill

Olof Johansson

unread,
Apr 17, 2013, 7:40:45 PM4/17/13
to bi...@smith-online.org, Chromium OS discuss
Hi Bill,

Did you plug the ethernet device into the 2.0 port, or the 3.0 port? Only 2.0 is supported.


-Olof


2013/4/17 Bill Smith <bi...@smith-online.org>


--
--
Chromium OS discuss mailing list: chromium-...@chromium.org
View archives, change email options, or unsubscribe:
http://groups.google.com/a/chromium.org/group/chromium-os-discuss?hl=en
 
 
 

Bill Smith

unread,
Apr 17, 2013, 9:51:20 PM4/17/13
to chromium-...@chromium.org, bi...@smith-online.org
Hi Olaf -

I am pretty certain I am using the 2.0 port ... the "usb tree" command (see original post) shows that nv-U-Boot can see the USB 2.0 controller (at 480 Mbps) with the Ethernet device attached.

It even shows the type of the device - which should match the native USB Ethernet driver bundled in nv-U-Boot source tree.

If it was on the USB 3.0 port - would "usb tree" even show that the device is attached?

- Bill

Olof Johansson

unread,
Apr 18, 2013, 12:54:41 AM4/18/13
to Bill Smith, Chromium OS discuss



2013/4/17 Bill Smith <bi...@smith-online.org>
Hi Olaf -

I am pretty certain I am using the 2.0 port ... the "usb tree" command (see original post) shows that nv-U-Boot can see the USB 2.0 controller (at 480 Mbps) with the Ethernet device attached.

Ah, sorry -- didn't read the original post properly.
 

It even shows the type of the device - which should match the native USB Ethernet driver bundled in nv-U-Boot source tree.

I suspect the VID:PID (vendor:product id) isn't matching what the driver is looking for. I don't know if it's just a minor spin of the product, or if a whole new driver will be needed.
 

If it was on the USB 3.0 port - would "usb tree" even show that the device is attached?

Nope.


-Olof

Bill Smith

unread,
Apr 18, 2013, 10:51:44 AM4/18/13
to chromium-...@chromium.org, Bill Smith
You're right - the VID and PID don't show up in the driver list of known ASIX devices.

For the record, the values should be as follows:

  Vendor ID  
0x0b95
  Product ID0x1780

for the Plugable USB Ethernet adapter (see here).

I am adding it to the list of "asix_dongles" in the driver and rebuilding nv-U-Boot.

Thanks for your input here.

Bill Smith

unread,
Apr 19, 2013, 8:45:05 AM4/19/13
to chromium-...@chromium.org, Bill Smith
It turns out the build process - as per the instructions here - is broken.  It fails on the following:

emerge-${BOARD} chromeos-ec chromeos-u-boot chromeos-bootimage

when it tries to build chromeos-bootimage.  Note that BOARD is "daisy".

The error messages are rather cryptic - but i have confirmed the problem on three different build environments.

The specific error session that I get is shown below.  Any suggestions here would be welcome.

- Bill

$ emerge-daisy --verbose chromeos-bootimage

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild  N     ] sys-boot/chromeos-bootimage-0.0.2-r64 to /build/daisy/ USE="cros-debug exynos -alex -butterfly -cros_ec -depthcharge -emeraldlake2 -factory-mode -fox -link -lumpy -lumpy64 -mario -memtest -parrot -spring -stout -stumpy -tegra -unified_depthcharge" 0 kB [1]

Total: 1 package (1 new), Size of downloads: 0 kB
Portage tree and overlays:
 [0] /usr/local/portage/stable
 [1] /usr/local/portage/chromiumos


>>> Emerging (1 of 1) sys-boot/chromeos-bootimage-0.0.2-r64 from chromiumos for /build/daisy/
 * Running stacked hooks for pre_pkg_setup
 *    sysroot_build_bin_dir ...                                                                                                              [ ok ]
 * Running stacked hooks for pre_src_unpack
 *    python_multilib_setup ...                                                                                                              [ ok ]
>>> Unpacking source...
>>> Source unpacked in /build/daisy/tmp/portage/sys-boot/chromeos-bootimage-0.0.2-r64/work
>>> Preparing source in /build/daisy/tmp/portage/sys-boot/chromeos-bootimage-0.0.2-r64/work ...
>>> Source prepared.
>>> Configuring source in /build/daisy/tmp/portage/sys-boot/chromeos-bootimage-0.0.2-r64/work ...
>>> Source configured.
>>> Compiling source in /build/daisy/tmp/portage/sys-boot/chromeos-bootimage-0.0.2-r64/work ...
 * Building all images
 * Building images for /build/daisy/firmware/dts/exynos5250-daisy.dts
Unknown machine parameter type 'a'
Unknown machine parameter type 's'
Unknown machine parameter type 'i'
Unknown machine parameter type 'r'
Unknown machine parameter type 'w'
Traceback (most recent call last):
  File "/usr/bin/cros_bundle_firmware", line 255, in <module>
    main()
  File "/usr/bin/cros_bundle_firmware", line 242, in main
    _DoBundle(options, output, tools)
  File "/usr/bin/cros_bundle_firmware", line 103, in _DoBundle
    options.show_map)
  File "/usr/lib64/python2.7/site-packages/bundle_firmware.py", line 1207, in Start
    image, pack = self._CreateImage(gbb, self.fdt)
  File "/usr/lib64/python2.7/site-packages/bundle_firmware.py", line 1091, in _CreateImage
    self._BuildBlob(pack, fdt, blob_type)
  File "/usr/lib64/python2.7/site-packages/bundle_firmware.py", line 1002, in _BuildBlob
    data = self._tools.ReadFile(self.ecro_fname)
  File "/usr/lib64/python2.7/site-packages/tools.py", line 222, in ReadFile
    fd = open(self.Filename(fname), 'rb')
  File "/usr/lib64/python2.7/site-packages/tools.py", line 157, in Filename
    if fname.startswith('##/'):
AttributeError: 'NoneType' object has no attribute 'startswith'
 * ERROR: sys-boot/chromeos-bootimage-0.0.2-r64 failed (compile phase):
 *   failed to build RO image:  --add-blob cros-splash /mnt/host/source/src/third_party/chromiumos-overlay/sys-boot/chromeos-bootimage/files/cros_splash_blob.bin --board daisy --key /build/daisy/usr/share/vboot/devkeys --bmpblk /build/daisy/firmware/bmpblk.bin -D --bl1=/build/daisy/firmware/E5250.nbl1.bin --bl2=/build/daisy/firmware/smdk5250-spl.bin         --dt /build/daisy/firmware/dts/exynos5250-daisy.dts         --uboot /build/daisy/firmware/u-boot.bin                  --bootcmd vboot_twostop         --bootsecure        
 *
 * Call stack:
 *     ebuild.sh, line   56:  Called src_compile
 *   environment, line 2590:  Called src_compile_uboot
 *   environment, line 2669:  Called build_image '/build/daisy/firmware/dts/exynos5250-daisy.dts' '/build/daisy/firmware/u-boot.bin' ' --add-blob cros-splash /mnt/host/source/src/third_party/chromiumos-overlay/sys-boot/chromeos-bootimage/files/cros_splash_blob.bin --board daisy --key /build/daisy/usr/share/vboot/devkeys --bmpblk /build/daisy/firmware/bmpblk.bin' ''
 *   environment, line  444:  Called die
 * The specific snippet of code:
 *       cros_bundle_firmware ${cmdline} --outdir "out-${board}.ro" --output "image-${board}.bin" || die "failed to build RO image: ${cmdline}";
 *
 * If you need support, post the output of 'emerge --info =sys-boot/chromeos-bootimage-0.0.2-r64',
 * the complete build log and the output of 'emerge -pqv =sys-boot/chromeos-bootimage-0.0.2-r64'.
 * This ebuild used the following eclasses from overlays:
 *   /mnt/host/source/src/third_party/chromiumos-overlay/eclass/cros-debug.eclass
 *   /mnt/host/source/src/third_party/chromiumos-overlay/eclass/toolchain-funcs.eclass
 *   /mnt/host/source/src/third_party/chromiumos-overlay/eclass/binutils-funcs.eclass
 * This ebuild is from an overlay named 'chromiumos': '/mnt/host/source/src/third_party/chromiumos-overlay/'
 * The complete build log is located at '/build/daisy/tmp/portage/logs/sys-boot:chromeos-bootimage-0.0.2-r64:20130419-123155.log'.
 * The ebuild environment file is located at '/build/daisy/tmp/portage/sys-boot/chromeos-bootimage-0.0.2-r64/temp/environment'.
 * S: '/build/daisy/tmp/portage/sys-boot/chromeos-bootimage-0.0.2-r64/work'

>>> Failed to emerge sys-boot/chromeos-bootimage-0.0.2-r64 for /build/daisy/, Log file:

>>>  '/build/daisy/tmp/portage/logs/sys-boot:chromeos-bootimage-0.0.2-r64:20130419-123155.log'

 * Messages for package sys-boot/chromeos-bootimage-0.0.2-r64 merged to /build/daisy/:

 * ERROR: sys-boot/chromeos-bootimage-0.0.2-r64 failed (compile phase):
 *   failed to build RO image:  --add-blob cros-splash /mnt/host/source/src/third_party/chromiumos-overlay/sys-boot/chromeos-bootimage/files/cros_splash_blob.bin --board daisy --key /build/daisy/usr/share/vboot/devkeys --bmpblk /build/daisy/firmware/bmpblk.bin -D --bl1=/build/daisy/firmware/E5250.nbl1.bin --bl2=/build/daisy/firmware/smdk5250-spl.bin         --dt /build/daisy/firmware/dts/exynos5250-daisy.dts         --uboot /build/daisy/firmware/u-boot.bin                  --bootcmd vboot_twostop         --bootsecure        
 *
 * Call stack:
 *     ebuild.sh, line   56:  Called src_compile
 *   environment, line 2590:  Called src_compile_uboot
 *   environment, line 2669:  Called build_image '/build/daisy/firmware/dts/exynos5250-daisy.dts' '/build/daisy/firmware/u-boot.bin' ' --add-blob cros-splash /mnt/host/source/src/third_party/chromiumos-overlay/sys-boot/chromeos-bootimage/files/cros_splash_blob.bin --board daisy --key /build/daisy/usr/share/vboot/devkeys --bmpblk /build/daisy/firmware/bmpblk.bin' ''
 *   environment, line  444:  Called die
 * The specific snippet of code:
 *       cros_bundle_firmware ${cmdline} --outdir "out-${board}.ro" --output "image-${board}.bin" || die "failed to build RO image: ${cmdline}";
 *
 * If you need support, post the output of 'emerge --info =sys-boot/chromeos-bootimage-0.0.2-r64',
 * the complete build log and the output of 'emerge -pqv =sys-boot/chromeos-bootimage-0.0.2-r64'.
 * This ebuild used the following eclasses from overlays:
 *   /mnt/host/source/src/third_party/chromiumos-overlay/eclass/cros-debug.eclass
 *   /mnt/host/source/src/third_party/chromiumos-overlay/eclass/toolchain-funcs.eclass
 *   /mnt/host/source/src/third_party/chromiumos-overlay/eclass/binutils-funcs.eclass
 * This ebuild is from an overlay named 'chromiumos': '/mnt/host/source/src/third_party/chromiumos-overlay/'
 * The complete build log is located at '/build/daisy/tmp/portage/logs/sys-boot:chromeos-bootimage-0.0.2-r64:20130419-123155.log'.
 * The ebuild environment file is located at '/build/daisy/tmp/portage/sys-boot/chromeos-bootimage-0.0.2-r64/temp/environment'.
 * S: '/build/daisy/tmp/portage/sys-boot/chromeos-bootimage-0.0.2-r64/work'


Vadim Bendebury

unread,
Apr 19, 2013, 9:22:29 AM4/19/13
to bi...@smith-online.org, Chromium OS discuss
I am not sure what you are trying to accomplish and how close you want/have to stay with the chrome OS build process .

This particular problem is caused by the fact that some components of the image are not found in /build/daisy/firmware (could you have deleted this directory or files in it before?).

You can try running

emerge-daisy -ev chromeos-bootimage 

this will take a long time, but all dependencies of the bootimage would be rebuilt (including missing files), this needs to be run only once.

Another alternative is to build the bootimage 'manually' invoking the bundling utility from the command line and omitting nonessential components. I can send you the command line later.

--vb
 
On Thursday, April 18, 2013 10:51:44 AM UTC-4, Bill Smith wrote:
You're right - the VID and PID don't show up in the driver list of known ASIX devices.

For the record, the values should be as follows:

  Vendor ID  
0x0b95
  Product ID0x1780

for the Plugable USB Ethernet adapter (see here).

I am adding it to the list of "asix_dongles" in the driver and rebuilding nv-U-Boot.

Thanks for your input here.

On Thursday, April 18, 2013 12:54:41 AM UTC-4, Olof Johansson wrote:



2013/4/17 Bill Smith <bi...@smith-online.org>
Hi Olaf -

I am pretty certain I am using the 2.0 port ... the "usb tree" command (see original post) shows that nv-U-Boot can see the USB 2.0 controller (at 480 Mbps) with the Ethernet device attached.

Ah, sorry -- didn't read the original post properly.
 

It even shows the type of the device - which should match the native USB Ethernet driver bundled in nv-U-Boot source tree.

I suspect the VID:PID (vendor:product id) isn't matching what the driver is looking for. I don't know if it's just a minor spin of the product, or if a whole new driver will be needed.
 

If it was on the USB 3.0 port - would "usb tree" even show that the device is attached?

Nope.


-Olof

--

Bill Smith

unread,
Apr 19, 2013, 10:51:44 AM4/19/13
to chromium-...@chromium.org, bi...@smith-online.org
I tried your suggestion of using "emerge -ev chromeos-bootimage" for the build in two different environments.

The first environment I used had a minor driver change to add my USB Ethernet dongle device to the list of supported devices (see earlier thread for context) so that I can use nv-U-Boot with a TFTP server.

It failed the same way as before with the same error messages.

The second environment I used was a pristine environment that had a fresh "repo sync" this morning.  It failed with the same error message as before.

Given that it fails in a pristine build environment for me, you might be able to reproduce this.

Note that I am able to run "./build-packages --board=daisy" and "./build-images ..." and actually boot these images from SD cards.  But this process does not actually build the nv-U-Boot binaries that I need, so I suspect that chromeos-bootimage must not actually be part of the standard image set as I don't see the nv-U-Boot artificats generated in the firmware directory.

I have used U-Boot for other hardware and we normally use TFTP boot when we are working on the kernel, so I was happy to see that this was supposed to be supported.

Thank you for your insights on this.

- Bill

Vadim Bendebury

unread,
Apr 19, 2013, 12:23:29 PM4/19/13
to Bill Smith, Chromium OS discuss
On Fri, Apr 19, 2013 at 7:51 AM, Bill Smith <bi...@smith-online.org> wrote:
I tried your suggestion of using "emerge -ev chromeos-bootimage" for the build in two different environments.

The first environment I used had a minor driver change to add my USB Ethernet dongle device to the list of supported devices (see earlier thread for context) so that I can use nv-U-Boot with a TFTP server.

It failed the same way as before with the same error messages.

The second environment I used was a pristine environment that had a fresh "repo sync" this morning.  It failed with the same error message as before.

Given that it fails in a pristine build environment for me, you might be able to reproduce this.

Note that I am able to run "./build-packages --board=daisy" and "./build-images ..." and actually boot these images from SD cards.  But this process does not actually build the nv-U-Boot binaries that I need, so I suspect that chromeos-bootimage must not actually be part of the standard image set as I don't see the nv-U-Boot artificats generated in the firmware directory.

I have used U-Boot for other hardware and we normally use TFTP boot when we are working on the kernel, so I was happy to see that this was supposed to be supported.

Thank you for your insights on this.


are you sure you get exactly the same error? Just in case, please post the error message again here,

--vb

Bill Smith

unread,
Apr 19, 2013, 1:08:59 PM4/19/13
to chromium-...@chromium.org, Bill Smith
I tried to attach the log file for "emerge-daisy -ev chromeos-bootimage" ... but my company's proxy server prevents this from working.

So here is another cut & paste. If there's other information you would like to see - let me know.

Thanks.

- Bill

>>> Emerging (20 of 20) sys-boot/chromeos-bootimage-0.0.2-r64 from chromiumos for /build/daisy/
 * The complete build log is located at '/build/daisy/tmp/portage/logs/sys-boot:chromeos-bootimage-0.0.2-r64:20130419-165640.log'.

 * The ebuild environment file is located at '/build/daisy/tmp/portage/sys-boot/chromeos-bootimage-0.0.2-r64/temp/environment'.
 * S: '/build/daisy/tmp/portage/sys-boot/chromeos-bootimage-0.0.2-r64/work'

>>> Failed to emerge sys-boot/chromeos-bootimage-0.0.2-r64 for /build/daisy/, Log file:

>>>  '/build/daisy/tmp/portage/logs/sys-boot:chromeos-bootimage-0.0.2-r64:20130419-165640.log'

 * Messages for package sys-boot/chromeos-bmpblk-0.0.3-r1 merged to /build/daisy/:

 * Checking for cached /var/cache/chromeos-cache/distfiles/target/cros-binary/bmpblk-0.0.3.bin
 * Not downloading, cached copy available in /var/cache/chromeos-cache/distfiles/target/cros-binary/bmpblk-0.0.3.bin
 * Checking for cached /var/cache/chromeos-cache/distfiles/target/cros-binary/bmpblk-0.0.3.bin

 * Messages for package sys-boot/chromeos-u-boot-9999 merged to /build/daisy/:

 * Using U-Boot config: chromeos_daisy_config
 * Installing device tree files in board/samsung/dts
 * Installing device tree files in arch/arm/dts
 * Installing device tree files in cros/dts

 * Messages for package sys-apps/util-linux-2.21.2-r1 merged to /build/daisy/:

 * The agetty util now clears the terminal by default.  You
 * might want to add --noclear to your /etc/inittab lines.

 * Messages for package app-crypt/trousers-0.3.3-r31 merged to /build/daisy/:

 * If you have problems starting tcsd, please check permissions and
 * ownership on /dev/tpm* and ~tss/system.data


 * Messages for package sys-boot/chromeos-bootimage-0.0.2-r64 merged to /build/daisy/:

 * ERROR: sys-boot/chromeos-bootimage-0.0.2-r64 failed (compile phase):
 *   failed to build RO image:  --add-blob cros-splash /mnt/host/source/src/third_party/chromiumos-overlay/sys-boot/chromeos-bootimage/files/cros_splash_blob.bin --board daisy --key /build/daisy/usr/share/vboot/devkeys --bmpblk /build/daisy/firmware/bmpblk.bin -D --bl1=/build/daisy/firmware/E5250.nbl1.bin --bl2=/build/daisy/firmware/smdk5250-spl.bin         --dt /build/daisy/firmware/dts/exynos5250-daisy.dts         --uboot /build/daisy/firmware/u-boot.bin                  --bootcmd vboot_twostop         --bootsecure        
 *
 * Call stack:
 *     ebuild.sh, line   56:  Called src_compile
 *   environment, line 2590:  Called src_compile_uboot
 *   environment, line 2669:  Called build_image '/build/daisy/firmware/dts/exynos5250-daisy.dts' '/build/daisy/firmware/u-boot.bin' ' --add-blob cros-splash /mnt/host/source/src/third_party/chromiumos-overlay/sys-boot/chromeos-bootimage/files/cros_splash_blob.bin --board daisy --key /build/daisy/usr/share/vboot/devkeys --bmpblk /build/daisy/firmware/bmpblk.bin' ''
 *   environment, line  444:  Called die
 * The specific snippet of code:
 *       cros_bundle_firmware ${cmdline} --outdir "out-${board}.ro" --output "image-${board}.bin" || die "failed to build RO image: ${cmdline}";
 *
 * If you need support, post the output of 'emerge --info =sys-boot/chromeos-bootimage-0.0.2-r64',
 * the complete build log and the output of 'emerge -pqv =sys-boot/chromeos-bootimage-0.0.2-r64'.
 * This ebuild used the following eclasses from overlays:
 *   /mnt/host/source/src/third_party/chromiumos-overlay/eclass/cros-debug.eclass
 *   /mnt/host/source/src/third_party/chromiumos-overlay/eclass/toolchain-funcs.eclass
 *   /mnt/host/source/src/third_party/chromiumos-overlay/eclass/binutils-funcs.eclass
 * This ebuild is from an overlay named 'chromiumos': '/mnt/host/source/src/third_party/chromiumos-overlay/'
 * The complete build log is located at '/build/daisy/tmp/portage/logs/sys-boot:chromeos-bootimage-0.0.2-r64:20130419-165640.log'.

 * The ebuild environment file is located at '/build/daisy/tmp/portage/sys-boot/chromeos-bootimage-0.0.2-r64/temp/environment'.
 * S: '/build/daisy/tmp/portage/sys-boot/chromeos-bootimage-0.0.2-r64/work'

Vadim Bendebury

unread,
Apr 19, 2013, 1:19:12 PM4/19/13
to Bill Smith, Chromium OS discuss
once you ran emerge-daisy -ev chromeos-bootimage, do not run it with `-ev' anymore, it is just a waste of time.

The last snippet does not actually show what exactly went wrong - it this because --verbose was omitted from the invocation line? What does

emerge-daisy --verbose chromeos-bootimage

show?

-vb

Bill Smith

unread,
Apr 19, 2013, 1:33:21 PM4/19/13
to chromium-...@chromium.org, Bill Smith
Here is is with verbose mode ... 

- Bill

(cr) smithwd@cyberdev ~ $ emerge-daisy --verbose chromeos-bootimage
 * The complete build log is located at '/build/daisy/tmp/portage/logs/sys-boot:chromeos-bootimage-0.0.2-r64:20130419-172855.log'.
 * The ebuild environment file is located at '/build/daisy/tmp/portage/sys-boot/chromeos-bootimage-0.0.2-r64/temp/environment'.
 * S: '/build/daisy/tmp/portage/sys-boot/chromeos-bootimage-0.0.2-r64/work'

>>> Failed to emerge sys-boot/chromeos-bootimage-0.0.2-r64 for /build/daisy/, Log file:

>>>  '/build/daisy/tmp/portage/logs/sys-boot:chromeos-bootimage-0.0.2-r64:20130419-172855.log'

 * Messages for package sys-boot/chromeos-bootimage-0.0.2-r64 merged to /build/daisy/:

 * ERROR: sys-boot/chromeos-bootimage-0.0.2-r64 failed (compile phase):
 *   failed to build RO image:  --add-blob cros-splash /mnt/host/source/src/third_party/chromiumos-overlay/sys-boot/chromeos-bootimage/files/cros_splash_blob.bin --board daisy --key /build/daisy/usr/share/vboot/devkeys --bmpblk /build/daisy/firmware/bmpblk.bin -D --bl1=/build/daisy/firmware/E5250.nbl1.bin --bl2=/build/daisy/firmware/smdk5250-spl.bin --dt /build/daisy/firmware/dts/exynos5250-daisy.dts --uboot /build/daisy/firmware/u-boot.bin --bootcmd vboot_twostop --bootsecure
 * 
 * Call stack:
 *     ebuild.sh, line   56:  Called src_compile
 *   environment, line 2590:  Called src_compile_uboot
 *   environment, line 2669:  Called build_image '/build/daisy/firmware/dts/exynos5250-daisy.dts' '/build/daisy/firmware/u-boot.bin' ' --add-blob cros-splash /mnt/host/source/src/third_party/chromiumos-overlay/sys-boot/chromeos-bootimage/files/cros_splash_blob.bin --board daisy --key /build/daisy/usr/share/vboot/devkeys --bmpblk /build/daisy/firmware/bmpblk.bin' ''
 *   environment, line  444:  Called die
 * The specific snippet of code:
 *       cros_bundle_firmware ${cmdline} --outdir "out-${board}.ro" --output "image-${board}.bin" || die "failed to build RO image: ${cmdline}";
 * 
 * If you need support, post the output of 'emerge --info =sys-boot/chromeos-bootimage-0.0.2-r64',
 * the complete build log and the output of 'emerge -pqv =sys-boot/chromeos-bootimage-0.0.2-r64'.
 * This ebuild used the following eclasses from overlays:
 *   /mnt/host/source/src/third_party/chromiumos-overlay/eclass/cros-debug.eclass
 *   /mnt/host/source/src/third_party/chromiumos-overlay/eclass/toolchain-funcs.eclass
 *   /mnt/host/source/src/third_party/chromiumos-overlay/eclass/binutils-funcs.eclass
 * This ebuild is from an overlay named 'chromiumos': '/mnt/host/source/src/third_party/chromiumos-overlay/'
 * The complete build log is located at '/build/daisy/tmp/portage/logs/sys-boot:chromeos-bootimage-0.0.2-r64:20130419-172855.log'.
 * The ebuild environment file is located at '/build/daisy/tmp/portage/sys-boot/chromeos-bootimage-0.0.2-r64/temp/environment'.
 * S: '/build/daisy/tmp/portage/sys-boot/chromeos-bootimage-0.0.2-r64/work'
(cr) smithwd@cyberdev ~ $ 

Vadim Bendebury

unread,
Apr 19, 2013, 1:54:26 PM4/19/13
to Bill Smith, Chromium OS discuss
Interesting. We're almost there :) What do these commands print on the console:

emerge-daisy -pev chromeos-bootimage
$ (cd ~/trunk/src/third_party/chromiumos-overlay/sys-boot/chromeos-bootimage/; git log  --oneline -n1 chromeos-bootimage-0.0.2.ebuild)


-vb

Bill Smith

unread,
Apr 19, 2013, 2:01:29 PM4/19/13
to chromium-...@chromium.org, Bill Smith
Here is the first command ...

(cr) smithwd@cyberdev ~ $ emerge-daisy -pev chromeos-bootimage

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild   R    ] sys-libs/zlib-1.2.7 to /build/daisy/ USE="static-libs -minizip" 0 kB [0]
[ebuild   R    ] sys-apps/diffutils-3.2 to /build/daisy/ USE="-nls -static" 0 kB [0]
[ebuild   R    ] sys-devel/autoconf-wrapper-10-r1 to /build/daisy/ 0 kB [0]
[ebuild   R    ] sys-libs/ncurses-5.9-r2 to /build/daisy/ USE="cxx minimal unicode (-ada) -debug -doc -gpm -profile -static-libs -tinfo -trace" 0 kB [0]
[ebuild   R    ] sys-devel/automake-wrapper-5 to /build/daisy/ 0 kB [0]
[ebuild   R    ] app-arch/xz-utils-4.999.9_beta to /build/daisy/ USE="static-libs threads -nls" 0 kB [0]
[ebuild   R    ] sys-boot/chromeos-bmpblk-0.0.3-r1 to /build/daisy/ 0 kB [1]
[ebuild   R    ] sys-boot/exynos-pre-boot-0.0.2-r8 to /build/daisy/ 0 kB [2]
[ebuild   R   ~] sys-boot/chromeos-u-boot-9999 to /build/daisy/ USE="cros-debug -cros_host -dev -factory-mode -profiling" BOARD_USE="daisy -amd64-corei7 -amd64-drm -amd64-generic -amd64-host -aries -arm-generic -beaglebone -butterfly -cardhu -chronos -daisy-drm -daisy_snow -daisy_spring -dalmore -emeraldlake2 -fb1 -fox -fox_baskingridge -fox_wtm1 -fox_wtm2 -ironhide -kiev -klang -link -lumpy -panda -parrot -peach -peach_pit -puppy -raspberrypi -ricochet -sonic -stout -stout32 -stumpy -tegra2 -tegra2_aebl -tegra2_arthur -tegra2_asymptote -tegra2_dev-board -tegra2_dev-board-opengl -tegra2_kaen -tegra2_seaboard -tegra2_wario -tegra3-generic -waluigi -x32-generic -x86-agz -x86-alex -x86-alex32 -x86-alex32_he -x86-alex_he -x86-alex_hubble -x86-dogfood -x86-drm -x86-fruitloop -x86-generic -x86-mario -x86-mario64 -x86-pineview -x86-wayland -x86-zgb -x86-zgb32 -x86-zgb32_he -x86-zgb_he" U_BOOT_CONFIG_USE="daisy -beaglebone -coreboot -seaboard -waluigi" 0 kB [1]
[ebuild   R    ] sys-devel/autoconf-2.68 to /build/daisy/ USE="-emacs" 0 kB [0]
[ebuild   R    ] sys-devel/automake-1.11.1 to /build/daisy/ 0 kB [0]
[ebuild   R    ] sys-kernel/linux-headers-3.4-r6 to /build/daisy/ 0 kB [1]
[ebuild   R    ] dev-libs/openssl-1.0.1c-r8 to /build/daisy/ USE="bindist zlib -gmp -heartbeat -kerberos -profiling -rfc3779 (-sse2) -static-libs -test -vanilla" 0 kB [1]
[ebuild   R    ] virtual/u-boot-1 to /build/daisy/ 0 kB [1]
[ebuild   R    ] sys-devel/libtool-2.4-r1 to /build/daisy/ USE="-test -vanilla" 0 kB [0]
[ebuild   R    ] virtual/os-headers-0 to /build/daisy/ 0 kB [0]
[ebuild   R    ] sys-apps/util-linux-2.21.2-r1 to /build/daisy/ USE="cramfs crypt ncurses static-libs unicode -ddate -nls -old-linux -perl (-selinux) -slang -suid (-uclibc) -udev" 0 kB [0]
[ebuild   R    ] app-crypt/trousers-0.3.3-r31 to /build/daisy/ USE="-doc -profiling -tss_trace" 0 kB [1]
[ebuild   R    ] chromeos-base/vboot_reference-1.0-r865 to /build/daisy/ USE="cros-debug minimal -32bit_au -cros_host -profiling -tpmtests" 0 kB [1]
[ebuild  N     ] sys-boot/chromeos-bootimage-0.0.2-r64 to /build/daisy/ USE="cros-debug exynos -alex -butterfly -cros_ec -depthcharge -emeraldlake2 -factory-mode -fox -link -lumpy -lumpy64 -mario -memtest -parrot -spring -stout -stumpy -tegra -unified_depthcharge" 0 kB [1]

Total: 20 packages (1 new, 19 reinstalls), Size of downloads: 0 kB
Portage tree and overlays:
 [0] /usr/local/portage/stable
 [1] /usr/local/portage/chromiumos
 [2] /mnt/host/source/src/overlays/overlay-daisy
(cr) smithwd@cyberdev ~ $ 


Here's the second command:

(cd ~/trunk/src/third_party/chromiumos-overlay/sys-boot/chromeos-bootimage/; git log  --oneline -n1 chromeos-bootimage-0.0.2.ebuild)

798983d Clean up chromeos-bootimage ebuild

Vadim Bendebury

unread,
Apr 19, 2013, 2:52:08 PM4/19/13
to Bill Smith, Chromium OS discuss
Oh well, it is kind of messy, the problem is that I am building using the internal manifest and some packages are not available when using the external manifest.

The good thing is that you don't need them anyways, the bad thing is thatwi thout modifying u-boot source device trees you need to pretend that you have them.

This command should work instead of `emerge-daisy chromeos-bootimage', *after* `emerge-daisy chromeos-u-boot'  :

cros_bundle_firmware --add-blob cros-splash /dev/null --board daisy --key /build/daisy/usr/share/vboot/devkeys --bmpblk /build/daisy/firmware/bmpblk.bin --ecro /dev/null --ec /dev/null -D --bl1=/build/daisy/firmware/E5250.nbl1.bin --bl2=/build/daisy/firmware/smdk5250-spl.bin --dt /build/daisy/firmware/dts/exynos5250-snow.dts --uboot /build/daisy/firmware/u-boot.bin --add-config-int load_env 1 --add-node-enable console 1 --outdir /tmp/daisy --output /tmp/daisy/bootimage.bin


The bootable image is  /tmp/daisy/bootimage.bin

let me know if there are problems trying to build/run that,

--vb

Bill Smith

unread,
Apr 19, 2013, 3:35:59 PM4/19/13
to chromium-...@chromium.org, Bill Smith
That last suggestion appears to have built without error:

(cr) smithwd@cyberdev ~ $ cros_bundle_firmware --add-blob cros-splash /dev/null --board daisy --key /build/daisy/usr/share/vboot/devkeys --bmpblk /build/daisy/firmware/bmpblk.bin --ecro /dev/null --ec /dev/null -D --bl1=/build/daisy/firmware/E5250.nbl1.bin --bl2=/build/daisy/firmware/smdk5250-spl.bin --dt /build/daisy/firmware/dts/exynos5250-snow.dts --uboot /build/daisy/firmware/u-boot.bin --add-config-int load_env 1 --add-node-enable console 1 --outdir /tmp/daisy --output /tmp/daisy/bootimage.bin
Unknown machine parameter type 'a'
Unknown machine parameter type 's'
Unknown machine parameter type 'i'
Unknown machine parameter type 'r'
Unknown machine parameter type 'w'
Warning: Flash map has a gap of 61184 bytes: fmap: 000a0000-000a1000, ro-frid: 000aff00-000b0000
Warning: Flash map has a gap of 4096 bytes: gbb: 000b0000-0019f000, ro-vpd: 001a0000-001b0000
(cr) smithwd@cyberdev ~ $ 

But which version of U-Boot am I actually building here?

I was hoping to get nv-U-Boot that would allow me to drop into a U-Boot shell with access to the TFTP server, etc. This one does not drop into the U-Boot shell - but boots directly to the OS.  So I suspect that this might be the RO version (there appear to be three versions: RO, RW and netboot version of U-Boot images).  I think I want the netboot image - so I presumably I need a different set of arguments to the cros_bundle_firmware script.  

After some digging around, I think these are some of the parameters required to build the netboot version - are these correct?

cros_bundle_firmware \
 --add-blob cros-splash /dev/null \
 --board daisy \
 --key /build/daisy/usr/share/vboot/devkeys \
 --bmpblk /build/daisy/firmware/bmpblk.bin \
 --ecro /dev/null \
 --ec /dev/null \
 -D \
 --bl1=/build/daisy/firmware/E5250.nbl1.bin \
 --bl2=/build/daisy/firmware/smdk5250-spl.bin \
 --dt /build/daisy/firmware/dts/exynos5250-snow.dts \
 --uboot /build/daisy/firmware/u-boot.bin \
 --bootcmd vboot_twostop \
 --bootsecure \
 --add-config-int load_env 1 \
 --add-node-enable console 1 \
 --outdir /tmp/daisy \
 --output /tmp/daisy/bootimage.bin

I am kind of operating blind here.  This built an image - but it doesn't actually boot - nor does it drop into a U-Boot shell.

Any suggestions on that?

Thanks.

- Bill

Mike Frysinger

unread,
Apr 19, 2013, 4:34:10 PM4/19/13
to bi...@smith-online.org, Chromium OS discuss
cros_bundle_firmware is for producing a complete BIOS image (which is u-boot, the EC, random files, etc...).  it is not for producing a standalone nv-u-boot image.  that image is built & bundled into the final BIOS image.

that's why the documentation talks about processing the nv image directly and not the image-xxx.bin file.
-mike

Vadim Bendebury

unread,
Apr 19, 2013, 4:48:57 PM4/19/13
to Bill Smith, Chromium OS discuss, Mike Frysinger
cros_bundle_firmware is good enough for producing a standalone image.

You can stop boot process by hitting any key while the system is coming up. You can modify bootcmd environment variable to prevent it from booting kernel. (use the cros_bundle_firmware  --bootcmd command line parameter for this).

--vb
Reply all
Reply to author
Forward
This conversation is locked
You cannot reply and perform actions on locked conversations.
0 new messages