<feed xmlns='http://www.w3.org/2005/Atom'>
<title>talos-obmc-linux/drivers/usb, branch dev-4.10</title>
<subtitle>Talos™ II Linux sources for OpenBMC</subtitle>
<id>https://git.raptorcs.com/git/talos-obmc-linux/atom?h=dev-4.10</id>
<link rel='self' href='https://git.raptorcs.com/git/talos-obmc-linux/atom?h=dev-4.10'/>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-obmc-linux/'/>
<updated>2017-06-05T02:24:15+00:00</updated>
<entry>
<title>Merge tag 'v4.10.17' into dev-4.10</title>
<updated>2017-06-05T02:24:15+00:00</updated>
<author>
<name>Joel Stanley</name>
<email>joel@jms.id.au</email>
</author>
<published>2017-06-05T02:24:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-obmc-linux/commit/?id=309678aa4cae5fe45ddfa1cf312625499851b6e1'/>
<id>urn:sha1:309678aa4cae5fe45ddfa1cf312625499851b6e1</id>
<content type='text'>
This is the 4.10.17 stable release
</content>
</entry>
<entry>
<title>usb/uhci: Add support for Aspeed BMC SoCs</title>
<updated>2017-06-01T04:58:07+00:00</updated>
<author>
<name>Benjamin Herrenschmidt</name>
<email>benh@kernel.crashing.org</email>
</author>
<published>2017-05-23T00:44:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-obmc-linux/commit/?id=cd0c3b23ac21178bbfbb2cc5b99cf088e2c62653'/>
<id>urn:sha1:cd0c3b23ac21178bbfbb2cc5b99cf088e2c62653</id>
<content type='text'>
The Aspeed 2400/2500 families have a variant of UHCI which requires
some quirks to the driver to work:

 - The register offsets are different. We add a remapping helper.

 - All accesses have to be done via 32-bit loads and stores. We
   force all accessors to use readl/writel. This is of no consequence
   for reads as we never read "in the middle" of a register. For writes
   it also works fine as the registers only actually implement the bits
   we try to write (16-bit for the registers accessed with writew and
   8-bit for the register accessed with writeb), so always using a
   32-bit write will have no negative effect. We never do partial writes.

 - The resume detect interrupt is broken

 - The number of ports is (optionally) provided via the device-tree

Signed-off-by: Benjamin Herrenschmidt &lt;benh@kernel.crashing.org&gt;
Acked-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
(cherry picked from commit 4642d34a439f80e16af0d56ed6258a33abae257a)
Signed-off-by: Joel Stanley &lt;joel@jms.id.au&gt;
</content>
</entry>
<entry>
<title>usb: hub: Do not attempt to autosuspend disconnected devices</title>
<updated>2017-05-20T12:30:57+00:00</updated>
<author>
<name>Guenter Roeck</name>
<email>linux@roeck-us.net</email>
</author>
<published>2017-03-20T21:30:50+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-obmc-linux/commit/?id=b1a8c141c88ce62d18350ceac7eca02d08ad1960'/>
<id>urn:sha1:b1a8c141c88ce62d18350ceac7eca02d08ad1960</id>
<content type='text'>
commit f5cccf49428447dfbc9edb7a04bb8fc316269781 upstream.

While running a bind/unbind stress test with the dwc3 usb driver on rk3399,
the following crash was observed.

Unable to handle kernel NULL pointer dereference at virtual address 00000218
pgd = ffffffc00165f000
[00000218] *pgd=000000000174f003, *pud=000000000174f003,
				*pmd=0000000001750003, *pte=00e8000001751713
