[#5147] Fails to write to usb storage with sl811 on bf537-stamp

Document created by Aaronwu Employee on Sep 3, 2013
Version 1Show Document
  • View in full screen mode

[#5147] Fails to write to usb storage with sl811 on bf537-stamp

Submitted By: Vivi Li

Open Date

2009-05-20 04:58:54     Close Date

2009-07-14 06:51:09

Priority:

Medium High     Assignee:

Michael Hennerich

Status:

Closed     Fixed In Release:

N/A

Found In Release:

N/A     Release:

Category:

Drivers     Board:

N/A

Processor:

BF537     Silicon Revision:

Is this bug repeatable?:

Yes     Resolution:

Not reproducible

Uboot version or rev.:

    Toolchain version or rev.:

gcc4.1-09r1_rc6

App binary format:

N/A     

Summary: Fails to write to usb storage with sl811 on bf537-stamp

Details:

 

Fails to write to usb storage with sl811 on bf537-stamp.

 

Config is attached and below is the log:

--

Linux version 2.6.28.10-ADI-2009R1-pre-svn6363 (test@uclinux54-adv7393-ad1981-usb1362) (gcc version 4.1.2 (ADI svn)) #171 Mon Ma9

Warning: limiting memory to 56MB due to hardware anomaly 05000263

Board Memory: 64MB

Kernel Managed Memory: 64MB

Memory map:

  fixedcode = 0x00000400-0x00000490

  text      = 0x00001000-0x001393a0

  rodata    = 0x001393a0-0x0019edfc

  bss       = 0x0019f000-0x001b0e6c

  data      = 0x001b0e6c-0x001c6000

    stack   = 0x001c4000-0x001c6000

  init      = 0x001c6000-0x00959000

  available = 0x00959000-0x037ff000

  DMA Zone  = 0x03f00000-0x04000000

Hardware Trace Active and Enabled

Boot Mode: 0

Reset caused by Software reset

Blackfin support (C) 2004-2009 Analog Devices, Inc.

Compiled for ADSP-BF537 Rev 0.2

Blackfin Linux support by http://blackfin.uclinux.org/

Processor Speed: 500 MHz core clock and 125 MHz System Clock

NOMPU: setting up cplb tables

Instruction Cache Enabled for CPU0

Data Cache Enabled for CPU0 (write-back)

Built 1 zonelists in Zone order, mobility grouping off.  Total pages: 14223

Kernel command line: root=/dev/mtdblock0 rw ip=10.100.4.50:10.100.4.174:10.100.4.174:255.255.255.0:BF537:eth0:off

Configuring Blackfin Priority Driven Interrupts

PID hash table entries: 256 (order: 8, 1024 bytes)

console [ttyBF0] enabled

Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)

Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)

Memory available: 47200k/65536k RAM, (7756k init code, 1248k kernel code, 564k data, 1024k dma, 7744k reserved)

Calibrating delay loop... 997.37 BogoMIPS (lpj=1994752)

Security Framework initialized

Mount-cache hash table entries: 512

Blackfin Scratchpad data SRAM: 4 KB

Blackfin L1 Data A SRAM: 16 KB (15 KB free)

Blackfin L1 Data B SRAM: 16 KB (16 KB free)

Blackfin L1 Instruction SRAM: 48 KB (37 KB free)

PDA for CPU0 reserved at 001a2000

net_namespace: 288 bytes

NET: Registered protocol family 16

Blackfin DMA Controller

stamp_init(): registering device resources

SCSI subsystem initialized

usbcore: registered new interface driver usbfs

usbcore: registered new interface driver hub

usbcore: registered new device driver usb

NET: Registered protocol family 2

IP route cache hash table entries: 1024 (order: 0, 4096 bytes)

TCP established hash table entries: 2048 (order: 2, 16384 bytes)

TCP bind hash table entries: 2048 (order: 1, 8192 bytes)

TCP: Hash tables configured (established 2048 bind 2048)

TCP reno registered

NET: Registered protocol family 1

msgmni has been set to 92

io scheduler noop registered

io scheduler anticipatory registered (default)

io scheduler cfq registered

Serial: Blackfin serial driver

bfin-uart.1: ttyBF0 at MMIO 0xffc00400 (irq = 18) is a BFIN-UART

brd: module loaded

bfin_mii_bus: probed

bfin_mac: attached PHY driver [SMSC LAN83C185] (mii_bus:phy_addr=0:01, irq=-1, mdc_clk=2500000Hz(mdc_div=24)@sclk=125MHz)

