<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/usb/core, branch v3.4.96</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/drivers/usb/core?h=v3.4.96</id>
<link rel='self' href='https://git.amat.us/linux/atom/drivers/usb/core?h=v3.4.96'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2014-06-11T19:04:13Z</updated>
<entry>
<title>USB: Avoid runtime suspend loops for HCDs that can't handle suspend/resume</title>
<updated>2014-06-11T19:04:13Z</updated>
<author>
<name>Alan Stern</name>
<email>stern@rowland.harvard.edu</email>
</author>
<published>2014-05-23T14:45:54Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=7da536df5fb077e03b8882b586f274409c459861'/>
<id>urn:sha1:7da536df5fb077e03b8882b586f274409c459861</id>
<content type='text'>
commit 8ef42ddd9a53b73e6fc3934278710c27f80f324f upstream.

Not all host controller drivers have bus-suspend and bus-resume
methods.  When one doesn't, it will cause problems if runtime PM is
enabled in the kernel.  The PM core will attempt to suspend the
controller's root hub, the suspend will fail because there is no
bus-suspend routine, and a -EBUSY error code will be returned to the
PM core.  This will cause the suspend attempt to be repeated shortly
thereafter, in a never-ending loop.

Part of the problem is that the original error code -ENOENT gets
changed to -EBUSY in usb_runtime_suspend(), on the grounds that the PM
core will interpret -ENOENT as meaning that the root hub has gotten
into a runtime-PM error state.  While this change is appropriate for
real USB devices, it's not such a good idea for a root hub.  In fact,
considering the root hub to be in a runtime-PM error state would not
be far from the truth.  Therefore this patch updates
usb_runtime_suspend() so that it adjusts error codes only for
non-root-hub devices.

Furthermore, the patch attempts to prevent the problem from occurring
in the first place by not enabling runtime PM by default for root hubs
whose host controller driver doesn't have bus_suspend and bus_resume
methods.

Signed-off-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Reported-by: Will Deacon &lt;will.deacon@arm.com&gt;
Tested-by: Will Deacon &lt;will.deacon@arm.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>USB: unbind all interfaces before rebinding any</title>
<updated>2014-05-06T14:51:45Z</updated>
<author>
<name>Alan Stern</name>
<email>stern@rowland.harvard.edu</email>
</author>
<published>2014-03-12T15:30:38Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=d6f6fc7a2bc99124058b7c4850a9997530589a33'/>
<id>urn:sha1:d6f6fc7a2bc99124058b7c4850a9997530589a33</id>
<content type='text'>
commit 6aec044cc2f5670cf3b143c151c8be846499bd15 upstream.

When a driver doesn't have pre_reset, post_reset, or reset_resume
methods, the USB core unbinds that driver when its device undergoes a
reset or a reset-resume, and then rebinds it afterward.

The existing straightforward implementation can lead to problems,
because each interface gets unbound and rebound before the next
interface is handled.  If a driver claims additional interfaces, the
claim may fail because the old binding instance may still own the
additional interface when the new instance tries to claim it.

This patch fixes the problem by first unbinding all the interfaces
that are marked (i.e., their needs_binding flag is set) and then
rebinding all of them.

The patch also makes the helper functions in driver.c a little more
uniform and adjusts some out-of-date comments.

Signed-off-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Reported-and-tested-by: "Poulain, Loic" &lt;loic.poulain@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>USB: fix crash during hotplug of PCI USB controller card</title>
<updated>2014-05-06T14:51:42Z</updated>
<author>
<name>Alan Stern</name>
<email>stern@rowland.harvard.edu</email>
</author>
<published>2014-04-14T17:48:47Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=5d052fbbd7b0069df1fdeaa7dd5eb16e1345a458'/>
<id>urn:sha1:5d052fbbd7b0069df1fdeaa7dd5eb16e1345a458</id>
<content type='text'>
commit a2ff864b53eac9a0e9b05bfe9d1781ccd6c2af71 upstream.

The code in hcd-pci.c that matches up EHCI controllers with their
companion UHCI or OHCI controllers assumes that the private drvdata
fields don't get set too early.  However, it turns out that this field
gets set by usb_create_hcd(), before hcd-pci expects it, and this can
result in a crash when two controllers are probed in parallel (as can
happen when a new controller card is hotplugged).

The companions_rwsem lock was supposed to prevent this sort of thing,
but usb_create_hcd() is called outside the scope of the rwsem.

A simple solution is to check that the root-hub pointer has been
initialized as well as the drvdata field.  This doesn't happen until
usb_add_hcd() is called; that call and the check are both protected by
the rwsem.

This patch should be applied to stable kernels from 3.10 onward.

Signed-off-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Reported-by: Stefani Seibold &lt;stefani@seibold.net&gt;
Tested-by: Stefani Seibold &lt;stefani@seibold.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>usb: hub: Clear Port Reset Change during init/resume</title>
<updated>2014-04-14T13:44:29Z</updated>
<author>
<name>Julius Werner</name>
<email>jwerner@chromium.org</email>
</author>
<published>2013-10-16T00:45:00Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=da02a12066a280b546c71a492f47a7776e2b1d10'/>
<id>urn:sha1:da02a12066a280b546c71a492f47a7776e2b1d10</id>
<content type='text'>
commit e92aee330837e4911553761490a8fb843f2053a6 upstream.

This patch adds the Port Reset Change flag to the set of bits that are
preemptively cleared on init/resume of a hub. In theory this bit should
never be set unexpectedly... in practice it can still happen if BIOS,
SMM or ACPI code plays around with USB devices without cleaning up
correctly. This is especially dangerous for XHCI root hubs, which don't
generate any more Port Status Change Events until all change bits are
cleared, so this is a good precaution to have (similar to how it's
already done for the Warm Port Reset Change flag).

Signed-off-by: Julius Werner &lt;jwerner@chromium.org&gt;
Acked-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
[bwh: Backported to 3.2:
 - Adjust context
 - s/usb_clear_port_feature/clear_port_feature/]
Signed-off-by: Ben Hutchings &lt;ben@decadent.org.uk&gt;
[yangyl: Backported to 3.4: Adjust context]
Signed-off-by: Yang Yingliang &lt;yangyingliang@huawei.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>usb: Disable USB 2.0 Link PM before device reset.</title>
<updated>2014-04-14T13:44:27Z</updated>
<author>
<name>Sarah Sharp</name>
<email>sarah.a.sharp@linux.intel.com</email>
</author>
<published>2013-09-30T14:26:29Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=9e5f97bb07a4048d388d81e8c26b2e6d15973bf3'/>
<id>urn:sha1:9e5f97bb07a4048d388d81e8c26b2e6d15973bf3</id>
<content type='text'>
commit dcc01c0864823f91c3bf3ffca6613e2351702b87 upstream.

Before the USB core resets a device, we need to disable the L1 timeout
for the roothub, if USB 2.0 Link PM is enabled.  Otherwise the port may
transition into L1 in between descriptor fetches, before we know if the
USB device descriptors changed.  LPM will be re-enabled after the
full device descriptors are fetched, and we can confirm the device still
supports USB 2.0 LPM after the reset.

We don't need to wait for the USB device to exit L1 before resetting the
device, since the xHCI roothub port diagrams show a transition to the
Reset state from any of the Ux states (see Figure 34 in the 2012-08-14
xHCI specification update).

This patch should be backported to kernels as old as 3.2, that contain
the commit 65580b4321eb36f16ae8b5987bfa1bb948fc5112 "xHCI: set USB2
hardware LPM".  That was the first commit to enable USB 2.0
hardware-driven Link Power Management.

Signed-off-by: Sarah Sharp &lt;sarah.a.sharp@linux.intel.com&gt;
[bwh: Backported to 3.2: adjust context]
Signed-off-by: Ben Hutchings &lt;ben@decadent.org.uk&gt;
Cc: Yang Yingliang &lt;yangyingliang@huawei.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>usb: Add USB_QUIRK_RESET_RESUME for all Logitech UVC webcams</title>
<updated>2014-04-14T13:44:22Z</updated>
<author>
<name>Laurent Pinchart</name>
<email>laurent.pinchart@ideasonboard.com</email>
</author>
<published>2012-07-19T10:39:14Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=8cb6708d75c2999d99d245dc6a42375ae602f8ce'/>
<id>urn:sha1:8cb6708d75c2999d99d245dc6a42375ae602f8ce</id>
<content type='text'>
commit e387ef5c47ddeaeaa3cbdc54424cdb7a28dae2c0 upstream.

Most Logitech UVC webcams (both early models that don't advertise UVC
compatibility and newer UVC-advertised devices) require the RESET_RESUME
quirk. Instead of listing each and every model, match the devices based
on the UVC interface information.

Signed-off-by: Laurent Pinchart &lt;laurent.pinchart@ideasonboard.com&gt;
Acked-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
[bwh: Adjust context to apply after 3.2.38]
Signed-off-by: Ben Hutchings &lt;ben@decadent.org.uk&gt;
Cc: Yang Yingliang &lt;yangyingliang@huawei.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>usb: Add quirk detection based on interface information</title>
<updated>2014-04-14T13:44:22Z</updated>
<author>
<name>Laurent Pinchart</name>
<email>laurent.pinchart@ideasonboard.com</email>
</author>
<published>2012-07-19T10:39:13Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=a85e474e00d762b1a20d912c003daa64c42cc74e'/>
<id>urn:sha1:a85e474e00d762b1a20d912c003daa64c42cc74e</id>
<content type='text'>
commit 80da2e0df5af700518611b7d1cc4fc9945bcaf95 upstream.

When a whole class of devices (possibly from a specific vendor, or
across multiple vendors) require a quirk, explictly listing all devices
in the class make the quirks table unnecessarily large. Fix this by
allowing matching devices based on interface information.

Signed-off-by: Laurent Pinchart &lt;laurent.pinchart@ideasonboard.com&gt;
Acked-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Signed-off-by: Ben Hutchings &lt;ben@decadent.org.uk&gt;
Cc: Yang Yingliang &lt;yangyingliang@huawei.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>USB: Add device quirk for Microsoft VX700 webcam</title>
<updated>2014-04-14T13:44:22Z</updated>
<author>
<name>Andreas Fleig</name>
<email>andreasfleig@gmail.com</email>
</author>
<published>2012-12-05T15:17:49Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=96ff7eff36f9f756726dbde657b020cd4469de8d'/>
<id>urn:sha1:96ff7eff36f9f756726dbde657b020cd4469de8d</id>
<content type='text'>
commit bc009eca8d539162f7271c2daf0ab5e9e3bb90a0 upstream.

Add device quirk for Microsoft Lifecam VX700 v2.0 webcams.
Fixes squeaking noise of the microphone.

Signed-off-by: Andreas Fleig &lt;andreasfleig@gmail.com&gt;
[bwh: Backported to 3.2: adjust context]
Signed-off-by: Ben Hutchings &lt;ben@decadent.org.uk&gt;
Cc: Yang Yingliang &lt;yangyingliang@huawei.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>usb: core: get config and string descriptors for unauthorized devices</title>
<updated>2014-02-06T19:05:48Z</updated>
<author>
<name>Thomas Pugliese</name>
<email>thomas.pugliese@gmail.com</email>
</author>
<published>2013-12-09T19:40:29Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=7af4a2da7aaca5f5a0e97fec4050cd8a3c59ebcd'/>
<id>urn:sha1:7af4a2da7aaca5f5a0e97fec4050cd8a3c59ebcd</id>
<content type='text'>
commit 83e83ecb79a8225e79bc8e54e9aff3e0e27658a2 upstream.

There is no need to skip querying the config and string descriptors for
unauthorized WUSB devices when usb_new_device is called.  It is allowed
by WUSB spec.  The only action that needs to be delayed until
authorization time is the set config.  This change allows user mode
tools to see the config and string descriptors earlier in enumeration
which is needed for some WUSB devices to function properly on Android
systems.  It also reduces the amount of divergent code paths needed
for WUSB devices.

Signed-off-by: Thomas Pugliese &lt;thomas.pugliese@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>usb: hub: Use correct reset for wedged USB3 devices that are NOTATTACHED</title>
<updated>2013-12-20T15:34:19Z</updated>
<author>
<name>Julius Werner</name>
<email>jwerner@chromium.org</email>
</author>
<published>2013-11-07T18:59:14Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=325be9564c80026b3ca6c1025e2fbb074bdd27a2'/>
<id>urn:sha1:325be9564c80026b3ca6c1025e2fbb074bdd27a2</id>
<content type='text'>
commit 2d51f3cd11f414c56a87dc018196b85fd50b04a4 upstream.

This patch adds a check for USB_STATE_NOTATTACHED to the
hub_port_warm_reset_required() workaround for ports that end up in
Compliance Mode in hub_events() when trying to decide which reset
function to use. Trying to call usb_reset_device() with a NOTATTACHED
device will just fail and leave the port broken.

Signed-off-by: Julius Werner &lt;jwerner@chromium.org&gt;
Acked-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
</feed>
