1. 01 3月, 2011 8 次提交
  2. 26 2月, 2011 3 次提交
  3. 18 2月, 2011 6 次提交
  4. 05 2月, 2011 7 次提交
    • P
      USB: Fix trout build failure with ci13xxx_msm gadget · 8cf28f1f
      Pavankumar Kondeti 提交于
      This patch fixes the below compilation errors.
      
        CC      drivers/usb/gadget/ci13xxx_msm.o
        CC      net/mac80211/led.o
        drivers/usb/gadget/ci13xxx_msm.c: In function 'ci13xxx_msm_notify_event':
        drivers/usb/gadget/ci13xxx_msm.c:42: error: 'USB_AHBBURST' undeclared (first use in this function)
        drivers/usb/gadget/ci13xxx_msm.c:42: error: (Each undeclared identifier is reported only once
        drivers/usb/gadget/ci13xxx_msm.c:42: error: for each function it appears in.)
        drivers/usb/gadget/ci13xxx_msm.c:43: error: 'USB_AHBMODE' undeclared (first use in this function)
      make[4]: *** [drivers/usb/gadget/ci13xxx_msm.o] Error 1
      make[3]: *** [drivers/usb/gadget] Error 2
      
      MSM USB driver is not supported on boards like trout (MSM7201) which
      has an external PHY.
      Signed-off-by: NPavankumar Kondeti <pkondeti@codeaurora.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      8cf28f1f
    • R
      USB: HCD: Add usb_hcd prefix to exported functions · c8cf203a
      Robert Morell 提交于
      The convention is to prefix symbols exported from the USB HCD core with
      "usb_hcd".  This change makes unmap_urb_setup_for_dma() and
      unmap_urb_for_dma() consistent with that.
      Signed-off-by: NRobert Morell <rmorell@nvidia.com>
      Acked-by: NAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      c8cf203a
    • D
      USB: EHCI: Rearrange create_companion_file() to avoid GCC-4.6 warnings. · ac8d6741
      David Daney 提交于
      In create_companion_file() there is a bogus assignemt to i created for
      the express purpose of avoiding an ignored return value warning.
      
      With pre-release GCC-4.6, this causes a 'set but not used' warning.
      
      Kick the problem further down the road by just returning i.  All the
      callers of create_companion_file() ignore its return value, so all is
      good:
      
      o No warnings are issued.
      
      o We still subvert the desires of the authors of device_create_file()
        by ignorning error conditions.
      Signed-off-by: NDavid Daney <ddaney@caviumnetworks.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      ac8d6741
    • D
      USB: EHCI: Rearrange EHCI_URB_TRACE code to avoid GCC-4.6 warnings. · eb34a908
      David Daney 提交于
      With pre-release GCC-4.6, we get a 'set but not used' warning when
      EHCI_URB_TRACE is not set because we set the qtd variable without
      using it.
      
      Rearrange the statements so that we only set qtd if it will be used.
      Signed-off-by: NDavid Daney <ddaney@caviumnetworks.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      eb34a908
    • D
      USB: EHCI: Cleanup and rewrite ehci_vdgb(). · 9a1cadb9
      David Daney 提交于
      The vdbg macro is not used anywhere so it can be removed.
      
      With pre-release GCC-4.6, there are several complaints of variables
      that are 'set but not used' caused by the ehci_vdbg() macro expanding
      to something that does not contain any of its arguments.  We can quiet
      this warning by rewriting ehci_vdbg() as a variadic static inline that
      does nothing.
      Signed-off-by: NDavid Daney <ddaney@caviumnetworks.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      9a1cadb9
    • D
      USB: EHCI: Remove dead code from ehci-sched.c · fc427a5a
      David Daney 提交于
      The pre-release GCC-4.6 now correctly flags this code as dead.
      Signed-off-by: NDavid Daney <ddaney@caviumnetworks.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      fc427a5a
    • A
      USB host: Move AMD PLL quirk to pci-quirks.c · b7d5b439
      Andiry Xu 提交于
      This patch moves the AMD PLL quirk code in OHCI/EHCI driver to pci-quirks.c,
      and exports the functions to be used by xHCI driver later.
      
      AMD PLL quirk disable the optional PM feature inside specific
      SB700/SB800/Hudson-2/3 platforms under the following conditions:
      
      1. If an isochronous device is connected to OHCI/EHCI/xHCI port and is active;
      2. Optional PM feature that powers down the internal Bus PLL when the link is
         in low power state is enabled.
      
      Without AMD PLL quirk, USB isochronous stream may stutter or have breaks
      occasionally, which greatly impair the performance of audio/video streams.
      
      Currently AMD PLL quirk is implemented in OHCI and EHCI driver, and will be
      added to xHCI driver too. They are doing similar things actually, so move
      the quirk code to pci-quirks.c, which has several advantages:
      
      1. Remove duplicate defines and functions in OHCI/EHCI (and xHCI) driver and
         make them cleaner;
      2. AMD chipset information will be probed only once and then stored.
         Currently they're probed during every OHCI/EHCI initialization, move
         the detect code to pci-quirks.c saves the repeat detect cost;
      3. Build up synchronization among OHCI/EHCI/xHCI driver. In current
         code, every host controller enable/disable PLL only according to
         its own status, and may enable PLL while there is still isoc transfer on
         other HCs. Move the quirk to pci-quirks.c prevents this issue.
      Signed-off-by: NAndiry Xu <andiry.xu@amd.com>
      Cc: David Brownell <dbrownell@users.sourceforge.net>
      Cc: Alex He <alex.he@amd.com>
      Acked-by: NAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      b7d5b439
  5. 04 2月, 2011 2 次提交
    • Y
      USB: EHCI: fix scheduling while atomic during suspend · 148fc55f
      Yin Kangkai 提交于
      There is a msleep with spin lock held during ehci pci suspend, which will
      cause kernel BUG: scheduling while atomic. Fix that.
      
      [  184.139620] BUG: scheduling while atomic: kworker/u:11/416/0x00000002
      [  184.139632] 4 locks held by kworker/u:11/416:
      [  184.139640]  #0:  (events_unbound){+.+.+.}, at: [<c104ddd4>] process_one_work+0x1b3/0x4cb
      [  184.139669]  #1:  ((&entry->work)){+.+.+.}, at: [<c104ddd4>] process_one_work+0x1b3/0x4cb
      [  184.139686]  #2:  (&__lockdep_no_validate__){+.+.+.}, at: [<c127cde3>] __device_suspend+0x2c/0x154
      [  184.139706]  #3:  (&(&ehci->lock)->rlock){-.-...}, at: [<c132f3d8>] ehci_pci_suspend+0x35/0x7b
      [  184.139725] Modules linked in: serio_raw pegasus joydev mrst_gfx(C) battery
      [  184.139748] irq event stamp: 52
      [  184.139753] hardirqs last  enabled at (51): [<c14fdaac>] mutex_lock_nested+0x258/0x293
      [  184.139766] hardirqs last disabled at (52): [<c14fe7b4>] _raw_spin_lock_irqsave+0xf/0x3e
      [  184.139777] softirqs last  enabled at (0): [<c10371c1>] copy_process+0x3d2/0x109d
      [  184.139789] softirqs last disabled at (0): [<  (null)>]   (null)
      [  184.139802] Pid: 416, comm: kworker/u:11 Tainted: G         C  2.6.37-6.3-adaptation-oaktrail #37
      [  184.139809] Call Trace:
      [  184.139820]  [<c102eeff>] __schedule_bug+0x5e/0x65
      [  184.139829]  [<c14fbca5>] schedule+0xac/0xc4c
      [  184.139840]  [<c11d4845>] ? string+0x37/0x8b
      [  184.139853]  [<c1044f21>] ? lock_timer_base+0x1f/0x3e
      [  184.139863]  [<c14fe7da>] ? _raw_spin_lock_irqsave+0x35/0x3e
      [  184.139876]  [<c1061590>] ? trace_hardirqs_off+0xb/0xd
      [  184.139885]  [<c14fccdc>] schedule_timeout+0x283/0x2d9
      [  184.139896]  [<c104516f>] ? process_timeout+0x0/0xa
      [  184.139906]  [<c14fcd47>] schedule_timeout_uninterruptible+0x15/0x17
      [  184.139916]  [<c104566a>] msleep+0x10/0x16
      [  184.139926]  [<c132f316>] ehci_adjust_port_wakeup_flags+0x69/0xf6
      [  184.139937]  [<c132f3eb>] ehci_pci_suspend+0x48/0x7b
      [  184.139946]  [<c1326587>] suspend_common+0x52/0xbb
      [  184.139956]  [<c1326625>] hcd_pci_suspend+0x26/0x28
      [  184.139967]  [<c11e7182>] pci_pm_suspend+0x5f/0xd0
      [  184.139976]  [<c127ca3a>] pm_op+0x5d/0xf0
      [  184.139986]  [<c127ceac>] __device_suspend+0xf5/0x154
      [  184.139996]  [<c127d2c8>] async_suspend+0x16/0x3a
      [  184.140006]  [<c1058f54>] async_run_entry_fn+0x89/0x111
      [  184.140016]  [<c104deb6>] process_one_work+0x295/0x4cb
      [  184.140026]  [<c1058ecb>] ? async_run_entry_fn+0x0/0x111
      [  184.140036]  [<c104e3d0>] worker_thread+0x17f/0x298
      [  184.140045]  [<c104e251>] ? worker_thread+0x0/0x298
      [  184.140055]  [<c105277f>] kthread+0x64/0x69
      [  184.140064]  [<c105271b>] ? kthread+0x0/0x69
      [  184.140075]  [<c1002efa>] kernel_thread_helper+0x6/0x1a
      Signed-off-by: NYin Kangkai <kangkai.yin@intel.com>
      Acked-by: NAlan Stern <stern@rowland.harvard.edu>
      CC: David Brownell <dbrownell@users.sourceforge.net>
      CC: stable@kernel.org
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      148fc55f
    • J
      USB SL811HS HCD: Fix memory leak in sl811h_urb_enqueue() · 2bd15f1f
      Jesper Juhl 提交于
      In drivers/usb/host/sl811-hcd.c::sl811h_urb_enqueue(), memory is allocated
      with kzalloc() and assigned to 'ep'. If we leave via the 'fail' label due
      to 'if (ep->maxpacket > H_MAXPACKET)', then 'ep' will go out of scope
      without having been assigned to anything, so we'll leak the memory we
      allocated.
      This patch fixes the leak by simply calling kfree(ep); before jumping to
      the 'fail' label.
      Signed-off-by: NJesper Juhl <jj@chaosbits.net>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      2bd15f1f
  6. 01 2月, 2011 1 次提交
  7. 23 1月, 2011 5 次提交
  8. 15 1月, 2011 8 次提交
    • M
      xhci: Remove more doorbell-related reads · 50d64676
      Matthew Wilcox 提交于
      The unused space in the doorbell is now marked as RsvdZ, not RsvdP, so
      we can avoid reading the doorbell before writing it.
      
      Update the doorbell-related defines to produce the entire doorbell value
      from a single macro.  Document the doorbell format in a comment.
      Signed-off-by: NMatthew Wilcox <willy@linux.intel.com>
      Signed-off-by: NSarah Sharp <sarah.a.sharp@linux.intel.com>
      50d64676
    • A
      xHCI: fix printk_ratelimit() usage · 7961acd7
      Andiry Xu 提交于
      printk_ratelimit() is misused in xhci-ring.c.
      Signed-off-by: NAndiry Xu <andiry.xu@amd.com>
      Signed-off-by: NSarah Sharp <sarah.a.sharp@linux.intel.com>
      7961acd7
    • A
      xHCI: replace dev_dbg() with xhci_dbg() · f2c565e2
      Andiry Xu 提交于
      dev_dbg() is used to print ordinary transfer messages in xhci-ring.c.
      System log messages will be flushed if CONFIG_USB_DEBUG is set. Replace the
      dev_dbg() with xhci_dbg().
      Signed-off-by: NAndiry Xu <andiry.xu@amd.com>
      Signed-off-by: NSarah Sharp <sarah.a.sharp@linux.intel.com>
      f2c565e2
    • A
      xHCI: fix cycle bit set in giveback_first_trb() · 50f7b52a
      Andiry Xu 提交于
      giveback_first_trb() controls the cycle bit set of the start_trb, to ensure
      that the start_trb is written last and the host controller will receive a
      whole td at a time.
      
      However, if the ring is wrapped and cycle bit is toggled to zero, then
      giveback_first_trb() will be of no effect. In this case, set the cycle bit of
      start_trb to 1 at the beginning and clear it in giveback_first_trb().
      Signed-off-by: NAndiry Xu <andiry.xu@amd.com>
      Signed-off-by: NSarah Sharp <sarah.a.sharp@linux.intel.com>
      50f7b52a
    • A
      xHCI: remove redundant parameter in giveback_first_trb() · e1eab2e0
      Andiry Xu 提交于
      Parameter *td is not used in giveback_first_trb(). Remove it.
      Signed-off-by: NAndiry Xu <andiry.xu@amd.com>
      Signed-off-by: NSarah Sharp <sarah.a.sharp@linux.intel.com>
      e1eab2e0
    • A
      xHCI: fix queue_trb in isoc transfer · 47cbf692
      Andiry Xu 提交于
      Fix the more_trbs_coming field of queue_trb() in isoc transfer.
      Signed-off-by: NAndiry Xu <andiry.xu@amd.com>
      Signed-off-by: NSarah Sharp <sarah.a.sharp@linux.intel.com>
      47cbf692
    • S
      xhci: Use GFP_NOIO during device reset. · a6d940dd
      Sarah Sharp 提交于
      When xhci_discover_or_reset_device() is called after a host controller
      power loss, the virtual device may need to be reallocated.  Make sure
      xhci_alloc_dev() uses GFP_NOIO.  This avoid causing a deadlock by allowing
      the kernel to flush pending I/O while reallocating memory for a virtual
      device for a USB mass storage device that's holding the backing store for
      dirty memory buffers.
      
      This patch should be queued for the 2.6.37 stable tree.
      Signed-off-by: NSarah Sharp <sarah.a.sharp@linux.intel.com>
      Cc: stable@kernel.org
      a6d940dd
    • Z
      xhci: Do not run xhci_cleanup_msix with irq disabled · 40a9fb17
      Zhang Rui 提交于
      when unloading xhci_hcd, I got:
      [  134.856813] xhci_hcd 0000:02:00.0: remove, state 4
      [  134.858140] usb usb3: USB disconnect, address 1
      [  134.874956] xhci_hcd 0000:02:00.0: Host controller not halted, aborting reset.
      [  134.876351] BUG: sleeping function called from invalid context at kernel/mutex.c:85
      [  134.877657] in_atomic(): 0, irqs_disabled(): 1, pid: 1451, name: modprobe
      [  134.878975] Pid: 1451, comm: modprobe Not tainted 2.6.37-rc5+ #162
      [  134.880298] Call Trace:
      [  134.881602]  [<ffffffff8104156a>] __might_sleep+0xeb/0xf0
      [  134.882921]  [<ffffffff814763dc>] mutex_lock+0x24/0x50
      [  134.884229]  [<ffffffff810a745c>] free_desc+0x2e/0x5f
      [  134.885538]  [<ffffffff810a74c8>] irq_free_descs+0x3b/0x71
      [  134.886853]  [<ffffffff8102584d>] free_irq_at+0x31/0x36
      [  134.888167]  [<ffffffff8102723f>] destroy_irq+0x69/0x71
      [  134.889486]  [<ffffffff8102747a>] native_teardown_msi_irq+0xe/0x10
      [  134.890820]  [<ffffffff8124c382>] default_teardown_msi_irqs+0x57/0x80
      [  134.892158]  [<ffffffff8124be46>] free_msi_irqs+0x8b/0xe9
      [  134.893504]  [<ffffffff8124cd46>] pci_disable_msix+0x35/0x39
      [  134.894844]  [<ffffffffa01b444a>] xhci_cleanup_msix+0x31/0x51 [xhci_hcd]
      [  134.896186]  [<ffffffffa01b4b3a>] xhci_stop+0x3a/0x80 [xhci_hcd]
      [  134.897521]  [<ffffffff81341dd4>] usb_remove_hcd+0xfd/0x14a
      [  134.898859]  [<ffffffff813500ae>] usb_hcd_pci_remove+0x5c/0xc6
      [  134.900193]  [<ffffffff8123c606>] pci_device_remove+0x3f/0x91
      [  134.901535]  [<ffffffff812e7ea4>] __device_release_driver+0x83/0xd9
      [  134.902899]  [<ffffffff812e8571>] driver_detach+0x86/0xad
      [  134.904222]  [<ffffffff812e7d56>] bus_remove_driver+0xb2/0xd8
      [  134.905540]  [<ffffffff812e8633>] driver_unregister+0x6c/0x74
      [  134.906839]  [<ffffffff8123c8e4>] pci_unregister_driver+0x44/0x89
      [  134.908121]  [<ffffffffa01b940e>] xhci_unregister_pci+0x15/0x17 [xhci_hcd]
      [  134.909396]  [<ffffffffa01bd7d2>] xhci_hcd_cleanup+0xe/0x10 [xhci_hcd]
      [  134.910652]  [<ffffffff8107fcd1>] sys_delete_module+0x1ca/0x23b
      [  134.911882]  [<ffffffff81123932>] ? path_put+0x22/0x26
      [  134.913104]  [<ffffffff8109a800>] ? audit_syscall_entry+0x2c/0x148
      [  134.914333]  [<ffffffff8100ac82>] system_call_fastpath+0x16/0x1b
      [  134.915658] xhci_hcd 0000:02:00.0: USB bus 3 deregistered
      [  134.916465] xhci_hcd 0000:02:00.0: PCI INT A disabled
      
      and the same issue when xhci_suspend is invoked.  (Note from Sarah: That's
      fixed by Andiry's patch before this, by synchronizing the irqs rather than
      freeing them on suspend.)
      
      Do not run xhci_cleanup_msix with irq disabled.
      
      This patch should be queued for the 2.6.37 stable tree.
      Signed-off-by: NZhang Rui <rui.zhang@intel.com>
      Signed-off-by: NSarah Sharp <sarah.a.sharp@linux.intel.com>
      Cc: stable@kernel.org
      40a9fb17