bfin_mac bfin_mac.0: Blackfin on-chip Ethernet MAC driver, Version 1.1

Driver 'sd' needs updating - please use bus_type methods

bfin-spi bfin-spi.0: Blackfin on-chip SPI Controller Driver, Version 1.0, regs_base@ffc00500, dma channel@7

driver isp1362-hcd, 2005-04-04

isp1362-hcd isp1362-hcd.0: ISP1362 Host Controller

isp1362-hcd isp1362-hcd.0: new USB bus registered, assigned bus number 1

isp1362_hc_reset:

isp1362-hcd isp1362-hcd.0: irq 53, io mem 0x20360000

isp1362_hc_start:

isp1362-hcd isp1362-hcd.0: ISP1362 Memory usage:

isp1362-hcd isp1362-hcd.0:   ISTL:    2 *  256:      512 @ $0000:$0100

isp1362-hcd isp1362-hcd.0:   INTL:   16 * ( 64+8):  1152 @ $0200

isp1362-hcd isp1362-hcd.0:   ATL :   32 * ( 64+8):  2304 @ $0680

isp1362-hcd isp1362-hcd.0:   USED/FREE:   3968       128

usb usb1: configuration #1 chosen from 1 choice

hub 1-0:1.0: USB hub found

hub 1-0:1.0: 2 ports detected

ISP1362 Host Controller, irq 53

sl811: driver sl811-hcd, 19 May 2005

sl811-hcd sl811-hcd.0: SL811HS v1.5

sl811-hcd sl811-hcd.0: new USB bus registered, assigned bus number 2

sl811-hcd sl811-hcd.0: irq 54, io mem 0x20340000

usb usb2: configuration #1 chosen from 1 choice

hub 2-0:1.0: USB hub found

hub 2-0:1.0: 1 port detected

Initializing USB Mass Storage driver...

usbcore: registered new interface driver usb-storage

USB Mass Storage support registered.

rtc-bfin rtc-bfin: rtc core: registered rtc-bfin as rtc0

bfin-wdt: initialized: timeout=20 sec (nowayout=0)

usbcore: registered new interface driver usbhid

usbhid: v2.6:USB HID core driver

TCP cubic registered

NET: Registered protocol family 17

rtc-bfin rtc-bfin: setting system clock to 1970-01-01 14:40:06 UTC (52806)

usb 1-2: new full speed USB device using isp1362-hcd and address 2

usb 1-2: configuration #1 chosen from 1 choice

scsi0 : SCSI emulation for USB Mass Storage devices

usb 2-1: new full speed USB device using sl811-hcd and address 2

usb 2-1: configuration #1 chosen from 1 choice

scsi1 : SCSI emulation for USB Mass Storage devices

IP-Config: Complete:

     device=eth0, addr=10.100.4.50, mask=255.255.255.0, gw=10.100.4.174,

     host=BF537, domain=, nis-domain=(none),

     bootserver=10.100.4.174, rootserver=10.100.4.174, rootpath=

Freeing unused kernel memory: 7756k freed

dma_alloc_init: dma_page @ 0x00956000 - 256 pages at 0x03f00000

PHY: 0:01 - Link is Up - 100/Full

                           _____________________________________

        a8888b.           / Welcome to the uClinux distribution \

       d888888b.         /       _     _                         \

       8P"YP"Y88        /       | |   |_|            __  __ (TM)  |

       8|o||o|88  _____/        | |    _ ____  _   _ \ \/ /       |

       8'    .88       \        | |   | |  _ \| | | | \  /        |

       8`._.' Y8.       \       | |__ | | | | | |_| | /  \        |

      d/      `8b.       \      \____||_|_| |_|\____|/_/\_\       |

     dP   .    Y8b.       \   For embedded processors including   |

    d8:'  "  `::88b        \    the Analog Devices Blackfin      /

   d8"         'Y88b        \___________________________________/

  :8P    '      :888

   8a.   :     _a88P         For further information, check out:

._/"Yaa_:   .| 88P|            - http://blackfin.uclinux.org/

\    YP"    `| 8P  `.          - http://docs.blackfin.uclinux.org/

/     \.___.d|    .'           - http://www.uclinux.org/

`--..__)8888P`._.'  jgs/a:f    - http://www.analog.com/blackfin

 

Have a lot of fun...

 

 

