<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/net/usb, branch v4.3</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v4.3</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v4.3'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2015-10-22T14:56:21Z</updated>
<entry>
<title>qmi_wwan: add Sierra Wireless MC74xx/EM74xx</title>
<updated>2015-10-22T14:56:21Z</updated>
<author>
<name>Bjørn Mork</name>
<email>bjorn@mork.no</email>
</author>
<published>2015-10-22T12:15:58Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=0db65fcfcded76fe4f74e3ca9f4e2baf67b683ef'/>
<id>urn:sha1:0db65fcfcded76fe4f74e3ca9f4e2baf67b683ef</id>
<content type='text'>
New device IDs shamelessly lifted from the vendor driver.

Signed-off-by: Bjørn Mork &lt;bjorn@mork.no&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: asix: add support for the Billionton GUSB2AM-1G-B USB adapter</title>
<updated>2015-10-19T02:36:04Z</updated>
<author>
<name>Chia-Sheng Chang</name>
<email>changchias@gmail.com</email>
</author>
<published>2015-10-15T18:00:21Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=80083a3c02ef4451edeef31a6f9afe130078f2bf'/>
<id>urn:sha1:80083a3c02ef4451edeef31a6f9afe130078f2bf</id>
<content type='text'>
Just another AX88178-based 10/100/1000 USB-to-Ethernet dongle. This one
shows up in lsusb as: "ID 08dd:0114 Billionton Systems, Inc".

Signed-off-by: Chia-Sheng Chang &lt;changchias@gmail.com&gt;
Cc: "David S. Miller" &lt;davem@davemloft.net&gt;
Cc: Luca Ceresoli &lt;luca@lucaceresoli.net&gt;
Cc: Christoph Jaeger &lt;cj@linux.com&gt;
Cc: "Woojung.Huh@microchip.com" &lt;Woojung.Huh@microchip.com&gt;
Cc: Matthew Garrett &lt;mjg59@srcf.ucam.org&gt;
Cc: Markus Elfring &lt;elfring@users.sourceforge.net&gt;
Cc: Charles Keepax &lt;ckeepax@opensource.wolfsonmicro.com&gt;
Cc: netdev@vger.kernel.org
Cc: linux-usb@vger.kernel.org
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: usb: asix: Fix crash on skb alloc failure</title>
<updated>2015-10-05T10:31:27Z</updated>
<author>
<name>David B. Robins</name>
<email>linux@davidrobins.net</email>
</author>
<published>2015-09-30T20:20:04Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=f6194bcf03e40bc6b6094f11289d87b605fb326d'/>
<id>urn:sha1:f6194bcf03e40bc6b6094f11289d87b605fb326d</id>
<content type='text'>
If asix_rx_fixup_internal() fails to allocate rx-&gt;ax_skb, it will return
but not clear rx-&gt;size. rx points to driver private data. A later call
assumes that nonzero size means ax_skb was allocated and passes a null
ax_skb to skb_put. Changed allocation failure return to clear size first.

Found testing board with AX88772B devices.

Signed-off-by: David B. Robins &lt;linux@davidrobins.net&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>ch9200: Convert to use module_usb_driver</title>
<updated>2015-09-23T00:34:57Z</updated>
<author>
<name>Tobias Klauser</name>
<email>tklauser@distanz.ch</email>
</author>
<published>2015-09-22T07:29:49Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=23eedbc2435ddd226717603c4f3c8efec7bdbb4d'/>
<id>urn:sha1:23eedbc2435ddd226717603c4f3c8efec7bdbb4d</id>
<content type='text'>
Converts the ch9200 driver to use the module_usb_driver() macro which
makes the code smaller and a bit simpler.

Signed-off-by: Tobias Klauser &lt;tklauser@distanz.ch&gt;
Acked-by: Matthew Garrett &lt;mjg59@srcf.ucam.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>usbnet: New driver for QinHeng CH9200 devices</title>
<updated>2015-09-21T23:16:16Z</updated>
<author>
<name>Matthew Garrett</name>
<email>mjg59@srcf.ucam.org</email>
</author>
<published>2015-09-20T09:25:38Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=4a476bd6d1d923922ec950ddc4c27b279f6901eb'/>
<id>urn:sha1:4a476bd6d1d923922ec950ddc4c27b279f6901eb</id>
<content type='text'>
There's a bunch of cheap USB 10/100 devices based on QinHeng chipsets. The
vendor driver supports the CH9100 and CH9200 devices, but the majority of
the code is of the if (ch9100) {} else {} form, with the most significant
difference being that CH9200 provides a real MII interface but CH9100 fakes
one with a bunch of global variables and magic commands. I don't have a
CH9100, so it's probably better if someone who does provides an independent
driver for it. In any case, this is a lightly cleaned up version of the
vendor driver with all the CH9100 code dropped.

Signed-off-by: Matthew Garrett &lt;mjg59@srcf.ucam.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>r8152: fix the runtime suspend issues</title>
<updated>2015-09-10T03:27:54Z</updated>
<author>
<name>hayeswang</name>
<email>hayeswang@realtek.com</email>
</author>
<published>2015-09-07T03:57:44Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=2dd49e0f16fb0e07c6fcc1322ebba310f5827072'/>
<id>urn:sha1:2dd49e0f16fb0e07c6fcc1322ebba310f5827072</id>
<content type='text'>
Fix the runtime suspend issues result from the linking change.

Case 1:
a) link down occurs.
b) driver disable tx/rx.
c) autosuspend occurs.
d) hw linking up.
e) device suspends without enabling tx/rx.
f) couldn't wake up when receiving packets.

Case 2:
a) Nway results in linking down.
b) autosuspend occurs.
c) device suspends.
d) device may not wake up when linking up.

Signed-off-by: Hayes Wang &lt;hayeswang@realtek.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>r8152: split DRIVER_VERSION</title>
<updated>2015-09-10T03:27:54Z</updated>
<author>
<name>hayeswang</name>
<email>hayeswang@realtek.com</email>
</author>
<published>2015-09-07T03:57:43Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=d0942473e3ca4629a40bbf0c9fd74fc0c7ff2a79'/>
<id>urn:sha1:d0942473e3ca4629a40bbf0c9fd74fc0c7ff2a79</id>
<content type='text'>
Split DRIVER_VERSION into NETNEXT_VERSION and NET_VERSION. Then,
according to the value of DRIVER_VERSION, we could know which
patches are used generally without comparing the source code.

Signed-off-by: Hayes Wang &lt;hayeswang@realtek.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>usbnet: Fix a race between usbnet_stop() and the BH</title>
<updated>2015-09-08T20:17:43Z</updated>
<author>
<name>Eugene Shatokhin</name>
<email>eugene.shatokhin@rosalab.ru</email>
</author>
<published>2015-09-01T14:05:33Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=fcb0bb6aab256288a4e0a8650d26e4096ec30319'/>
<id>urn:sha1:fcb0bb6aab256288a4e0a8650d26e4096ec30319</id>
<content type='text'>
The race may happen when a device (e.g. YOTA 4G LTE Modem) is
unplugged while the system is downloading a large file from the Net.

Hardware breakpoints and Kprobes with delays were used to confirm that
the race does actually happen.

The race is on skb_queue ('next' pointer) between usbnet_stop()
and rx_complete(), which, in turn, calls usbnet_bh().

Here is a part of the call stack with the code where the changes to the
queue happen. The line numbers are for the kernel 4.1.0:

*0 __skb_unlink (skbuff.h:1517)
    prev-&gt;next = next;
*1 defer_bh (usbnet.c:430)
    spin_lock_irqsave(&amp;list-&gt;lock, flags);
    old_state = entry-&gt;state;
    entry-&gt;state = state;
    __skb_unlink(skb, list);
    spin_unlock(&amp;list-&gt;lock);
    spin_lock(&amp;dev-&gt;done.lock);
    __skb_queue_tail(&amp;dev-&gt;done, skb);
    if (dev-&gt;done.qlen == 1)
        tasklet_schedule(&amp;dev-&gt;bh);
    spin_unlock_irqrestore(&amp;dev-&gt;done.lock, flags);
*2 rx_complete (usbnet.c:640)
    state = defer_bh(dev, skb, &amp;dev-&gt;rxq, state);

At the same time, the following code repeatedly checks if the queue is
empty and reads these values concurrently with the above changes:

*0  usbnet_terminate_urbs (usbnet.c:765)
    /* maybe wait for deletions to finish. */
    while (!skb_queue_empty(&amp;dev-&gt;rxq)
        &amp;&amp; !skb_queue_empty(&amp;dev-&gt;txq)
        &amp;&amp; !skb_queue_empty(&amp;dev-&gt;done)) {
            schedule_timeout(msecs_to_jiffies(UNLINK_TIMEOUT_MS));
            set_current_state(TASK_UNINTERRUPTIBLE);
            netif_dbg(dev, ifdown, dev-&gt;net,
                  "waited for %d urb completions\n", temp);
    }
*1  usbnet_stop (usbnet.c:806)
    if (!(info-&gt;flags &amp; FLAG_AVOID_UNLINK_URBS))
        usbnet_terminate_urbs(dev);

As a result, it is possible, for example, that the skb is removed from
dev-&gt;rxq by __skb_unlink() before the check
"!skb_queue_empty(&amp;dev-&gt;rxq)" in usbnet_terminate_urbs() is made. It is
also possible in this case that the skb is added to dev-&gt;done queue
after "!skb_queue_empty(&amp;dev-&gt;done)" is checked. So
usbnet_terminate_urbs() may stop waiting and return while dev-&gt;done
queue still has an item.

Locking in defer_bh() and usbnet_terminate_urbs() was revisited to avoid
this race.

Signed-off-by: Eugene Shatokhin &lt;eugene.shatokhin@rosalab.ru&gt;
Reviewed-by: Bjørn Mork &lt;bjorn@mork.no&gt;
Acked-by: Oliver Neukum &lt;oneukum@suse.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>lan78xx: Fix ladv/radv error handling in lan78xx_link_reset()</title>
<updated>2015-09-07T02:46:56Z</updated>
<author>
<name>Geert Uytterhoeven</name>
<email>geert@linux-m68k.org</email>
</author>
<published>2015-09-04T10:47:28Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=99c79eceb152e2ac7f8a81ff55d4a810f730ec7b'/>
<id>urn:sha1:99c79eceb152e2ac7f8a81ff55d4a810f730ec7b</id>
<content type='text'>
net/usb/lan78xx.c: In function ‘lan78xx_link_reset’:
net/usb/lan78xx.c:1107: warning: comparison is always false due to limited range of data type
net/usb/lan78xx.c:1111: warning: comparison is always false due to limited range of data type

Assigning return values that can be negative error codes to "u16"
variables makes them positive, ignoring the errors.  Hence use "int"
instead.

Drop the "unlikely"s (unlikely considered harmful) and propagate the
actual error values instead of overriding them to -EIO while we're at
it.

Signed-off-by: Geert Uytterhoeven &lt;geert@linux-m68k.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: qmi_wwan: Sierra Wireless MC73xx -&gt; Sierra Wireless MC7304/MC7354</title>
<updated>2015-08-31T22:16:17Z</updated>
<author>
<name>David Ward</name>
<email>david.ward@ll.mit.edu</email>
</author>
<published>2015-08-31T18:15:14Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=e704059272aae2aaa5e5ce7a76e4c27c492e947e'/>
<id>urn:sha1:e704059272aae2aaa5e5ce7a76e4c27c492e947e</id>
<content type='text'>
Other Sierra Wireless MC73xx devices exist, with different USB IDs.

Cc: Bjørn Mork &lt;bjorn@mork.no&gt;
Signed-off-by: David Ward &lt;david.ward@ll.mit.edu&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
</feed>
