Welcome! Log In Create A New Profile

Advanced

2015.10 U-Boot for Pogoplug V3 (OXNAS OX820)

Posted by bodhi 
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
March 07, 2015 10:02PM
OK I could boot (unsupervised) with the specially prepared sata disk if the u-boot.env file included in shv's ox820-sata-uboot.tar disk prep package didin't boot from uImage only (dt_sata_boot=ext2load ide 0:1 $uimage_addr /boot/uImage_2.6.31.14_OX820_1.2_shv.Pro; bootm $uimage_addr). And unfortunately the only way I have read to create and / or modify the u-boot-env file is with the mkenvimage tool which I don't know how to load onto the linux box I am preparing the special disk with. Do you happend to have a u-boot-env file you could post that is for the latest rootfs that loads uImage, uInitrd and the dtb (in /boot or /boot/dts correspondingly) files and then boots from their memory locations? Or if you could provide some pointers on how to load mkenvimage on my linux box that would work too.

Edit: I just realized something. What if I do the following below and rename the resulting created uImage (with embedded dtb) to uImage_2.6.31.14_OX820_1.2_shv.Pro?

cd /media/sdb1/boot
cp -a zImage-3.17.0-oxnas-tld-1 zImage-3.17.0-oxnas-tld-1.fdt
cat dts/ox820-pogoplug-pro.dtb >> zImage-3.17.0-oxnas-tld-1.fdt
mkimage -A arm -O linux -C none -T kernel -a 0x60008000 -e 0x60008000 -n 'Linux-3.3.17.0-oxnas-tld-1' -d zImage-3.17.0-oxnas-tld-1.fdt uImage_2.6.31.14_OX820_1.2_shv.Pro
sync



Edited 1 time(s). Last edit at 03/07/2015 10:11PM by LeggoMyEggo.
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
March 08, 2015 04:53PM
@ LeggoMyEggo,

Please install and try this release version. You only need to flash u-boot image (the SPL and Pogo env are the same images).

Dropbox:
uboot.2013.10-tld-5.ox820.bodhi.tar
md5:
bf385f83b42cdeee1f2ecbf53f6cdec5

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
March 08, 2015 05:26PM
bodhi Wrote:
-------------------------------------------------------
> @ LeggoMyEggo,
>
> Please install and try this release version. You
> only need to flash u-boot image (the SPL and Pogo
> env are the same images).
>
> Dropbox:
> uboot.2013.10-tld-5
> .ox820.bodhi.tar

> md5:
> bf385f83b42cdeee1f2ecbf53f6cdec5

So this u-boot by default checks to see if there is a uEnv.txt file in /boot before it executes the bootenv's stored in nand? Is that correct?

Here is what I plan on putting into uEnv.txt this time. If you see anything that looks like it doesn't belong please let me know.

bootcmd=run bootcmd_usb; run bootcmd_sata; reset
bootcmd_sata=run sata_init; run set_bootargs_sata; run sata_boot;
bootcmd_usb=run usb_init; run set_bootargs_usb; run usb_boot;
bootdelay=10
console=ttyS0,115200
device=0:1
rootdelay=10
sata_boot=run sata_load_uimage; run sata_load_uinitrd; run sata_load_dtb; if run sata_load_dtb; then bootm $uimage_addr $uinitrd_addr $dtb_addr; fi
sata_init=ide reset
sata_load_uimage=ext2load ide $device $uimage_addr /boot/uImage
sata_load_uinitrd=ext2load ide $device $uinitrd_addr /boot/uInitrd
sata_load_dtb=ext2load ide $device $dtb_addr /boot/dts/ox820-pogoplug-pro.dtb
sata_root=/dev/sda1
usb_boot=run usb_load_uimage; run usb_load_initrd; run usb_load_dtb; if run usb_load_dtb; then bootm $uimage_addr $uinitrd_addr $dtb_addr; fi
usb_init=usb start
usb_load_uimage=ext2load usb $device $uimage_addr /boot/uImage
usb_load_uinitrd=ext2load usb $device $uinitrd_addr /boot/uInitrd
usb_load_dtb=ext2load usb $device $dtb_addr /boot/dts/ox820-pogoplug-pro.dtb
usb_root=/dev/sda1
uimage_addr=0x60500000
uinitrd_addr=0x60e00000
dtb_addr=0x62c00000
set_bootargs_sata=setenv bootargs console=$console root=$sata_root rootdelay=$rootdelay
set_bootargs_usb=setenv bootargs console=$console root=$usb_root rootdelay=$rootdelay



Edited 2 time(s). Last edit at 03/08/2015 06:01PM by LeggoMyEggo.
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
March 08, 2015 06:00PM
LeggoMyEggo,