Internal error: Oops: 96000005 [#1] PREEMPT SMP
Modules linked in: uinput uvcvideo videobuf2_vmalloc cmac
ipt_MASQUERADE nf_nat_masquerade_ipv4 iptable_nat nf_nat_ipv4 nf_nat rfcomm
xt_mark fuse bridge stp llc zram btusb btrtl btbcm btintel bluetooth
ip6table_filter mwifiex_pcie mwifiex cfg80211 cdc_ether usbnet r8152 mii joydev
snd_seq_midi snd_seq_midi_event snd_rawmidi snd_seq snd_seq_device ppp_async
ppp_generic slhc tun
CPU: 1 PID: 29814 Comm: kworker/1:1 Not tainted 4.4.52 #507
Hardware name: Google Kevin (DT)
Workqueue: pm pm_runtime_work
task: ffffffc0ac540000 ti: ffffffc0af4d4000 task.ti: ffffffc0af4d4000
PC is at autosuspend_check+0x74/0x174
LR is at autosuspend_check+0x70/0x174
...
Call trace:
[&lt;ffffffc00080dcc0&gt;] autosuspend_check+0x74/0x174
[&lt;ffffffc000810500&gt;] usb_runtime_idle+0x20/0x40
[&lt;ffffffc000785ae0&gt;] __rpm_callback+0x48/0x7c
[&lt;ffffffc000786af0&gt;] rpm_idle+0x1e8/0x498
[&lt;ffffffc000787cdc&gt;] pm_runtime_work+0x88/0xcc
[&lt;ffffffc000249bb8&gt;] process_one_work+0x390/0x6b8
[&lt;ffffffc00024abcc&gt;] worker_thread+0x480/0x610
[&lt;ffffffc000251a80&gt;] kthread+0x164/0x178
[&lt;ffffffc0002045d0&gt;] ret_from_fork+0x10/0x40

Source:

(gdb) l *0xffffffc00080dcc0
0xffffffc00080dcc0 is in autosuspend_check
(drivers/usb/core/driver.c:1778).
1773		/* We don't need to check interfaces that are
1774		 * disabled for runtime PM.  Either they are unbound
1775		 * or else their drivers don't support autosuspend
1776		 * and so they are permanently active.
1777		 */
1778		if (intf-&gt;dev.power.disable_depth)
1779			continue;
1780		if (atomic_read(&amp;intf-&gt;dev.power.usage_count) &gt; 0)
1781			return -EBUSY;
1782		w |= intf-&gt;needs_remote_wakeup;

Code analysis shows that intf is set to NULL in usb_disable_device() prior
to setting actconfig to NULL. At the same time, usb_runtime_idle() does not
lock the usb device, and neither does any of the functions in the
traceback. This means that there is no protection against a race condition
where usb_disable_device() is removing dev-&gt;actconfig-&gt;interface[] pointers
while those are being accessed from autosuspend_check().

To solve the problem, synchronize and validate device state between
autosuspend_check() and usb_disconnect().

Acked-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Signed-off-by: Guenter Roeck &lt;linux@roeck-us.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>usb: hub: Fix error loop seen after hub communication errors</title>
<updated>2017-05-20T12:30:56+00:00</updated>
<author>
<name>Guenter Roeck</name>
<email>linux@roeck-us.net</email>
</author>
<published>2017-03-20T18:16:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-obmc-linux/commit/?id=5830c376e3afad4272e31e2eab87f04333f0ca80'/>
<id>urn:sha1:5830c376e3afad4272e31e2eab87f04333f0ca80</id>
<content type='text'>
commit 245b2eecee2aac6fdc77dcafaa73c33f9644c3c7 upstream.

While stress testing a usb controller using a bind/unbind looop, the
following error loop was observed.

usb 7-1.2: new low-speed USB device number 3 using xhci-hcd
usb 7-1.2: hub failed to enable device, error -108
usb 7-1-port2: cannot disable (err = -22)
usb 7-1-port2: couldn't allocate usb_device
usb 7-1-port2: cannot disable (err = -22)
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
hub 7-1:1.0: activate --&gt; -22
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
hub 7-1:1.0: activate --&gt; -22
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
hub 7-1:1.0: activate --&gt; -22
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
hub 7-1:1.0: activate --&gt; -22
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
hub 7-1:1.0: activate --&gt; -22
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
hub 7-1:1.0: activate --&gt; -22
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
hub 7-1:1.0: activate --&gt; -22
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
hub 7-1:1.0: activate --&gt; -22
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
hub 7-1:1.0: hub_ext_port_status failed (err = -22)
** 57 printk messages dropped ** hub 7-1:1.0: activate --&gt; -22
** 82 printk messages dropped ** hub 7-1:1.0: hub_ext_port_status failed (err = -22)

This continues forever. After adding tracebacks into the code,
the call sequence leading to this is found to be as follows.

[&lt;ffffffc0007fc8e0&gt;] hub_activate+0x368/0x7b8
[&lt;ffffffc0007fceb4&gt;] hub_resume+0x2c/0x3c
[&lt;ffffffc00080b3b8&gt;] usb_resume_interface.isra.6+0x128/0x158
[&lt;ffffffc00080b5d0&gt;] usb_suspend_both+0x1e8/0x288
[&lt;ffffffc00080c9c4&gt;] usb_runtime_suspend+0x3c/0x98
[&lt;ffffffc0007820a0&gt;] __rpm_callback+0x48/0x7c
[&lt;ffffffc00078217c&gt;] rpm_callback+0xa8/0xd4
[&lt;ffffffc000786234&gt;] rpm_suspend+0x84/0x758
[&lt;ffffffc000786ca4&gt;] rpm_idle+0x2c8/0x498
[&lt;ffffffc000786ed4&gt;] __pm_runtime_idle+0x60/0xac
[&lt;ffffffc00080eba8&gt;] usb_autopm_put_interface+0x6c/0x7c
[&lt;ffffffc000803798&gt;] hub_event+0x10ac/0x12ac
[&lt;ffffffc000249bb8&gt;] process_one_work+0x390/0x6b8
[&lt;ffffffc00024abcc&gt;] worker_thread+0x480/0x610
[&lt;ffffffc000251a80&gt;] kthread+0x164/0x178
[&lt;ffffffc0002045d0&gt;] ret_from_fork+0x10/0x40

kick_hub_wq() is called from hub_activate() even after failures to
communicate with the hub. This results in an endless sequence of
hub event -&gt; hub activate -&gt; wq trigger -&gt; hub event -&gt; ...

Provide two solutions for the problem.

- Only trigger the hub event queue if communication with the hub
  is successful.
- After a suspend failure, only resume already suspended interfaces
  if the communication with the device is still possible.

Each of the changes fixes the observed problem. Use both to improve
robustness.

Acked-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Signed-off-by: Guenter Roeck &lt;linux@roeck-us.net&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>usb: gadget: legacy gadgets are optional</title>
<updated>2017-05-20T12:30:56+00:00</updated>
<author>
<name>Romain Izard</name>
<email>romain.izard.pro@gmail.com</email>
</author>
<published>2017-03-10T13:11:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-obmc-linux/commit/?id=934c4e338e7e47ea5dd0d642a1615f7d0e42c70a'/>
<id>urn:sha1:934c4e338e7e47ea5dd0d642a1615f7d0e42c70a</id>
<content type='text'>
commit 6e253d0fbc665b36192b8ed3cecdbb65b413a1eb upstream.

With commit bc49d1d17dcf ("usb: gadget: don't couple configfs to legacy
gadgets"),it is possible to build a modular kernel with both built-in
configfs support and modular legacy gadget drivers.

But when building a kernel without modules, it is also necessary to be
able to build with configfs but without any legacy gadget driver. This
was a possible configuration when the USB_CONFIGFS was a part of the
choice options, but not anymore.

Mark the choice for legacy gadget drivers as optional restores this.

Fixes: bc49d1d17dcf ("usb: gadget: don't couple configfs to legacy gadgets")
Signed-off-by: Romain Izard &lt;romain.izard.pro@gmail.com&gt;
Signed-off-by: Felipe Balbi &lt;felipe.balbi@linux.intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>usb: misc: add missing continue in switch</title>
<updated>2017-05-20T12:30:56+00:00</updated>
<author>
<name>Gustavo A. R. Silva</name>
<email>garsilva@embeddedor.com</email>
</author>
<published>2017-04-04T03:48:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-obmc-linux/commit/?id=7f7a4b58e257123573c9dd488ac7fea0f7a01df1'/>
<id>urn:sha1:7f7a4b58e257123573c9dd488ac7fea0f7a01df1</id>
<content type='text'>
commit 2c930e3d0aed1505e86e0928d323df5027817740 upstream.

Add missing continue in switch.

Addresses-Coverity-ID: 1248733
Signed-off-by: Gustavo A. R. Silva &lt;garsilva@embeddedor.com&gt;
Acked-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>USB: Revert "cdc-wdm: fix "out-of-sync" due to missing notifications"</title>
<updated>2017-05-20T12:30:55+00:00</updated>
<author>
<name>Bjørn Mork</name>
<email>bjorn@mork.no</email>
</author>
<published>2017-04-21T08:01:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-obmc-linux/commit/?id=5b92090a53eb584276454588e81db105dcf07954'/>
<id>urn:sha1:5b92090a53eb584276454588e81db105dcf07954</id>
<content type='text'>
commit 19445816996d1a89682c37685fe95959631d9f32 upstream.

This reverts commit 833415a3e781 ("cdc-wdm: fix "out-of-sync" due to
missing notifications")

There have been several reports of wdm_read returning unexpected EIO
errors with QMI devices using the qmi_wwan driver. The reporters
confirm that reverting prevents these errors. I have been unable to
reproduce the bug myself, and have no explanation to offer either. But
reverting is the safe choice here, given that the commit was an
attempt to work around a firmware problem.  Living with a firmware
problem is still better than adding driver bugs.

Reported-by: Kasper Holtze &lt;kasper@holtze.dk&gt;
Reported-by: Aleksander Morgado &lt;aleksander@aleksander.es&gt;
Reported-by: Daniele Palmas &lt;dnlplm@gmail.com&gt;
Fixes: 833415a3e781 ("cdc-wdm: fix "out-of-sync" due to missing notifications")
Signed-off-by: Bjørn Mork &lt;bjorn@mork.no&gt;
Acked-by: Oliver Neukum &lt;oneukum@suse.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>USB: Proper handling of Race Condition when two USB class drivers try to call init_usb_class simultaneously</title>
<updated>2017-05-20T12:30:55+00:00</updated>
<author>
<name>Ajay Kaher</name>
<email>ajay.kaher@samsung.com</email>
</author>
<published>2017-03-28T12:09:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-obmc-linux/commit/?id=32dd9987fbd9a0f1a80484146aeafdb7f3b88e49'/>
<id>urn:sha1:32dd9987fbd9a0f1a80484146aeafdb7f3b88e49</id>
<content type='text'>
commit 2f86a96be0ccb1302b7eee7855dbee5ce4dc5dfb upstream.

There is race condition when two USB class drivers try to call
init_usb_class at the same time and leads to crash.
code path: probe-&gt;usb_register_dev-&gt;init_usb_class

To solve this, mutex locking has been added in init_usb_class() and
destroy_usb_class().

As pointed by Alan, removed "if (usb_class)" test from destroy_usb_class()
because usb_class can never be NULL there.

Signed-off-by: Ajay Kaher &lt;ajay.kaher@samsung.com&gt;
Acked-by: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>USB: serial: ftdi_sio: add device ID for Microsemi/Arrow SF2PLUS Dev Kit</title>
<updated>2017-05-20T12:30:55+00:00</updated>
<author>
<name>Marek Vasut</name>
<email>marex@denx.de</email>
</author>
<published>2017-04-18T18:07:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-obmc-linux/commit/?id=e349a57233228a8f479fa833a3606312ac830610'/>
<id>urn:sha1:e349a57233228a8f479fa833a3606312ac830610</id>
<content type='text'>
commit 31c5d1922b90ddc1da6a6ddecef7cd31f17aa32b upstream.

This development kit has an FT4232 on it with a custom USB VID/PID.
The FT4232 provides four UARTs, but only two are used. The UART 0
is used by the FlashPro5 programmer and UART 2 is connected to the
SmartFusion2 CortexM3 SoC UART port.

Note that the USB VID is registered to Actel according to Linux USB
VID database, but that was acquired by Microsemi.

Signed-off-by: Marek Vasut &lt;marex@denx.de&gt;
Signed-off-by: Johan Hovold &lt;johan@kernel.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>usb: host: xhci: print correct command ring address</title>
<updated>2017-05-20T12:30:55+00:00</updated>
<author>
<name>Peter Chen</name>
<email>peter.chen@nxp.com</email>
</author>
<published>2017-04-19T13:55:52+00:00</published>
<link rel='alternate' type='text/html' href='https://git.raptorcs.com/git/talos-obmc-linux/commit/?id=dffe5d4b0511cada0e8a833b1e3297df65e4eadb'/>
<id>urn:sha1:dffe5d4b0511cada0e8a833b1e3297df65e4eadb</id>
<content type='text'>
commit 6fc091fb0459ade939a795bfdcaf645385b951d4 upstream.

Print correct command ring address using 'val_64'.

Signed-off-by: Peter Chen &lt;peter.chen@nxp.com&gt;
Signed-off-by: Mathias Nyman &lt;mathias.nyman@linux.intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

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