BusyBox v1.13.4 (2009-05-18 08:13:53 CST) built-in shell (msh)

Enter 'help' for a list of built-in commands.

 

root:/> scsi 0:0:0:0: Direct-Access     Kingston DataTraveler 2.0 1.00 PQ: 0 ANSI: 2

sd 0:0:0:0: [sda] 1952768 512-byte hardware sectors: (999 MB/953 MiB)

sd 0:0:0:0: [sda] Write Protect is off

sd 0:0:0:0: [sda] Assuming drive cache: write through

sd 0:0:0:0: [sda] 1952768 512-byte hardware sectors: (999 MB/953 MiB)

sd 0:0:0:0: [sda] Write Protect is off

sd 0:0:0:0: [sda] Assuming drive cache: write through

sda: sda1

sd 0:0:0:0: [sda] Attached SCSI removable disk

scsi 1:0:0:0: Direct-Access     USB 2.0  Flash Disk       1.00 PQ: 0 ANSI: 2

sd 1:0:0:0: [sdb] 2007040 512-byte hardware sectors: (1.02 GB/980 MiB)

sd 1:0:0:0: [sdb] Write Protect is off

sd 1:0:0:0: [sdb] Assuming drive cache: write through

sd 1:0:0:0: [sdb] 2007040 512-byte hardware sectors: (1.02 GB/980 MiB)

sd 1:0:0:0: [sdb] Write Protect is off

sd 1:0:0:0: [sdb] Assuming drive cache: write through

sdb: sdb1

sd 1:0:0:0: [sdb] Attached SCSI removable disk

 

root:/> mount /dev/sdb1 /mnt/

root:/> mount

rootfs on / type rootfs (rw)

proc on /proc type proc (rw,nosuid,nodev,noexec)

sysfs on /sys type sysfs (rw,nosuid,nodev,noexec)

mdev on /dev type tmpfs (rw,nosuid)

devpts on /dev/pts type devpts (rw,nosuid,noexec,mode=600)

var on /var type ramfs (rw)

tmp on /tmp type tmpfs (rw,nosuid,nodev)

debugfs on /sys/kernel/debug type debugfs (rw)

/dev/sdb1 on /mnt type vfat (rw,fmask=0022,dmask=0022,codepage=cp437,iocharset=iso8859-1)

root:/> cd /mnt/

root:/mnt> time dd conv=fsync if=/dev/zero of=/mnt/bin bs=1M count=1

1+0 records in

1+0 records out

real    0m 1.26s

user    0m 0.00s

sys     0m 0.11s

root:/mnt> time dd conv=fsync if=/dev/zero of=/mnt/bin bs=1M count=5

5+0 records in

5+0 records out

real    0m 5.94s

user    0m 0.00s

sys     0m 0.28s

root:/mnt> time dd conv=fsync if=/dev/zero of=/mnt/bin bs=1M count=10

usb 2-1: reset full speed USB device using sl811-hcd and address 2

usb 2-1: device descriptor read/64, error -110

usb 2-1: device descriptor read/64, error -110

usb 2-1: reset full speed USB device using sl811-hcd and address 2

usb 2-1: device descriptor read/64, error -110

usb 2-1: device descriptor read/64, error -110

usb 2-1: reset full speed USB device using sl811-hcd and address 2

usb 2-1: device not accepting address 2, error -110

usb 2-1: reset full speed USB device using sl811-hcd and address 2

usb 2-1: device not accepting address 2, error -110

usb 2-1: USB disconnect, address 2

sd 1:0:0:0: Device offlined - not ready after error recovery

sd 1:0:0:0: [sdb] Result: hostbyte=0x05 driverbyte=0x00

end_request: I/O error, dev sdb, sector 160158

sd 1:0:0:0: rejecting I/O to offline device

sd 1:0:0:0: rejecting I/O to offline device

sd 1:0:0:0: rejecting I/O to offline device

sd 1:0:0:0: rejecting I/O to offline device

sd 1:0:0:0: rejecting I/O to offline device

sd 1:0:0:0: rejecting I/O to offline device

sd 1:0:0:0: rejecting I/O to offline device

Buffer I/O error on device sdb1, logical block 3944

lost page write due to I/O error on sdb1

sd 1:0:0:0: rejecting I/O to offline device

Buffer I/O error on device sdb1, logical block 2141

lost page write due to I/O error on sdb1

Buffer I/O error on device sdb1, logical block 2142

lost page write due to I/O error on sdb1

Buffer I/O error on device sdb1, logical block 2143

lost page write due to I/O error on sdb1

sd 1:0:0:0: rejecting I/O to offline device

Buffer I/O error on device sdb1, logical block 186

lost page write due to I/O error on sdb1

Buffer I/O error on device sdb1, logical block 187

lost page write due to I/O error on sdb1

Buffer I/O error on device sdb1, logical block 188

lost page write due to I/O error on sdb1

sd 1:0:0:0: rejecting I/O to offline device

Buffer I/O error on device sdb1, logical block 1

lost page write due to I/O error on sdb1

sd 1:0:0:0: [sdb] Result: hostbyte=0x01 driverbyte=0x00

end_request: I/O error, dev sdb, sector 160398

dd: /mnt/bin: Input/output error

Command exited with non-zero status 1

real    1m 54.71s

user    0m 0.00s

sys     0m 0.14s

root:/mnt>

--

 

Follow-ups

 

--- Michael Hennerich                                        2009-05-25 05:16:36

Works OK for me - however you should set:

CONFIG_DUMMY_DELAY_BANK0=y

in your config.

See below -

-Michael

 

CONFIG_USB_SL811_HCD=y

CONFIG_USB_SL811_BFIN_IRQ=54

# CONFIG_NO_DUMMY_DELAY is not set

CONFIG_DUMMY_DELAY_BANK0=y

# CONFIG_DUMMY_DELAY_BANK1 is not set

# CONFIG_DUMMY_DELAY_BANK2 is not set

# CONFIG_DUMMY_DELAY_BANK3 is not set

# CONFIG_USB_R8A66597_HCD is not set

 

 

root:/> mount /dev/sda1 /mnt                                               

                                 

root:/> cd mnt                                                             

                                 

root:/mnt> time dd conv=fsync if=/dev/zero of=/mnt/bin bs=1M count=5       

                                 

5+0 records in                                                                

                              

5+0 records out                                                               

                              

real    0m 8.97s                                                              

                              

user    0m 0.00s                                                              

                              

sys     0m 0.21s                                                              

                              

root:/mnt> time dd conv=fsync if=/dev/zero of=/mnt/bin bs=1M count=5       

                                 

5+0 records in                                                                

                              

5+0 records out                                                               

                              

real    0m 8.95s                                                              

                              

user    0m 0.00s                                                              

                              

sys     0m 0.24s                                                              

                              

root:/mnt> time dd conv=fsync if=/dev/zero of=/mnt/bin bs=1M count=10      

                                 

10+0 records in

10+0 records out

real    0m 17.32s

user    0m 0.00s

sys     0m 0.42s

root:/mnt> time dd conv=fsync if=/dev/zero of=/mnt/bin bs=1M count=10

10+0 records in

10+0 records out

real    0m 17.27s

user    0m 0.00s

sys     0m 0.43s

root:/mnt> time dd conv=fsync if=/dev/zero of=/mnt/bin bs=1M count=10

10+0 records in

10+0 records out

real    0m 17.22s

user    0m 0.00s

sys     0m 0.43s

root:/mnt> version

kernel:    Linux release 2.6.28.10-ADI-2010R1-pre-svn6467, build #10586 Mon May

25 11:04:35 CEST 2009

toolchain: bfin-linux-uclibc-gcc release gcc version 4.1.2 (ADI svn)

user-dist: release svn-8040, build #3619 Mon May 25 11:04:01 CEST 2009

root:/mnt> mount

rootfs on / type rootfs (rw)

proc on /proc type proc (rw,nosuid,nodev,noexec)

sysfs on /sys type sysfs (rw,nosuid,nodev,noexec)

mdev on /dev type tmpfs (rw,nosuid)

devpts on /dev/pts type devpts (rw,nosuid,noexec,mode=600)

var on /var type ramfs (rw)

tmp on /tmp type tmpfs (rw,nosuid,nodev)

debugfs on /sys/kernel/debug type debugfs (rw)

/dev/sda1 on /mnt type ext2 (rw,errors=continue)

root:/mnt>

 

--- Vivi Li                                                  2009-07-14 06:51:09

OK now. Close it.

 

 

 

    Files

    Changes

    Commits

    Dependencies

    Duplicates

    Associations

    Tags

 

File Name     File Type     File Size     Posted By

config.usbhost_1362&811    application/octet-stream    37733    Vivi Li

Outcomes