> So this u-boot by default checks to see if there
> is a uEnv.txt file in /boot before it
> executes the bootenv's stored in nand? Is that
> correct?

Yes it does, but in reverse. u-boot envs are always checked before anything else. However, if the check failed because the NAND block is bad, then it will set the envs to the default values internally defined. And inside this u-boot, the default bootcmd is defined to load uEnv.txt as the first action.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
March 08, 2015 06:24PM
LeggoMyEggo Wrote:
-------------------------------------------------------
> bodhi Wrote:
> --------------------------------------------------
> -----
> > @ LeggoMyEggo,
> >
> > Please install and try this release version.
> You
> > only need to flash u-boot image (the SPL and
> Pogo
> > env are the same images).
> >
> > Dropbox:
> >
> uboot.2013.10-tld-5
>
> > .ox820.bodhi.tar

> > md5:
> > bf385f83b42cdeee1f2ecbf53f6cdec5
>
> So this u-boot by default checks to see if there
> is a uEnv.txt file in /boot before it
> executes the bootenv's stored in nand? Is that
> correct?
>
> Here is what I plan on putting into uEnv.txt this
> time. If you see anything that looks like it
> doesn't belong please let me know.
>
> bootcmd=run bootcmd_usb; run bootcmd_sata; reset
> bootcmd_sata=run sata_init; run set_bootargs_sata;
> run sata_boot;
> bootcmd_usb=run usb_init; run set_bootargs_usb;
> run usb_boot;
> bootdelay=10
> console=ttyS0,115200
> device=0:1
> rootdelay=10
> sata_boot=run sata_load_uimage; run
> sata_load_uinitrd; run sata_load_dtb; if run
> sata_load_dtb; then bootm $uimage_addr
> $uinitrd_addr $dtb_addr; fi
> sata_init=ide reset
> sata_load_uimage=ext2load ide $device $uimage_addr
> /boot/uImage
> sata_load_uinitrd=ext2load ide $device
> $uinitrd_addr /boot/uInitrd
> sata_load_dtb=ext2load ide $device $dtb_addr
> /boot/dts/ox820-pogoplug-pro.dtb
> sata_root=/dev/sda1
> usb_boot=run usb_load_uimage; run usb_load_initrd;
> run usb_load_dtb; if run usb_load_dtb; then bootm
> $uimage_addr $uinitrd_addr $dtb_addr; fi
> usb_init=usb start
> usb_load_uimage=ext2load usb $device $uimage_addr
> /boot/uImage
> usb_load_uinitrd=ext2load usb $device
> $uinitrd_addr /boot/uInitrd
> usb_load_dtb=ext2load usb $device $dtb_addr
> /boot/dts/ox820-pogoplug-pro.dtb
> usb_root=/dev/sda1
> uimage_addr=0x60500000
> uinitrd_addr=0x60e00000
> dtb_addr=0x62c00000
> set_bootargs_sata=setenv bootargs console=$console
> root=$sata_root rootdelay=$rootdelay
> set_bootargs_usb=setenv bootargs console=$console
> root=$usb_root rootdelay=$rootdelay

Everything looks good, except the missing ethaddr. And later after booting, the rootfs label should be set up for future multiple drive booting.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
March 08, 2015 06:28PM
Here is what the internal default envs look like.

OX820> printenv 
autoload=no
baudrate=115200
bootargs=console=ttyS0,115200n8
bootcmd=run bootcmd_uenv; run dt_bootcmd_usb; reset
bootcmd_uenv=run uenv_load; if test $uenv_loaded -eq 1; then run uenv_import; fi
bootdelay=10
console=console=ttyS0,115200n8
devices=usb ide
dt_bootcmd_usb=usb start; run dt_usb_bootcmd; usb stop; reset
dt_bootm=bootm $uimage_addr $uinitrd_addr $dtb_addr
dt_load_dtb=ext2load usb 0:1 $dtb_addr /boot/dts/ox820-pogoplug-pro.dtb
dt_load_initrd=ext2load usb 0:1 $uinitrd_addr /boot/uInitrd
dt_load_uimage=ext2load usb 0:1 $uimage_addr /boot/uImage
dt_usb_boot=run dt_load_uimage; run dt_load_initrd; run dt_load_dtb; run dt_bootm
dt_usb_bootcmd=run usb_set_bootargs; run dt_usb_boot
dtb_addr=0x62c00000
ethact=mii0
ethaddr=5e:2b:15:71:ec:b6
if_netconsole=ping $serverip
ipaddr=192.168.0.222
mtdids=nand0=41000000.nand
mtdparts=mtdparts=41000000.nand:14m(boot),-(data)
preboot=run safeboot
preboot_nc=run if_netconsole start_netconsole
serverip=192.168.0.220
start_netconsole=setenv ncip $serverip; setenv bootdelay 10; setenv stdin nc; setenv stdout nc; setenv stderr nc; version
stderr=serial
stdin=serial
stdout=serial
uenv_import=echo importing envs ...; env import -t 0x60500000
uenv_init_devices=setenv init_usb "usb start";  setenv init_ide "ide reset";  setenv init_mmc "mmc rescan"; for devtype in $devices; do run init_$devtype; done;
uenv_load=run uenv_init_devices; setenv uenv_loaded 0; for devtype in $devices;  do for disknum in 0; do run uenv_read_disk; done; done;
uenv_read=echo loading envs from $devtype $disknum ...; if load $devtype $disknum:1 0x60500000 /boot/uEnv.txt; then setenv uenv_loaded 1; fi
uenv_read_disk=if test $devtype -eq mmc; then if $devtype part; then run uenv_read;  fi; else if $devtype part $disknum; then run uenv_read; fi;  fi
uimage_addr=0x60500000
uinitrd_addr=0x60e00000
usb_device=0:1
usb_set_bootargs=setenv bootargs console=ttyS0,115200 root=/dev/sda1 rootdelay=10

