Welcome! Log In Create A New Profile

Advanced

Problem overwriting ethaddr (and remedy) / Picky about USB drives?

Posted by chessplayer 
Problem overwriting ethaddr (and remedy) / Picky about USB drives?
August 01, 2022 07:18PM
Hi, I followed the instructions in the 2017 uBoot thread for the Kirkwoods for my GoFlexNet (which still had a uBoot from 2011 ...). Everything worked fine (or so it seemed - see below) except for the setting of the ethaddr:

root@gfn ~ $ fw_setenv ethaddr '00:10:75:XX:YY:ZZ'
Can't overwrite "ethaddr"

This could be remedied from the OpenWrt Rescue system.

However, when trying to boot the box using a USB drive which happily boots a Dockstar as well as a Pogo E02, I ran into EHCI timeouts. I was able to boot with an older kernel / rootfs from a Lexar USB 3.0 drive, unable with a Data Traveler drive, Kingston drive or any other I tried with the latest kernel / rootfs. Has anybody else seen the GFN be so picky about booting from USB?

Cheers,

chessplayer

---
Standart ist der Standardfehler
Re: Problem overwriting ethaddr (and remedy) / Picky about USB drives?
August 01, 2022 09:55PM
chessplayer,

> Everything worked fine (or so it seemed - see
> below) except for the setting of the ethaddr:
>
>
> root@gfn ~ $ fw_setenv ethaddr
> '00:10:75:XX:YY:ZZ'
> Can't overwrite "ethaddr"
>

If you boot Debian, you won't have this problem. The new u-boot + my Debian rootfs should allow changing the MAC address.

And by the way, Debian /etc/network/interfaces is sticky. It won't be overwritten by Debian upgrade.

-bodhi
===========================
Forum Wiki
bodhi's corner



Edited 1 time(s). Last edit at 08/01/2022 09:57PM by bodhi.
Re: Problem overwriting ethaddr (and remedy) / Picky about USB drives?
August 01, 2022 10:00PM
> Has anybody else seen the
> GFN be so picky about booting from USB?

A lot of the USB thumb drives suffer the same fate. Sandisk brand is most reliable in booting.

In anycase, my released u-boot for 2017 should help in booting USB thumb drives of many brands.

-bodhi
===========================
Forum Wiki
bodhi's corner
Re: Problem overwriting ethaddr (and remedy) / Picky about USB drives?
August 02, 2022 06:09AM
bodhi Wrote:
-------------------------------------------------------
> > Has anybody else seen the
> > GFN be so picky about booting from USB?
>
> A lot of the USB thumb drives suffer the same
> fate. Sandisk brand is most reliable in booting.
>
> In anycase, my released u-boot for 2017 should
> help in booting USB thumb drives of many brands.


As I said, this happens with the new uBoot and the drives mentioned:

Kingston USB 3.0
U-Boot 2017.07-tld-1 (Sep 05 2017 - 00:17:19 -0700)
Seagate GoFlex Net
gcc (Debian 6.3.0-18) 6.3.0 20170516
GNU ld (GNU Binutils for Debian) 2.28
Hit any key to stop autoboot:  0 
Initializing devices...
starting USB...
USB0:   USB EHCI 1.00
scanning bus 0 for devices... EHCI timed out on TD - token=0x80008c80
EHCI timed out on TD - token=0x80400988
unable to get device descriptor (error=-1) retry: 5
EHCI timed out on TD - token=0x80008c80
EHCI timed out on TD - token=0x80a88
unable to get device descriptor (error=-1) retry: 4


Data Traveller USB 3.0

U-Boot 2017.07-tld-1 (Sep 05 2017 - 00:17:19 -0700)
Seagate GoFlex Net
gcc (Debian 6.3.0-18) 6.3.0 20170516
GNU ld (GNU Binutils for Debian) 2.28
Hit any key to stop autoboot:  0 
Initializing devices...
starting USB...
USB0:   USB EHCI 1.00
scanning bus 0 for devices... EHCI timed out on TD - token=0x80008c80
EHCI timed out on TD - token=0x80400988
unable to get device descriptor (error=-1) retry: 5
EHCI timed out on TD - token=0x80008c80
EHCI timed out on TD - token=0x80a88
unable to get device descriptor (error=-1) retry: 4


Toshiba USB 2.0

