1. 19 5月, 2012 2 次提交
    • S
      xhci: Reset reserved command ring TRBs on cleanup. · 33b2831a
      Sarah Sharp 提交于
      When the xHCI driver needs to clean up memory (perhaps due to a failed
      register restore on resume from S3 or resume from S4), it needs to reset
      the number of reserved TRBs on the command ring to zero.  Otherwise,
      several resume cycles (about 30) with a UAS device attached will
      continually increment the number of reserved TRBs, until all command
      submissions fail because there isn't enough room on the command ring.
      
      This patch should be backported to kernels as old as 2.6.32,
      that contain the commit 913a8a34
      "USB: xhci: Change how xHCI commands are handled."
      Signed-off-by: NSarah Sharp <sarah.a.sharp@linux.intel.com>
      Cc: stable@vger.kernel.org
      33b2831a
    • O
      USB: fix resource leak in xhci power loss path · f8a9e72d
      Oliver Neukum 提交于
      Some more data structures must be freed and counters
      reset if an XHCI controller has lost power. The failure
      to do so renders some chips inoperative after a certain number
      of S4 cycles.
      
      This patch should be backported to kernels as old as 3.2,
      that contain the commits c29eea62
      "xhci: Implement HS/FS/LS bandwidth checking." and
      commit 839c817c
      "xhci: Implement HS/FS/LS bandwidth checking."
      Signed-off-by: NOliver Neukum <oneukum@suse.de>
      Signed-off-by: NSarah Sharp <sarah.a.sharp@linux.intel.com>
      Cc: stable@vger.kernel.org
      f8a9e72d
  2. 18 5月, 2012 1 次提交
    • S
      xhci: Add new short TX quirk for Fresco Logic host. · 1530bbc6
      Sarah Sharp 提交于
      Sergio reported that when he recorded audio from a USB headset mic
      plugged into the USB 3.0 port on his ASUS N53SV-DH72, the audio sounded
      "robotic".  When plugged into the USB 2.0 port under EHCI on the same
      laptop, the audio sounded fine.  The device is:
      
      Bus 002 Device 004: ID 046d:0a0c Logitech, Inc. Clear Chat Comfort USB Headset
      
      The problem was tracked down to the Fresco Logic xHCI host controller
      not correctly reporting short transfers on isochronous IN endpoints.
      The driver would submit a 96 byte transfer, the device would only send
      88 or 90 bytes, and the xHCI host would report the transfer had a
      "successful" completion code, with an untransferred buffer length of 8
      or 6 bytes.
      
      The successful completion code and non-zero untransferred length is a
      contradiction.  The xHCI host is supposed to only mark a transfer as
      successful if all the bytes are transferred.  Otherwise, the transfer
      should be marked with a short packet completion code.  Without the EHCI
      bus trace, we wouldn't know whether the xHCI driver should trust the
      completion code or the untransferred length.  With it, we know to trust
      the untransferred length.
      
      Add a new xHCI quirk for the Fresco Logic host controller.  If a
      transfer is reported as successful, but the untransferred length is
      non-zero, print a warning.  For the Fresco Logic host, change the
      completion code to COMP_SHORT_TX and process the transfer like a short
      transfer.
      
      This should be backported to stable kernels that contain the commit
      f5182b41 "xhci: Disable MSI for some
      Fresco Logic hosts."  That commit was marked for stable kernels as old
      as 2.6.36.
      Signed-off-by: NSarah Sharp <sarah.a.sharp@linux.intel.com>
      Reported-by: NSergio Correia <lists@uece.net>
      Tested-by: NSergio Correia <lists@uece.net>
      Cc: stable@vger.kernel.org
      Signed-off-by: NSarah Sharp <sarah.a.sharp@linux.intel.com>
      1530bbc6
  3. 15 5月, 2012 4 次提交
  4. 14 5月, 2012 2 次提交
  5. 12 5月, 2012 3 次提交
  6. 10 5月, 2012 3 次提交
  7. 09 5月, 2012 1 次提交
  8. 08 5月, 2012 2 次提交
  9. 05 5月, 2012 1 次提交
  10. 04 5月, 2012 4 次提交
    • S
      xhci: Add Lynx Point to list of Intel switchable hosts. · 1c12443a
      Sarah Sharp 提交于
      The upcoming Intel Lynx Point chipset includes an xHCI host controller
      that can have ports switched from the EHCI host controller, just like
      the Intel Panther Point xHCI host.  This time, ports from both EHCI
      hosts can be switched to the xHCI host controller.  The PCI config
      registers to do the port switching are in the exact same place in the
      xHCI PCI configuration registers, with the same semantics.
      
      Hooray for shipping patches for next-gen hardware before the current gen
      hardware is even available for purchase!
      
      This patch should be backported to stable kernels as old as 3.0,
      that contain commit 69e848c2
      "Intel xhci: Support EHCI/xHCI port switching."
      Signed-off-by: NSarah Sharp <sarah.a.sharp@linux.intel.com>
      Cc: stable@vger.kernel.org
      1c12443a
    • S
      xhci: Avoid dead ports when CONFIG_USB_XHCI_HCD=n · 51c9e6c7
      Sarah Sharp 提交于
      If the user chooses to say "no" to CONFIG_USB_XHCI_HCD on a system
      with an Intel Panther Point chipset, the PCI quirks code or the EHCI
      driver will switch the ports over to the xHCI host, but the xHCI driver
      will never load.  The ports will be powered off and seem "dead" to the
      user.
      
      Fix this by only switching the ports over if CONFIG_USB_XHCI_HCD is
      either compiled in, or compiled as a module.
      
      This patch should be backported to stable kernels as old as 3.0,
      that contain commit 69e848c2
      "Intel xhci: Support EHCI/xHCI port switching."
      Signed-off-by: NSarah Sharp <sarah.a.sharp@linux.intel.com>
      Reported-by: NEric Anholt <eric.anholt@intel.com>
      Reported-by: NDavid Bein <d.bein@f5.com>
      Cc: stable@vger.kernel.org
      51c9e6c7
    • H
      usb-xhci: Handle COMP_TX_ERR for isoc tds · 9c745995
      Hans de Goede 提交于
      While testing unplugging an UVC HD webcam with usb-redirection (so through
      usbdevfs), my userspace usb-redir code was getting a value of -1 in
      iso_frame_desc[n].status, which according to Documentation/usb/error-codes.txt
      is not a valid value.
      
      The source of this -1 is the default case in xhci-ring.c:process_isoc_td()
      adding a kprintf there showed the value of trb_comp_code to be COMP_TX_ERR
      in this case, so this patch adds handling for that completion code to
      process_isoc_td().
      
      This was observed and tested with the following xhci controller:
      1033:0194 NEC Corporation uPD720200 USB 3.0 Host Controller (rev 04)
      
      Note: I also wonder if setting frame->status to -1 (-EPERM) is the best we can
      do, but since I cannot come up with anything better I've left that as is.
      
      This patch should be backported to kernels as old as 2.6.36, which contain the
      commit 04e51901 "USB: xHCI: Isochronous
      transfer implementation".
      Signed-off-by: NHans de Goede <hdegoede@redhat.com>
      Signed-off-by: NSarah Sharp <sarah.a.sharp@linux.intel.com>
      Cc: stable@vger.kernel.org
      9c745995
    • A
      xHCI: keep track of ports being resumed and indicate in hub_status_data · f370b996
      Andiry Xu 提交于
      This commit adds a bit-array to xhci bus_state for keeping track of
      which ports are undergoing a resume transition. If any of the bits
      are set when xhci_hub_status_data() is called, the routine will return
      a non-zero value even if no ports have any status changes pending.
      This will allow usbcore to handle races between root-hub suspend and
      port wakeup.
      
      This patch should be backported to kernels as old as 3.4, that contain
      the commit 879d38e6 "USB: fix race
      between root-hub suspend and remote wakeup".
      Signed-off-by: NAndiry Xu <andiry.xu@amd.com>
      Signed-off-by: NSarah Sharp <sarah.a.sharp@linux.intel.com>
      Cc: Alan Stern <stern@rowland.harvard.edu>
      Cc: stable@vger.kernel.org
      f370b996
  11. 02 5月, 2012 15 次提交
  12. 28 4月, 2012 2 次提交