Environment size: 2001/131068 bytes

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
March 08, 2015 09:42PM
@LeggoMyEggo,

> if you could provide some pointers on how to load
> mkenvimage on my linux box that would work too.

I've realized I've missed this question! the reason you have problem loading this command because it is part of the u-boot build. It is not in Debian repository. So to run this and create a proper u-boot env image, you can use the attached binary in this post:
http://forum.doozan.com/read.php?2,16044,19723#msg-19723

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
March 12, 2015 01:17AM
Upgrading to newer version needs some changes when booting from SATA (at least here in my case, as ide command does not know start/stop anymore)

I've changed

dt_bootcmd_ide=ide start; run dt_ide_bootcmd; ide stop; reset


to

dt_bootcmd_ide=ide reset; run dt_ide_bootcmd; reset
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
March 12, 2015 01:52AM
morph027 Wrote:
-------------------------------------------------------
> Upgrading to newer version needs some changes when
> booting from SATA (at least here in my case, as
> ide command does not know start/stop
> anymore)
>
> I've changed
>
>
> dt_bootcmd_ide=ide start; run dt_ide_bootcmd; ide
> stop; reset
>
>
>
> to
>
>
> dt_bootcmd_ide=ide reset; run dt_ide_bootcmd;
> reset
>

Thanks! perhaps I forgot to update the 1st post.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)



Edited 1 time(s). Last edit at 03/12/2015 01:53AM by bodhi.
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
April 08, 2015 10:11AM
Hello Bodhi,

This uboot.2013.10-tld-4.ox820.bodhi.tar is for PogoPlug V3. Is it the same as my newly acquired PogoPlug Pro P02 from Adorama? If so, then I will just follow the instruction as shown on your OP.
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
April 08, 2015 03:38PM
habibie,

Yes it is for Pogo V3. And Pogo V3 has many models.

POGO-P01 this is the Pro version and P02 is Canadian model of the same.

The rest I'd lump them into a Classic version. These don't have Wifi (PCIe).

POGO-P21
POGO-P24
POGO-P25
POGO-B01
POGO-B02
POGO-B03
POGO-B04

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
April 08, 2015 04:38PM
OK Bodhi and thank you.
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
April 11, 2015 07:40AM
bodhi Wrote:
-------------------------------------------------------
>
...
>
> 2. The env image pogopro_uboot_env.img should only
> be flashed if
> your
> rootfs has FDT kernel
. If your kernel is
> an older non-FDT kernel then do not flash this env
> image. If you plan to run with
> the
> new rootfs
then flash this image.
>
Hello Bodhi,

My understanding of the above statement is if my PogoPlug Pro P02 still runs on its original stock firmware (which I believe doesn't support FDT) and I flash the env image pogopro_uboot_env.img, the new uboot won't be able to boot the original stock firmware. That is fine with me. I also wonder if the latest PogoPlug Pro firmware has a support for FDT that I can update the original firmware. This way, the env image pogopro_uboot_env.img will be able to boot it.
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
April 11, 2015 03:13PM
habibie,

> My understanding of the above statement is if my
> PogoPlug Pro P02 still runs on its original stock
> firmware (which I believe doesn't support FDT) and
> I flash the env image pogopro_uboot_env.img, the
> new uboot won't be able to boot the original stock
> firmware.

Correct.

>This
> way, the env image pogopro_uboot_env.img will be
> able to boot it.

Not really. The default envs are set up to boot with kernel and rootfs on USB. So it won't work without modifying. And it's not a good way to boot stock OS either. To do that, we should try to chainload the old u-boot if possible.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
April 11, 2015 09:16PM
Bodhi,

Thank you for the above clarification.
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
May 17, 2015 04:08PM
A request for help.

I have a Pogoplug Pro (Oxnas CPU, Internal SATA port, Internal WiFi via PCI-e card). I have access to the internal serial port.

I set out out update my Pogoplug system completely, it was running an older version of Debian off a USB stick but not very well. I have followed the instructions in the first post and successfully updated U-boot. Unfortunately something went wrong and the environment variables got messed up. To correct this, I have tried to cut and paste the list of environment variables in the post by Bodhi above line by line, but this method fails with the longer, more complex lines.

Can someone direct me to a 'howto' or tell me what I need to type from the U-boot prompt to boot a previously known working USB stick. Once I've got a working Debian command prompt, I can then attempt to reflash the environment variables so hopefully I have a system that will correctly boot a USB stick. Once I've got a Pogoplug that starts correctly, I can then re-program the USB stick to an updated version of Debian. Then I will have acheived what I set out to do - the hard way!

Thanks

Peter
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
May 17, 2015 04:22PM
Peter,

If you are running the latest u-boot version, then you can use uEnv.txt to restore a default set like the one I've posted.

Quote

Updated 05 Mar 2015

I've uploaded the uboot.2013.10-tld-4 u-Boot image for Pogoplug V3 Oxnas. This u-boot supports the following latest U-Boot features (among others):

- Ability to customize u-boot envs in a script (uEnv.txt) during boot, without committing changes to NAND (see section A below for instruction). This feature also can be used for rescue purpose where the u-boot envs were messed up, or when the NAND envs block is bad.

The instruction is in section A.

Quote

A. How to use the uEnv.txt script

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)



Edited 2 time(s). Last edit at 05/17/2015 04:25PM by bodhi.
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
May 17, 2015 06:15PM
Peter,

It occured to me that you might want to enter the envs one-by-one at serial console prompt OX820>. In that case, each of the default envs should be entered as followed:

OX820> setenv autoload 'no'
OX820> setenv bootargs 'console=ttyS0,115200n8'
and so on.

Basically, you want to replace the first = sign, with a space and a single quote. Keep everying as is until then end, where you end quote with another single quote.

You should prepare these commands on a notepad. And then paste them one by one at the serial console prompt.

autoload=no
baudrate=115200
bootargs=console=ttyS0,115200n8
bootdelay=10
console=console=ttyS0,115200n8
ethact=mii0
ethaddr=5e:2b:15:71:ec:b6
ipaddr=192.168.0.222
mtdids=nand0=41000000.nand
mtdparts=mtdparts=41000000.nand:14m(boot),-(data)
serverip=192.168.0.220
stderr=serial
stdin=serial
stdout=serial
usb_device=0:1
if_netconsole=ping $serverip
preboot_nc=run if_netconsole start_netconsole
start_netconsole=setenv ncip $serverip; setenv bootdelay 10; setenv stdin nc; setenv stdout nc; setenv stderr nc; version
usb_set_bootargs=setenv bootargs console=ttyS0,115200 root=/dev/sda1 rootdelay=10
uinitrd_addr=0x60e00000
uimage_addr=0x60500000
dtb_addr=0x62c00000
dt_load_dtb=ext2load usb 0:1 $dtb_addr /boot/dts/ox820-pogoplug-pro.dtb
dt_load_initrd=ext2load usb 0:1 $uinitrd_addr /boot/uInitrd
dt_load_uimage=ext2load usb 0:1 $uimage_addr /boot/uImage
dt_bootm=bootm $uimage_addr $uinitrd_addr $dtb_addr
dt_usb_boot=run dt_load_uimage; run dt_load_initrd; run dt_load_dtb; run dt_bootm
dt_usb_bootcmd=run usb_set_bootargs; run dt_usb_boot
dt_bootcmd_usb=usb start; run dt_usb_bootcmd; usb stop; reset
bootcmd=run dt_bootcmd_usb
and then execute boot to boot the box:
OX820> boot


After you have booted successfully into Debian, then use Linux fw_setenv command to set them for real. Again, prepare another set in notepad, this time use the fw_setenv instead of setenv. And then paste each one to the command line.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
May 18, 2015 05:07PM
Bodhi,

Thank you for your helpful reply. The secret bit I did not know was to put the long, complex lines 'in single quotes'. Once I did this I was able to get the all the environment variables set correctly and it now boots correctly. Now to sort out the rest of it.

In the example printev shown further up this page, (2001 bytes) there's an error message caused by the line 'preboot=run safeboot' - safeboot is not defined. It does not affect what I am doing.

Thank you and the community for your efforts to help let us play with our devices in ways the maker did not really intend.

Regards

Peter
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
May 18, 2015 07:07PM
Peter,

Glad you got it working! And thanks for pointing out the "safeboot" env. That was a leftover from the old settings that I need to remove but forgot about it!

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
June 03, 2015 07:52PM
I have installed U-Boot according to this thread and I am running Debian with kernel 3.17.
In the OP ist says:
"After flashing this U-Boot, it still will be possible to boot back to stock OS"
I tried to do that but it seems to me it doesn't ...
If I unplug the USB stick with the Debian rootfs on it and power cycle the box, I cannot connect to it any more.
It still has the same IP addr, but I cannot ping it and it doesn't seem to listen on an http[s] or ssh port, at least I cannot connect.
This is not a big deal, as I don't need to run the original Pogo OS anyways, I am/was just curious if I screwed something up.
I assume it might have something to do with my U-Boot environment settings.
Here is the output from fw_printenv
autoload=no
baudrate=115200
bootargs=console=ttyS0,115200n8
bootdelay=10
console=console=ttyS0,115200n8
ethact=mii0
mtdids=nand0=41000000.nand
mtdparts=mtdparts=41000000.nand:14m(boot),-(data)
stderr=serial
stdin=serial
stdout=serial
usb_device=0:1
if_netconsole=ping $serverip
preboot_nc=run if_netconsole start_netconsole
start_netconsole=setenv ncip $serverip; setenv bootdelay 10; setenv stdin nc; setenv stdout nc; setenv stderr nc; version
usb_set_bootargs=setenv bootargs console=ttyS0,115200 root=/dev/sda1 rootdelay=10
uinitrd_addr=0x60e00000
uimage_addr=0x60500000
dtb_addr=0x62c00000
dt_load_initrd=ext2load usb 0:1 $uinitrd_addr /boot/uInitrd
dt_load_uimage=ext2load usb 0:1 $uimage_addr /boot/uImage
dt_bootm=bootm $uimage_addr $uinitrd_addr $dtb_addr
dt_usb_boot=run dt_load_uimage; run dt_load_initrd; run dt_load_dtb; run dt_bootm
dt_usb_bootcmd=run usb_set_bootargs; run dt_usb_boot
dt_bootcmd_usb=usb start; run dt_usb_bootcmd; usb stop; reset
bootcmd=run dt_bootcmd_usb
ethaddr=00:25:31:01:d6:b2
dt_load_dtb=ext2load usb 0:1 $dtb_addr $fdt_file
preboot=run preboot_nc
ipaddr=192.168.42.92
serverip=192.168.42.74
fdt_file=/boot/dts/ox820-pogoplug-pro.dtb
Any hints and help appreciated - thanks!
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
June 03, 2015 11:00PM
zwalex,

Cool! so you have installed and run Debian kernel 3.17 successfully.

Regarding the stock Pogo OS, I should have made it clearer: it is possible to boot back to stock OS. However, some u-boot envs needed to be adjusted so that it will boot into Pogo OS when there is no USB or HDD rootfs present. As it is right now, the default u-boot envs set does not have those settings.

I meant to post these settings so that everybody can use Pogo OS as a simple rescue system. But have not got around to do that. So stay tune and it will be available eventually!

In the mean time, just be sure you don't change NAND mtdparts definition or try flashing other software (such as OpenWrt), like some users did. it will complicate things a bit (still possible) when you set it up later.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
June 04, 2015 02:21AM
Thanks bodhi!
As I said - not a big deal, as I am not planing to use the original Pogo OS ever again ...
Knowing that it would still be there as a kind of a rescue system would be cool though - so I am looking forward to seeing the u-boot envs settings allowing this.
My next step now will be to upgrade the kernel.
Thanks again!
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
June 16, 2015 02:08PM
I have severe problems with USB booting on both oxnas devices I've tried (a black POGO-P21 and pink POGO-B01). This has happened with a couple of different USB flash drives/card readers and both U-Boot 2013.10-tld-4 and U-Boot 2013.10-tld-5. Using the default environment with dt_bootcmd_usb set to 'usb start; run dt_usb_bootcmd; usb stop; reset', U-Boot goes into a loop of:
U-Boot 2013.10-tld-5 (Mar 07 2015 - 16:50:17) for OXNAS
gcc (Debian 4.9.1-19) 4.9.1
GNU ld (GNU Binutils for Debian) 2.24.90.20141023
Hit any key to stop autoboot:  0 
(Re)start USB...
USB0:   USB EHCI 1.00
scanning bus 0 for devices... cannot reset port 4!?
2 USB Device(s) found
       scanning usb for storage devices... 0 Storage Device(s) found
** Bad device usb 0 **
** Bad device usb 0 **
** Bad device usb 0 **
Wrong Image Format for bootm command

Led:    ORANGE (Failed)
ERROR: can't get kernel image!
stopping USB..
resetting ...
If I run
usb start
twice without a reset, it works consistently the second time on the black Pogoplug (with the USB device on any port). It also works on ports 1-3 (but not the front-facing port 4) of the pink Pogoplug.
OX820> usb start
u s b s t a r t 
(Re)start USB...
USB0: USB EHCI 1.00
scanning bus 0 for devices... cannot reset port 4!?
2 USB Device(s) found
scanning usb for storage devices... 0 Storage Device(s) found
OX820> usb start
u s b s t a r t 
(Re)start USB...
USB0: USB EHCI 1.00
scanning bus 0 for devices... 3 USB Device(s) found
scanning usb for storage devices... 1 Storage Device(s) found
The EHCI controller works fine in Linux. I don't know much about the platform details, but something doesn't seem right here. Any relevant U-Boot build params (clock related, etc.) that could affect reliability of the USB controller?



Edited 2 time(s). Last edit at 06/16/2015 02:20PM by trisk.
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
June 17, 2015 12:35AM
trisk Wrote:
-------------------------------------------------------
> I have severe problems with USB booting on both
> oxnas devices I've tried (a black POGO-P21 and
> pink POGO-B01). This has happened with a couple of
> different USB flash drives/card readers and both
> U-Boot 2013.10-tld-4 and U-Boot 2013.10-tld-5.
> Using the default environment with dt_bootcmd_usb
> set to 'usb start; run dt_usb_bootcmd; usb stop;
> reset', U-Boot goes into a loop of:
>
> U-Boot 2013.10-tld-5 (Mar 07 2015 - 16:50:17) for
> OXNAS
> gcc (Debian 4.9.1-19) 4.9.1
> GNU ld (GNU Binutils for Debian) 2.24.90.20141023
> Hit any key to stop autoboot:  0 
> (Re)start USB...
> USB0:   USB EHCI 1.00
> scanning bus 0 for devices... cannot reset port
> 4!?
> 2 USB Device(s) found
>        scanning usb for storage devices... 0
> Storage Device(s) found
> ** Bad device usb 0 **
> ** Bad device usb 0 **
> ** Bad device usb 0 **
> Wrong Image Format for bootm command
> 
> Led:    ORANGE (Failed)
> ERROR: can't get kernel image!
> stopping USB..
> resetting ...
>
> If I run
usb start
twice without a
> reset, it works consistently the second
> time on the black Pogoplug (with the USB device on
> any port). It also works on ports 1-3 (but not the
> front-facing port 4) of the pink Pogoplug.
>
> OX820> usb start
> u s b s t a r t 
> (Re)start USB...
> USB0: USB EHCI 1.00
> scanning bus 0 for devices... cannot reset port
> 4!?
> 2 USB Device(s) found
> scanning usb for storage devices... 0 Storage
> Device(s) found
> OX820> usb start
> u s b s t a r t 
> (Re)start USB...
> USB0: USB EHCI 1.00
> scanning bus 0 for devices... 3 USB Device(s)
> found
> scanning usb for storage devices... 1 Storage
> Device(s) found
>
> The EHCI controller works fine in Linux. I don't
> know much about the platform details, but
> something doesn't seem right here. Any relevant
> U-Boot build params (clock related, etc.) that
> could affect reliability of the USB controller?

This is most likely due to the type of USB flash drive you are using. Which brand is this one? Some USB flash drives can't not be used for booting reliably. Sandisk is among the most reliable USB 2.0 flash drives for booting.

I can't recall if I did implement the usb_ready_retry on this u-boot version (I have this in the Kirkwood u-boot). Try this:

- interrupt netconsole, and enter command:
setenv usb_ready_retry 15
- and then
boot

See if you can boot consistently with this seting. And please post the output of netconsle session in either case.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
June 17, 2015 05:28PM
bodhi Wrote:
-------------------------------------------------------
> trisk Wrote:
> --------------------------------------------------
> -----
> > I have severe problems with USB booting on both
> > oxnas devices I've tried (a black POGO-P21 and
> > pink POGO-B01). This has happened with a couple
> of
> > different USB flash drives/card readers and
> both
> > U-Boot 2013.10-tld-4 and U-Boot 2013.10-tld-5.
> > Using the default environment with
> dt_bootcmd_usb
> > set to 'usb start; run dt_usb_bootcmd; usb
> stop;
> > reset', U-Boot goes into a loop of:
> >
> > U-Boot 2013.10-tld-5 (Mar 07 2015 - 16:50:17)
> for
> > OXNAS
> > gcc (Debian 4.9.1-19) 4.9.1
> > GNU ld (GNU Binutils for Debian)
> 2.24.90.20141023
> > Hit any key to stop autoboot:  0 
> > (Re)start USB...
> > USB0:   USB EHCI 1.00
> > scanning bus 0 for devices... cannot reset port
> > 4!?
> > 2 USB Device(s) found
> >        scanning usb for storage devices... 0
> > Storage Device(s) found
> > ** Bad device usb 0 **
> > ** Bad device usb 0 **
> > ** Bad device usb 0 **
> > Wrong Image Format for bootm command
> > 
> > Led:    ORANGE (Failed)
> > ERROR: can't get kernel image!
> > stopping USB..
> > resetting ...
> >
> > If I run
usb start
twice without a
> > reset, it works consistently the second
> > time on the black Pogoplug (with the USB device
> on
> > any port). It also works on ports 1-3 (but not
> the
> > front-facing port 4) of the pink Pogoplug.
> >
> > OX820> usb start
> > u s b s t a r t 
> > (Re)start USB...
> > USB0: USB EHCI 1.00
> > scanning bus 0 for devices... cannot reset port
> > 4!?
> > 2 USB Device(s) found
> > scanning usb for storage devices... 0 Storage
> > Device(s) found
> > OX820> usb start
> > u s b s t a r t 
> > (Re)start USB...
> > USB0: USB EHCI 1.00
> > scanning bus 0 for devices... 3 USB Device(s)
> > found
> > scanning usb for storage devices... 1 Storage
> > Device(s) found
> >
> > The EHCI controller works fine in Linux. I
> don't
> > know much about the platform details, but
> > something doesn't seem right here. Any relevant
> > U-Boot build params (clock related, etc.) that
> > could affect reliability of the USB controller?
>
> This is most likely due to the type of USB flash
> drive you are using. Which brand is this one? Some
> USB flash drives can't not be used for booting
> reliably. Sandisk is among the most reliable USB
> 2.0 flash drives for booting.
>

I think the one branded drive I had issues with was a Transcend 4 GB drive, the rest are branded conference giveaways with no clear markings, or generic micro SD card readers (I have a lot more microSD cards than modern USB drives).

> I can't recall if I did implement the
> usb_ready_retry on this u-boot version (I have
> this in the Kirkwood u-boot). Try this:
>
> - interrupt netconsole, and enter command:
>
> setenv usb_ready_retry 15
>
> - and then
>
> boot
>
>
> See if you can boot consistently with this seting.
> And please post the output of netconsle session in
> either case.

On the POGO-P01, I get:
OX820> printenv
 p r i n t e n v 
autoload=no
baudrate=115200
bootargs=console=ttyS0,115200 root=/dev/sda1 rootdelay=10
bootcmd=run dt_bootcmd_usb
bootdelay=5
console=console=ttyS0,115200n8
dt_bootcmd_usb=usb start; run dt_usb_bootcmd; usb stop; reset
dt_bootm=bootm $uimage_addr $uinitrd_addr $dtb_addr
dt_load_dtb=ext2load usb 0:1 $dtb_addr $fdt_file
dt_load_initrd=ext2load usb 0:1 $uinitrd_addr /boot/uInitrd
dt_load_uimage=ext2load usb 0:1 $uimage_addr /boot/uImage
dt_usb_boot=run dt_load_uimage; run dt_load_initrd; run dt_load_dtb; run dt_bootm
dt_usb_bootcmd=run usb_set_bootargs; run dt_usb_boot
dtb_addr=0x62c00000
ethact=mii0
ethaddr=00:25:31:02:8d:42
fdt_file=/boot/dts/ox820-pogoplug-classic.dtb
if_netconsole=ping $serverip
ipaddr=192.168.0.158
mtdids=nand0=41000000.nand
mtdparts=mtdparts=41000000.nand:14m(boot),-(data)
ncip=192.168.0.4
preboot=run preboot_nc
preboot_nc=run if_netconsole start_netconsole
serverip=192.168.0.4
start_netconsole=setenv ncip $serverip; setenv bootdelay 5; setenv stdin nc; setenv stdout nc; setenv stderr nc; version
stderr=nc
stdin=nc
stdout=nc
uimage_addr=0x60500000
uinitrd_addr=0x60e00000
usb_device=0:1
usb_set_bootargs=setenv bootargs console=ttyS0,115200 root=/dev/sda1 rootdelay=10

Environment size: 1271/131068 bytes
OX820> setenv setenv usb_ready_retry 15
 s e t e n v   s e t e n v   u s b _ r e a d y _ r e t r y   1 5 
OX820> run bootcmd
 r u n   b o o t c m d 
(Re)start USB...
USB0:   USB EHCI 1.00
scanning bus 0 for devices... 4 USB Device(s) found
       scanning usb for storage devices... 1 Storage Device(s) found
4170064 bytes read in 374 ms (10.6 MiB/s)
EHCI timed out on TD - token=0xc008d80
EHCI timed out on TD - token=0x80008d80
EHCI timed out on TD - token=0x80008d80
EHCI timed out on TD - token=0x80008d80
EHCI timed out on TD - token=0x80008d80
EHCI timed out on TD - token=0x80008d80
EHCI timed out on TD - token=0x80008d80
EHCI timed out on TD - token=0xc008d80
EHCI timed out on TD - token=0x80008d80
EHCI timed out on TD - token=0x80008d80
EHCI timed out on TD - token=0x80008d80
EHCI timed out on TD - token=0x80008d80
EHCI timed out on TD - token=0x80008d80
 ** ext4fs_devread read error - block
EHCI timed out on TD - token=0x80008d80
EHCI timed out on TD - token=0x80008d80
EHCI timed out on TD - token=0x80008d80
EHCI timed out on TD - token=0x80008d80
EHCI timed out on TD - token=0x80008d80
EHCI timed out on TD - token=0x80008d80
** Can't read partition table on 0:0 **
** Invalid partition 1 **
## Booting kernel from Legacy Image at 60500000 ...
   Image Name:   Linux-3.18.5-oxnas-tld-1
   Created:      2015-06-15  22:44:20 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    4170000 Bytes = 4 MiB
   Load Address: 60008000
   Entry Point:  60008000
   Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 60e00000 ...
   Image Name:   initramfs-3.18.5-oxnas-tld-1
   Created:      2015-06-15  22:44:21 UTC
   Image Type:   ARM Linux RAMDisk Image (gzip compressed)
   Data Size:    1977442 Bytes = 1.9 MiB
   Load Address: 60000000
   Entry Point:  60000000
   Verifying Checksum ... Bad Data CRC