U-Boot 2017.07-tld-1 (Sep 05 2017 - 00:17:19 -0700)
Seagate GoFlex Net
gcc (Debian 6.3.0-18) 6.3.0 20170516
GNU ld (GNU Binutils for Debian) 2.28
Hit any key to stop autoboot:  0 
Initializing devices...
starting USB...
USB0:   USB EHCI 1.00
scanning bus 0 for devices... Error: Cannot find high speed parent of usb-1 device
EHCI timed out on TD - token=0x80008c80
EHCI timed out on TD - token=0x80a88
unable to get device descriptor (error=-1) retry: 5
Error: Cannot find high speed parent of usb-1 device
EHCI timed out on TD - token=0x80008c80
EHCI timed out on TD - token=0x80a88


NoName USB 2.0

U-Boot 2017.07-tld-1 (Sep 05 2017 - 00:17:19 -0700)
Seagate GoFlex Net
gcc (Debian 6.3.0-18) 6.3.0 20170516
GNU ld (GNU Binutils for Debian) 2.28
Hit any key to stop autoboot:  0 
Initializing devices...
starting USB...
USB0:   USB EHCI 1.00
scanning bus 0 for devices... 2 USB Device(s) found
       scanning usb for storage devices... 
Use USB retry period from the environment: 15 second(s)
1 Storage Device(s) found

Reset IDE: ide_preinit failed
Unknown command 'mmc' - try 'help'
Loading envs from usb 0...
** File not found /boot/uEnv.txt **
Loading envs from usb 1...
** Bad device usb 1 **
Loading envs from usb 2...
** Bad device usb 2 **
Loading envs from usb 3...
** Bad device usb 3 **
Loading envs from ide 0...
** Bad device ide 0 **
Loading envs from ide 1...
** Bad device ide 1 **
Loading envs from ide 2...
** Bad device ide 2 **
Loading envs from ide 3...
** Bad device ide 3 **
Loading envs from mmc 0...
** Bad device mmc 0 **
Loading envs from mmc 1...
** Bad device mmc 1 **
Loading envs from mmc 2...
** Bad device mmc 2 **
Loading envs from mmc 3...
** Bad device mmc 3 **
running scan_disk ...
Scan device usb
device usb 0:1
1 bytes read in 692 ms (0 Bytes/s)
Found bootable drive on usb 0
loading uImage ...
5435888 bytes read in 985 ms (5.3 MiB/s)
loading uInitrd ...
9671091 bytes read in 1431 ms (6.4 MiB/s)
loading DTB /boot/dts/kirkwood-goflexnet.dtb ...
11457 bytes read in 3291 ms (2.9 KiB/s)
## Booting kernel from Legacy Image at 00800000 ...
   Image Name:   Linux-5.13.6-kirkwood-tld-1
   Created:      2021-09-24   0:22:58 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    5435824 Bytes = 5.2 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 01100000 ...
   Image Name:   initramfs-5.13.6-kirkwood-tld-1
   Created:      2021-09-24   1:06:32 UTC
   Image Type:   ARM Linux RAMDisk Image (gzip compressed)
   Data Size:    9671027 Bytes = 9.2 MiB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK
## Flattened Device Tree blob at 01c00000
   Booting using the fdt blob at 0x1c00000


Starting kernel ...

Remark: This is a particularly slow thumb drive ... I

Lexar USB 3.0

U-Boot 2017.07-tld-1 (Sep 05 2017 - 00:17:19 -0700)
Seagate GoFlex Net
gcc (Debian 6.3.0-18) 6.3.0 20170516
GNU ld (GNU Binutils for Debian) 2.28
Hit any key to stop autoboot:  0 
Initializing devices...
starting USB...
USB0:   USB EHCI 1.00
scanning bus 0 for devices... 2 USB Device(s) found
       scanning usb for storage devices... 
Use USB retry period from the environment: 15 second(s)
1 Storage Device(s) found

