All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot-Users] usb storage return value is always true
@ 2008-03-19  1:56 Aras Vaichas
  0 siblings, 0 replies; only message in thread
From: Aras Vaichas @ 2008-03-19  1:56 UTC (permalink / raw)
  To: u-boot

I'm using U-Boot 1.3.2 with AT91RM9200 custom board (based on DK)

At boot time I want to detect that a USB storage device has been
inserted, and then I want to attempt to load an image off it and upgrade
my system.

If I run "usb storage" it always returns 0 - even if there is no USB
storage device inserted. If I run fatload on a non-existent device, it
has a very long timeout period.

e.g.

U-Boot> usb start
(Re)start USB...
USB:   scanning bus for devices... 1 USB Device(s) found
       scanning bus for storage devices... 0 Storage Device(s) found
U-Boot> usb storage; echo $?
No storage devices, perhaps not 'usb start'ed..?
0
U-Boot> usb start
(Re)start USB...
USB:   scanning bus for devices... 2 USB Device(s) found
       scanning bus for storage devices... 1 Storage Device(s) found
U-Boot>  usb storage; echo $?
  Device 0: Vendor:          Prod.:                  Rev: PMAP
            Type: Removable Hard Disk
            Capacity: 245.5 MB = 0.2 GB (502784 x 512)
0


Is there a way to detect if a USB storage device has been inserted?

Aras

______________________________________________________________________
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email 
______________________________________________________________________

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2008-03-19  1:56 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-03-19  1:56 [U-Boot-Users] usb storage return value is always true Aras Vaichas

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.