Led:    ORANGE (Failed)
Ramdisk image is corrupt or invalid
stopping USB..
resetting ...
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
June 17, 2015 05:31PM
<accidental dup>



Edited 1 time(s). Last edit at 06/17/2015 05:32PM by trisk.
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
June 17, 2015 06:21PM
trisk Wrote:
-------------------------------------------------------
> the rest are branded
> conference giveaways with no clear markings, or
> generic micro SD card readers (I have a lot more
> microSD cards than modern USB drives).

That's your problem right there. The conference giveaway flash drives are garbage.

-grayman4hire
======================================
Pogoplug V2 and V3 Serial Connection
Tutorial - Pogoplug v4 (Series 4 and Mobile) with Linux (Debian or Arch)

OpenWRT on Pogoplug Mobile
Tutorial - Pogoplug E02/V4 with Arch Linux ARM
Hacking the Pogoplug v3/Oxnas (Pro/Classic) with Debian

OpenWRT on Pogoplug v3/Oxnas (Pro/Classic)
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
June 17, 2015 11:59PM
trisk,

These drives are not good to use as boot drives. You should get a Sandisk (any model is fine).

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
dibbsy
Re: 2013.10 U-Boot for Pogoplug V3 (OXNAS)
July 03, 2015 06:29PM
I have alarm on the pogo right now.
4. You are running stock kernel, and have gained SHH access to the box, and have downloaded u-boot-tools and mtd-utils (fw_setenv, flash_erase, nandwrite …) to work with NAND mtds. And plan to run a USB rootfs that came from any of the above 3.

OK so I plan to run a new rootfs/kernel from USB, I need a new uBoot to do this. I have a serial console. I get to step 12 and I do not have valid uBoot envs. I did not run step 9 or 10 as instructed as I have the stock kernel right now.

[ 4380.990000] uncorrectable error :
[ 4380.990000] uncorrectable error : Warning: Bad CRC, using default environment
bootcmd=bootp; setenv bootargs root=/dev/nfs nfsroot=${serverip}:${rootpath} ip=${ipaddr}:${serverip}:${gatewayip}:${netmask}:${hostname}::off; bootm
bootdelay=5
baudrate=115200

How do I put the correct uboot environment back?

Thanks!
Sorry, you can't reply to this topic. It has been closed.