Reset IDE: ide_preinit failed
Unknown command 'mmc' - try 'help'
Loading envs from usb 0...
** File not found /boot/uEnv.txt **
Loading envs from usb 1...
** Bad device usb 1 **
Loading envs from usb 2...
** Bad device usb 2 **
Loading envs from usb 3...
** Bad device usb 3 **
Loading envs from ide 0...
** Bad device ide 0 **
Loading envs from ide 1...
** Bad device ide 1 **
Loading envs from ide 2...
** Bad device ide 2 **
Loading envs from ide 3...
** Bad device ide 3 **
Loading envs from mmc 0...
** Bad device mmc 0 **
Loading envs from mmc 1...
** Bad device mmc 1 **
Loading envs from mmc 2...
** Bad device mmc 2 **
Loading envs from mmc 3...
** Bad device mmc 3 **
running scan_disk ...
Scan device usb
device usb 0:1
1 bytes read in 538 ms (0 Bytes/s)
Found bootable drive on usb 0
loading uImage ...
4551232 bytes read in 676 ms (6.4 MiB/s)
loading uInitrd ...
8139969 bytes read in 710 ms (10.9 MiB/s)
loading DTB /boot/dts/kirkwood-goflexnet.dtb ...
11445 bytes read in 1538 ms (6.8 KiB/s)
## Booting kernel from Legacy Image at 00800000 ...
   Image Name:   Linux-5.1.0-kirkwood-tld-1
   Created:      2019-05-29  19:58:08 UTC
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    4551168 Bytes = 4.3 MiB
   Load Address: 00008000
   Entry Point:  00008000
   Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 01100000 ...
   Image Name:   initramfs-5.1.0-kirkwood-tld-1
   Created:      2019-05-29  19:58:23 UTC
   Image Type:   ARM Linux RAMDisk Image (gzip compressed)
   Data Size:    8139905 Bytes = 7.8 MiB
   Load Address: 00000000
   Entry Point:  00000000
   Verifying Checksum ... OK
## Flattened Device Tree blob at 01c00000
   Booting using the fdt blob at 0x1c00000


Starting kernel ...

Remark: This is quite a fast thumb drive ... In any case, all this does show that it is the drive (or rather the USB connector) which is responsible for the (non-)problems ... Also, once I am finished, the GoFlexNet will (hopefully) boot from IDE again.

Cheers,

chessplayer

---
Standart ist der Standardfehler
Re: Problem overwriting ethaddr (and remedy) / Picky about USB drives?
August 02, 2022 07:49AM
Can't overwrite "ethaddr" was reported here before. Don't know why it happens. But there are solutions available:

1 change it in u-boot.

2 use a different version of fw_setenv or OS. (just like you changed it in Openwrt)


https://forum.doozan.com/read.php?3,45299,46159

https://forum.doozan.com/read.php?3,31453,31453
Re: Problem overwriting ethaddr (and remedy) / Picky about USB drives?
August 02, 2022 08:00AM
Another possible solution to non-bootable usb flash drive: put a usb hub between the usb flash drive and the device.

This is from my notebook



Sometimes, u-boot's usb system won't work so well, some of the usb flash drives can not be detected.

Eg, sandisk 32gb usb 2.0 disk drive (Walmart cheapo) won't get detected in Ctera C200 V1's u-boot 2021 v0.3, it will show
0 storage device detected. And of course, it won't be able to boot.

However, if we add one usb hub to it, this might change. Eg, I added one NX USB 2.0 hub to it and the drive
got detected and system can boot without problem.

Might be a power problem? Maybe to initialize this drive, it needs more power than the C200 V1 usb port can
handle. So it can not get detected.

reason: if the NX usb 2.0 hub is not connected to a power supply (worked in bus powered mode), the sandisk flash drive still won't get detected. However, if the usb hub is powered, although the power supply of the usb hub is just 5.3v 0.5A (Nokia old phone charger), the flash drive will be detected by U-boot.


Maybe not related to power.

Proof: Added one staples brand usb 2.0 hub between the sandisk 32gb drive and C200-V1 usb port, it worked.

Staples usb 2.0 hub is bus powered only. It can not connect to an external power supply!


Well, it looks complicated. Anyway, if the flash drive doesn't work in u-boot, add a usb hub and it might change.
Attachments:
open | download - reference_only.jpg (276.5 KB)
Re: Problem overwriting ethaddr (and remedy) / Picky about USB drives?
August 02, 2022 08:22AM
daviddyer Wrote:
-------------------------------------------------------
[snip ...]
>
> Well, it looks complicated. Anyway, if the flash
> drive doesn't work in u-boot, add a usb hub and it
> might change.


Ah, that seems like a way to go, if need be - thanks for that. Anyway, the GoflexNet is now booting from HDD again with the latest uBoot and I have a USB drive which seems to work (and a Rescue system if everything else fails) - so I should be good.

Cheers,

chessplayer

---
Standart ist der Standardfehler
Re: Problem overwriting ethaddr (and remedy) / Picky about USB drives?
August 02, 2022 03:27PM
The problem with USB "EHCI timed out on TD" error was analyzed and fixed (almost) by rayvt's patch, which I included in the u-boot 2017.07-tld-1. However, the patch did not fix all, there seems to be some drives that still have this problem.

The external power hub or non-power Hub is a good workaround. Because the driver in the external hub controller most oftenly can run at the same "speed" as the Kirkwood box. And the external hub manages the handshake with the "slow" thumb drives.

-bodhi
===========================
Forum Wiki
bodhi's corner
Author:

Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: