1. 13 4月, 2011 10 次提交
    • M
      USB: musb: blackfin: work around anomaly 05000450 · 13254307
      Mike Frysinger 提交于
      DMA mode 1 data corruption anomaly on Blackfin systems.  This issue is
      specific to the Blackfin silicon as the bug appears to be related to the
      connection of the musb ip to the bus/dma fabric.
      
      Data corruption when using USB DMA mode 1. (Issue manager 17-01-0105)
      DMA mode 1 allows large size transfers to generate a single interrupt
      at the end of the entire transfer.  The transfer is split up in packets
      of length specified in the Maximum Packet Size field for that endpoint.
      If the transfer size is not an integer multiple of the Maximum Packet
      Size, a short packet will be present at the end of the transfer.
      
      Under certain conditions this packet may be corrupted in the USB FIFO.
      
      Workaround:
      Use DMA mode 1 to transfer (n* Maximum Packet Size) and schedule DMA
      mode 0 to transfer the short packet.
      
      As an example if your transfer size is 33168 bytes and Maximum Packet
      Size equals 512, schedule [33168 - (33168 mod 512)] in DMA mode 1 and
      the remainder (33168 mod 512) in DMA mode 0.
      Signed-off-by: NMike Frysinger <vapier@gentoo.org>
      Signed-off-by: NFelipe Balbi <balbi@ti.com>
      13254307
    • H
      usb: musb: Fix the crash issue during reboot · 4f9edd2d
      Hema HK 提交于
      Below crash observed with commit 7acc6197
      (usb: musb: Idle path retention and offmode support for OMAP3)
      during board reboot.
      
      The musb clock was disabled when musb_shutdown() was called by
      platform_drv_shutdown in which there are register accesses.
      call pm_runtime_get_sync() and pm_runtime_put_sync() in the
      musb_shutdown function.
      
      / # [  172.368774] Unhandled fault: imprecise external abort (0x1406) at 0x400f0000
      [  172.376190] Internal error: : 1406 [#1] SMP
      [  172.380554] last sysfs file: /sys/devices/platform/omap/omap_i2c.4/i2c-4/i2c-dev/i2c-4/dev
      [  172.389221] Modules linked in:
      [  172.392456] CPU: 0    Tainted: G        W    (2.6.38-06671-geddecbb6 #33)
      [  172.399475] PC is at do_raw_spin_unlock+0x50/0xc0
      [  172.404418] LR is at _raw_spin_unlock_irqrestore+0x24/0x44
      [  172.410186] pc : [<c069bfdc>]    lr : [<c085a7f8>]    psr: 60000093
      [  172.410186] sp : ee993e40  ip : c0d00240  fp : bea9cf14
      [  172.422241] r10: 00000000  r9 : ee992000  r8 : c04b2fa8
      [  172.427703] r7 : 00000000  r6 : c0fa46c0  r5 : ef966124  r4 : ef966124
      [  172.434539] r3 : ef92cbc0  r2 : ef92cbc0  r1 : 00000000  r0 : ef966124
      [  172.441406] Flags: nZCv  IRQs off  FIQs on  Mode SVC_32  ISA ARM  Segment user
      [  172.448974] Control: 10c5387d  Table: ae8d804a  DAC: 00000015
      [  172.454986] Process init (pid: 1094, stack limit = 0xee9922f8)
      [  172.461120] Stack: (0xee993e40 to 0xee994000)
      [  172.465667] 3e40: a0000013 c085a7f8 ef966124 a0000013 c0fa46c0 c0761ab4 c0761a70 ef95c008
      [  172.474273] 3e60: ef95c014 c06e2fd0 c06e2fbc c06dea90 00000000 01234567 28121969 c04fccb4
      [  172.482849] 3e80: 00000000 c04fcd04 c0a302bc c04fce44 c0a02600 00000001 00000000 c085cd04
      [  172.491424] 3ea0: 00000000 00000002 c09ea000 c085afc0 ee993f24 00000000 00040001 00000445
      [  172.499999] 3ec0: a8eb9d34 00000027 00000000 00000000 00000000 c0a56a4c 00000000 00000000
      [  172.508575] 3ee0: 00000002 60000093 00000000 c0519aac 00000002 00000080 00000000 c0550420
      [  172.517150] 3f00: 00000000 00000002 ee970000 c0a56a3c c0a56a20 00000002 c0a56a3c 00000000
      [  172.525726] 3f20: c0a56a3c 0000000a c1580e00 c0a56a20 00000002 c0a56a3c c1580e00 c0a56a20
      [  172.534301] 3f40: ef92cbc0 c05173a0 00000001 ef92cbc0 c0576190 c04e3174 20000013 c0517324
      [  172.542877] 3f60: ef815c00 ee90b720 c04e3174 c0576190 00000001 ef92cbc0 c04b2f00 ffffffff
      [  172.551483] 3f80: 00000058 c0517324 00000000 00000000 ffffffff 00000000 00000000 ffffffff
      [  172.560058] 3fa0: 00000058 c04b2de0 00000000 00000000 fee1dead 28121969 01234567 00000000
      [  172.568634] 3fc0: 00000000 00000000 ffffffff 00000058 00000000 00000001 400aa000 bea9cf14
      [  172.577209] 3fe0: 000ea148 bea9c958 000aa750 40225728 60000010 fee1dead 00000000 00000000
      [  172.585784] [<c069bfdc>] (do_raw_spin_unlock+0x50/0xc0) from [<c085a7f8>] (_raw_spin_unlock_irqrestore+0x24/0x44)
      [  172.596588] [<c085a7f8>] (_raw_spin_unlock_irqrestore+0x24/0x44) from [<c0761ab4>] (musb_shutdown+0x44/0x88)
      [  172.606933] [<c0761ab4>] (musb_shutdown+0x44/0x88) from [<c06e2fd0>] (platform_drv_shutdown+0x14/0x18)
      [  172.616699] [<c06e2fd0>] (platform_drv_shutdown+0x14/0x18) from [<c06dea90>] (device_shutdown+0x74/0xb4)
      [  172.626647] [<c06dea90>] (device_shutdown+0x74/0xb4) from [<c04fccb4>] (kernel_restart_prepare+0x24/0x38)
      [  172.636688] [<c04fccb4>] (kernel_restart_prepare+0x24/0x38) from [<c04fcd04>] (kernel_restart+0xc/0x48)
      [  172.646545] [<c04fcd04>] (kernel_restart+0xc/0x48) from [<c04fce44>] (sys_reboot+0xfc/0x1d8)
      [  172.655426] [<c04fce44>] (sys_reboot+0xfc/0x1d8) from [<c04b2de0>] (ret_fast_syscall+0x0/0x3c)
      [  172.664459] Code: e3c3303f e594200c e593300c e1520003 (0a000002)
      [  172.670867] ------------[ cut here ]------------
      Signed-off-by: NHema HK <hemahk@ti.com>
      Signed-off-by: NFelipe Balbi <balbi@ti.com>
      4f9edd2d
    • F
      usb: musb: gadget: check the correct list_head · 3d5ad13e
      Felipe Balbi 提交于
      We are now using our own list_head, so we should
      be checking against that, not the gadget driver's
      list_head.
      Signed-off-by: NFelipe Balbi <balbi@ti.com>
      3d5ad13e
    • F
      usb: musb: temporarily make it bool · 7a180e70
      Felipe Balbi 提交于
      Due to the recent changes to musb's glue layers,
      we can't compile musb-hdrc as a module - compilation
      will break due to undefined symbol musb_debug. In
      order to fix that, we need a big re-work of the
      debug support on the MUSB driver.
      
      Because that would mean a lot of new code coming
      into the -rc series, it's best to defer that to
      next merge window and for now just disable module
      support for MUSB.
      
      Once we get the refactor of the debugging support
      done, we can simply revert this patch and things
      will go back to normal again.
      
      Cc: stable@kernel.org # v2.6.38
      Signed-off-by: NFelipe Balbi <balbi@ti.com>
      7a180e70
    • D
      USB: musb: dereferencing an iomem pointer · 2e10f5e7
      Dan Carpenter 提交于
      "tx_ram" points to io memory.  We can't dereference it directly.  Sparse
      complains about this: "drivers/usb/musb/cppi_dma.c:1205:25: warning:
      dereference of noderef expression"
      Signed-off-by: NDan Carpenter <error27@gmail.com>
      Signed-off-by: NFelipe Balbi <balbi@ti.com>
      2e10f5e7
    • D
      USB: musb: silence printk format warning · 2fbcf3fa
      Dan Carpenter 提交于
      Gcc gives the following warnings:
      
      drivers/usb/musb/cppi_dma.c: In function ‘cppi_next_tx_segment’:
      drivers/usb/musb/cppi_dma.c:600: warning: format ‘%x’ expects type ‘unsigned int’, but argument 8 has type ‘dma_addr_t’
      drivers/usb/musb/cppi_dma.c: In function ‘cppi_next_rx_segment’:
      drivers/usb/musb/cppi_dma.c:822: warning: format ‘%x’ expects type ‘unsigned int’, but argument 9 has type ‘dma_addr_t’
      drivers/usb/musb/cppi_dma.c: In function ‘cppi_rx_scan’:
      drivers/usb/musb/cppi_dma.c:1042: warning: format ‘%08x’ expects type ‘unsigned int’, but argument 4 has type ‘dma_addr_t’
      drivers/usb/musb/cppi_dma.c:1114: warning: format ‘%08x’ expects type ‘unsigned int’, but argument 7 has type ‘dma_addr_t’
      
      dma_addr_t is sometimes 32 bit and sometimes 64.  We normally cast them
      to unsigned long long for printk().
      Signed-off-by: NDan Carpenter <error27@gmail.com>
      Signed-off-by: NFelipe Balbi <balbi@ti.com>
      2fbcf3fa
    • D
      USB: musb: using 0 instead of NULL · aca7f353
      Dan Carpenter 提交于
      Sparse complains (and rightly so):
      drivers/usb/musb/cppi_dma.c:1458:33:
      	warning: Using plain integer as NULL pointer
      Signed-off-by: NDan Carpenter <error27@gmail.com>
      Signed-off-by: NFelipe Balbi <balbi@ti.com>
      aca7f353
    • D
      USB: musb: add missing unlock in cppi_interrupt() · ec63bf6c
      Dan Carpenter 提交于
      We should unlock before returning here.
      Signed-off-by: NDan Carpenter <error27@gmail.com>
      Signed-off-by: NFelipe Balbi <balbi@ti.com>
      ec63bf6c
    • M
      usb: musb: ux500: copy dma mask from platform device to musb device · 87266064
      Mian Yousaf Kaukab 提交于
      musb code checks dma mask before calling dma hooks.
      Signed-off-by: NMian Yousaf Kaukab <mian.yousaf.kaukab@stericsson.com>
      Signed-off-by: NFelipe Balbi <balbi@ti.com>
      87266064
    • M
      usb: musb: clear AUTOSET while clearing DMAENAB · 100d4a9d
      Mian Yousaf Kaukab 提交于
      On the completion of tx dma, dma is disabled by clearing MUSB_TXCSR_DMAENAB in
      TXCSR. If MUSB_TXCSR_AUTOSET was set in txstate() it will remain set although
      it is not needed in PIO mode. Clear it as soon as it is not needed.
      Signed-off-by: NMian Yousaf Kaukab <mian.yousaf.kaukab@stericsson.com>
      Signed-off-by: NFelipe Balbi <balbi@ti.com>
      100d4a9d
  2. 06 4月, 2011 20 次提交
  3. 05 4月, 2011 10 次提交