<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-toradex.git/drivers/net/usb, branch tegra</title>
<subtitle>Linux kernel for Apalis and Colibri modules</subtitle>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/'/>
<entry>
<title>net: usb: asix: add testmode support</title>
<updated>2018-11-29T12:54:14+00:00</updated>
<author>
<name>Dominik Sliwa</name>
<email>dominik.sliwa@toradex.com</email>
</author>
<published>2018-10-10T09:46:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=13bd0f089ac6babeb7248fe3db4b9c19233cce3c'/>
<id>13bd0f089ac6babeb7248fe3db4b9c19233cce3c</id>
<content type='text'>
Using module parameter, Etherent compliance testing
can be run.

Signed-off-by: Dominik Sliwa &lt;dominik.sliwa@toradex.com&gt;
Acked-by: Marcel Ziswiler &lt;marcel.ziswiler@toradex.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Using module parameter, Etherent compliance testing
can be run.

Signed-off-by: Dominik Sliwa &lt;dominik.sliwa@toradex.com&gt;
Acked-by: Marcel Ziswiler &lt;marcel.ziswiler@toradex.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>colibri_t20/t30: net: usb: asix: ethernet mac address handling</title>
<updated>2015-06-10T11:35:04+00:00</updated>
<author>
<name>Marcel Ziswiler</name>
<email>marcel.ziswiler@toradex.com</email>
</author>
<published>2015-06-10T11:35:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=090a9fba60fb60d58ef9fc29d7b0c93f08ce2c9e'/>
<id>090a9fba60fb60d58ef9fc29d7b0c93f08ce2c9e</id>
<content type='text'>
Revise Ethernet MAC address assignment: should now handle up to two
instances of custom user MACs (2nd one with a 0x100000 offset). This
way customer does not have to worry about NVM on a secondary Ethernet
on the carrier board and still gets a valid official MAC address from
us (e.g. analogous to how we did it on our Protea carrier board).

Please note that instead of defaulting to the default ASIX MAC address
if no valid one is encountered this driver now generates a random one
pre-fixed with the ASIX OUI.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Revise Ethernet MAC address assignment: should now handle up to two
instances of custom user MACs (2nd one with a 0x100000 offset). This
way customer does not have to worry about NVM on a secondary Ethernet
on the carrier board and still gets a valid official MAC address from
us (e.g. analogous to how we did it on our Protea carrier board).

Please note that instead of defaulting to the default ASIX MAC address
if no valid one is encountered this driver now generates a random one
pre-fixed with the ASIX OUI.
</pre>
</div>
</content>
</entry>
<entry>
<title>net: usb: asix: integrate driver 4.17.0</title>
<updated>2015-06-10T11:32:47+00:00</updated>
<author>
<name>Marcel Ziswiler</name>
<email>marcel.ziswiler@toradex.com</email>
</author>
<published>2015-06-10T11:32:47+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=0aa8350c3e98bcfebd55ab7d07e70baafcb55811'/>
<id>0aa8350c3e98bcfebd55ab7d07e70baafcb55811</id>
<content type='text'>
Integrate latest ASIX proprietary driver version 4.17.0
(AX88772C_772B_772A_760_772_178_LINUX_DRIVER_v4.17.0_Source.tar.bz2).
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Integrate latest ASIX proprietary driver version 4.17.0
(AX88772C_772B_772A_760_772_178_LINUX_DRIVER_v4.17.0_Source.tar.bz2).
</pre>
</div>
</content>
</entry>
<entry>
<title>net: asix: fix Ethernet MAC address assignment after suspend</title>
<updated>2013-04-16T09:54:53+00:00</updated>
<author>
<name>Marcel Ziswiler</name>
<email>marcel.ziswiler@toradex.com</email>
</author>
<published>2013-04-16T09:54:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=5aca4fabc06a93cfd0c99025fb38e3594a5d048c'/>
<id>5aca4fabc06a93cfd0c99025fb38e3594a5d048c</id>
<content type='text'>
Turns out after suspend an unbind and bind operation is executed upon
which we subsequently gave out the 2nd custom user MAC address followed
by the default ASIX MAC address.

This patch fixes it by checking for the custom user MAC address upon
unbinding and in this case properly releasing it for subsequent reuse.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Turns out after suspend an unbind and bind operation is executed upon
which we subsequently gave out the 2nd custom user MAC address followed
by the default ASIX MAC address.

This patch fixes it by checking for the custom user MAC address upon
unbinding and in this case properly releasing it for subsequent reuse.
</pre>
</div>
</content>
</entry>
<entry>
<title>net: asix: revise Ethernet MAC address assignment</title>
<updated>2012-12-05T15:20:01+00:00</updated>
<author>
<name>Marcel Ziswiler</name>
<email>marcel.ziswiler@toradex.com</email>
</author>
<published>2012-12-05T15:20:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=93596956391157d9ec9103b0c8033d0505b8b102'/>
<id>93596956391157d9ec9103b0c8033d0505b8b102</id>
<content type='text'>
Revise Ethernet MAC address assignment: should now use MAC from EEPROM
if set and further handles up to two instances of custom user MACs (2nd
one with a 0x100000 offset). This way customer does not have to put
EEPROM on a secondary Ethernet on the carrier board and still gets a
valid official MAC address from us (e.g. analogous to how we did it on
our Protea carrier board).
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Revise Ethernet MAC address assignment: should now use MAC from EEPROM
if set and further handles up to two instances of custom user MACs (2nd
one with a 0x100000 offset). This way customer does not have to put
EEPROM on a secondary Ethernet on the carrier board and still gets a
valid official MAC address from us (e.g. analogous to how we did it on
our Protea carrier board).
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge branch 'l4t/l4t-r16-r2' into colibri</title>
<updated>2012-11-12T14:28:39+00:00</updated>
<author>
<name>Marcel Ziswiler</name>
<email>marcel.ziswiler@toradex.com</email>
</author>
<published>2012-11-12T14:28:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=f987e832a9e79d2ce8009a5ea9c7b677624b3b30'/>
<id>f987e832a9e79d2ce8009a5ea9c7b677624b3b30</id>
<content type='text'>
Conflicts:
	arch/arm/mach-tegra/tegra3_usb_phy.c
	arch/arm/mach-tegra/usb_phy.c
	drivers/usb/gadget/tegra_udc.c
	drivers/usb/otg/Makefile
	drivers/video/tegra/fb.c
	sound/soc/tegra/tegra_pcm.c
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Conflicts:
	arch/arm/mach-tegra/tegra3_usb_phy.c
	arch/arm/mach-tegra/usb_phy.c
	drivers/usb/gadget/tegra_udc.c
	drivers/usb/otg/Makefile
	drivers/video/tegra/fb.c
	sound/soc/tegra/tegra_pcm.c
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge branch 'l4t/l4t-r16' into colibri</title>
<updated>2012-09-10T13:04:19+00:00</updated>
<author>
<name>Marcel Ziswiler</name>
<email>marcel.ziswiler@toradex.com</email>
</author>
<published>2012-09-10T12:53:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=d5bbf34613a877dbe3da847fa0432da8c6721e73'/>
<id>d5bbf34613a877dbe3da847fa0432da8c6721e73</id>
<content type='text'>
Merge with latest NVIDIA L4T R16.

Only real conflict concerning inverted VBUS gpio support.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Merge with latest NVIDIA L4T R16.

Only real conflict concerning inverted VBUS gpio support.
</pre>
</div>
</content>
</entry>
<entry>
<title>usbnet: fix skb traversing races during unlink(v2)</title>
<updated>2012-09-05T00:10:35+00:00</updated>
<author>
<name>Ming Lei</name>
<email>tom.leiming@gmail.com</email>
</author>
<published>2012-04-26T03:33:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=6f61e5baa83ef8c75746eabe90be0588f6d86b37'/>
<id>6f61e5baa83ef8c75746eabe90be0588f6d86b37</id>
<content type='text'>
Commit 4231d47e6fe69f061f96c98c30eaf9fb4c14b96d(net/usbnet: avoid
recursive locking in usbnet_stop()) fixes the recursive locking
problem by releasing the skb queue lock before unlink, but may
cause skb traversing races:
	- after URB is unlinked and the queue lock is released,
	the refered skb and skb-&gt;next may be moved to done queue,
	even be released
	- in skb_queue_walk_safe, the next skb is still obtained
	by next pointer of the last skb
	- so maybe trigger oops or other problems

This patch extends the usage of entry-&gt;state to describe 'start_unlink'
state, so always holding the queue(rx/tx) lock to change the state if
the referd skb is in rx or tx queue because we need to know if the
refered urb has been started unlinking in unlink_urbs.

The other part of this patch is based on Huajun's patch:
always traverse from head of the tx/rx queue to get skb which is
to be unlinked but not been started unlinking.

Signed-off-by: Huajun Li &lt;huajun.li.lee@gmail.com&gt;
Signed-off-by: Ming Lei &lt;tom.leiming@gmail.com&gt;
Cc: Oliver Neukum &lt;oneukum@suse.de&gt;
Cc: stable@kernel.org
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
(cherry picked from commit 5b6e9bcdeb65634b4ad604eb4536404bbfc62cfa)

Bug 1040642

Change-Id: I1a8c248016529bebf71d540738ad4726cf3f59b7
Signed-off-by: Steve Lin &lt;stlin@nvidia.com&gt;
Reviewed-on: http://git-master/r/128693
GVS: Gerrit_Virtual_Submit
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Commit 4231d47e6fe69f061f96c98c30eaf9fb4c14b96d(net/usbnet: avoid
recursive locking in usbnet_stop()) fixes the recursive locking
problem by releasing the skb queue lock before unlink, but may
cause skb traversing races:
	- after URB is unlinked and the queue lock is released,
	the refered skb and skb-&gt;next may be moved to done queue,
	even be released
	- in skb_queue_walk_safe, the next skb is still obtained
	by next pointer of the last skb
	- so maybe trigger oops or other problems

This patch extends the usage of entry-&gt;state to describe 'start_unlink'
state, so always holding the queue(rx/tx) lock to change the state if
the referd skb is in rx or tx queue because we need to know if the
refered urb has been started unlinking in unlink_urbs.

The other part of this patch is based on Huajun's patch:
always traverse from head of the tx/rx queue to get skb which is
to be unlinked but not been started unlinking.

Signed-off-by: Huajun Li &lt;huajun.li.lee@gmail.com&gt;
Signed-off-by: Ming Lei &lt;tom.leiming@gmail.com&gt;
Cc: Oliver Neukum &lt;oneukum@suse.de&gt;
Cc: stable@kernel.org
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
(cherry picked from commit 5b6e9bcdeb65634b4ad604eb4536404bbfc62cfa)

Bug 1040642

Change-Id: I1a8c248016529bebf71d540738ad4726cf3f59b7
Signed-off-by: Steve Lin &lt;stlin@nvidia.com&gt;
Reviewed-on: http://git-master/r/128693
GVS: Gerrit_Virtual_Submit
</pre>
</div>
</content>
</entry>
<entry>
<title>net/usbnet: avoid recursive locking in usbnet_stop()</title>
<updated>2012-08-23T21:46:03+00:00</updated>
<author>
<name>Steve Lin</name>
<email>stlin@nvidia.com</email>
</author>
<published>2012-08-22T21:55:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=81c24e718939bc0a2d774ba6790febf57b4da4a5'/>
<id>81c24e718939bc0a2d774ba6790febf57b4da4a5</id>
<content type='text'>
|kernel BUG at kernel/rtmutex.c:724!
|[&lt;c029599c&gt;] (rt_spin_lock_slowlock+0x108/0x2bc) from [&lt;c01c2330&gt;] (defer_bh+0x1c/0xb4)
|[&lt;c01c2330&gt;] (defer_bh+0x1c/0xb4) from [&lt;c01c3afc&gt;] (rx_complete+0x14c/0x194)
|[&lt;c01c3afc&gt;] (rx_complete+0x14c/0x194) from [&lt;c01cac88&gt;] (usb_hcd_giveback_urb+0xa0/0xf0)
|[&lt;c01cac88&gt;] (usb_hcd_giveback_urb+0xa0/0xf0) from [&lt;c01e1ff4&gt;] (musb_giveback+0x34/0x40)
|[&lt;c01e1ff4&gt;] (musb_giveback+0x34/0x40) from [&lt;c01e2b1c&gt;] (musb_advance_schedule+0xb4/0x1c0)
|[&lt;c01e2b1c&gt;] (musb_advance_schedule+0xb4/0x1c0) from [&lt;c01e2ca8&gt;] (musb_cleanup_urb.isra.9+0x80/0x8c)
|[&lt;c01e2ca8&gt;] (musb_cleanup_urb.isra.9+0x80/0x8c) from [&lt;c01e2ed0&gt;] (musb_urb_dequeue+0xec/0x108)
|[&lt;c01e2ed0&gt;] (musb_urb_dequeue+0xec/0x108) from [&lt;c01cbb90&gt;] (unlink1+0xbc/0xcc)
|[&lt;c01cbb90&gt;] (unlink1+0xbc/0xcc) from [&lt;c01cc2ec&gt;] (usb_hcd_unlink_urb+0x54/0xa8)
|[&lt;c01cc2ec&gt;] (usb_hcd_unlink_urb+0x54/0xa8) from [&lt;c01c2a84&gt;] (unlink_urbs.isra.17+0x2c/0x58)
|[&lt;c01c2a84&gt;] (unlink_urbs.isra.17+0x2c/0x58) from [&lt;c01c2b44&gt;] (usbnet_terminate_urbs+0x94/0x10c)
|[&lt;c01c2b44&gt;] (usbnet_terminate_urbs+0x94/0x10c) from [&lt;c01c2d68&gt;] (usbnet_stop+0x100/0x15c)
|[&lt;c01c2d68&gt;] (usbnet_stop+0x100/0x15c) from [&lt;c020f718&gt;] (__dev_close_many+0x94/0xc8)

defer_bh() takes the lock which is hold during unlink_urbs(). The safe
walk suggest that the skb will be removed from the list and this is done
by defer_bh() so it seems to be okay to drop the lock here.

Reported-by: AnÃ­bal Almeida Pinto &lt;anibal.pinto@efacec.com&gt;
Signed-off-by: Sebastian Andrzej Siewior &lt;bigeasy@linutronix.de&gt;
Acked-by: Oliver Neukum &lt;oliver@neukum.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
(cherry picked from commit 4231d47e6fe69f061f96c98c30eaf9fb4c14b96d)
---------------------------------------------------------------------
net/usbnet: reserve headroom on rx skbs

network drivers should reserve some headroom on incoming skbs so that we
dont need expensive reallocations, eg forwarding packets in tunnels.

This NET_SKB_PAD padding is done in various helpers, like
__netdev_alloc_skb_ip_align() in this patch, combining NET_SKB_PAD and
NET_IP_ALIGN magic.

Signed-off-by: Eric Dumazet &lt;eric.dumazet@gmail.com&gt;
Cc: Oliver Neukum &lt;oneukum@suse.de&gt;
Cc: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Acked-by: Oliver Neukum &lt;oneukum@suse.de&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
(cherry picked from commit 7bdd402706cf26bfef9050dfee3f229b7f33ee4f)
---------------------------------------------------------------------
usbnet: use netif_tx_wake_queue instead of netif_start_queue

If host is going to autosuspend function with two interfaces and
if IP packet has arrived in-between of two usbnet_suspend() callbacks,
i.e usbnet_resume() is called in-between, tx data flow is stopped.
When autosuspend timer expires and device is put to autosuspend
again, tx queue is waked up and data can be sent again.
This behavior might be repeated several times in a row.

Tested on Intel/ARM.

Reviewed-by: Sjur Brændeland &lt;sjur.brandeland@stericsson.com&gt;
Tested-by: Dmitry Tarnyagin &lt;dmitry.tarnyagin@stericsson.com&gt;
Signed-off-by: Alexey Orishko &lt;alexey.orishko@stericsson.com&gt;
Acked-by: Oliver Neukum &lt;oneukum@suse.de&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
(cherry picked from commit 1aa9bc5b2f4cf8c48944fb9a607bf1dd674e2c10)
---------------------------------------------------------------------
usbnet: increase URB reference count before usb_unlink_urb

Commit 4231d47e6fe69f061f96c98c30eaf9fb4c14b96d(net/usbnet: avoid
recursive locking in usbnet_stop()) fixes the recursive locking
problem by releasing the skb queue lock, but it makes usb_unlink_urb
racing with defer_bh, and the URB to being unlinked may be freed before
or during calling usb_unlink_urb, so use-after-free problem may be
triggerd inside usb_unlink_urb.

The patch fixes the use-after-free problem by increasing URB
reference count with skb queue lock held before calling
usb_unlink_urb, so the URB won't be freed until return from
usb_unlink_urb.

Reported-by: Dave Jones &lt;davej@redhat.com&gt;
Signed-off-by: Ming Lei &lt;tom.leiming@gmail.com&gt;
Acked-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
(cherry picked from commit 0956a8c20b23d429e79ff86d4325583fc06f9eb4)
---------------------------------------------------------------------
usbnet: don't clear urb-&gt;dev in tx_complete

URB unlinking is always racing with its completion and tx_complete
may be called before or during running usb_unlink_urb, so tx_complete
must not clear urb-&gt;dev since it will be used in unlink path,
otherwise invalid memory accesses or usb device leak may be caused
inside usb_unlink_urb.

Signed-off-by: Ming Lei &lt;tom.leiming@gmail.com&gt;
Acked-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
(cherry picked from commit 5d5440a835710d09f0ef18da5000541ec98b537a)
---------------------------------------------------------------------
usbnet: consider device busy at each recieved packet

usbnet should centrally handle busy reporting in the rx path
so subdrivers need not worry. This hurts use cases which do
rx only or predominantly.

Signed-off-by: Oliver Neukum &lt;oneukum@suse.de&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
(cherry picked from commit 8a78335442cea429afb2b964318b6e257448ea00)
---------------------------------------------------------------------
usbnet: fix leak of transfer buffer of dev-&gt;interrupt

The transfer buffer of dev-&gt;interrupt is allocated in .probe path,
but not freed in .disconnet path, so mark the interrupt URB as
URB_FREE_BUFFER to free the buffer when the URB is destroyed.

Signed-off-by: Ming Lei &lt;tom.leiming@gmail.com&gt;
Acked-by: Oliver Neukum &lt;oneukum@suse.de&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
(cherry picked from commit 267a83e8e00dc5a878b24c39883643c20a8b1482)

Bug 1036768

Change-Id: I5d6620c8ff4e6cef52c3f467fb2196658c4d47b1
Signed-off-by: Steve Lin &lt;stlin@nvidia.com&gt;
Reviewed-on: http://git-master/r/125338
GVS: Gerrit_Virtual_Submit
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
|kernel BUG at kernel/rtmutex.c:724!
|[&lt;c029599c&gt;] (rt_spin_lock_slowlock+0x108/0x2bc) from [&lt;c01c2330&gt;] (defer_bh+0x1c/0xb4)
|[&lt;c01c2330&gt;] (defer_bh+0x1c/0xb4) from [&lt;c01c3afc&gt;] (rx_complete+0x14c/0x194)
|[&lt;c01c3afc&gt;] (rx_complete+0x14c/0x194) from [&lt;c01cac88&gt;] (usb_hcd_giveback_urb+0xa0/0xf0)
|[&lt;c01cac88&gt;] (usb_hcd_giveback_urb+0xa0/0xf0) from [&lt;c01e1ff4&gt;] (musb_giveback+0x34/0x40)
|[&lt;c01e1ff4&gt;] (musb_giveback+0x34/0x40) from [&lt;c01e2b1c&gt;] (musb_advance_schedule+0xb4/0x1c0)
|[&lt;c01e2b1c&gt;] (musb_advance_schedule+0xb4/0x1c0) from [&lt;c01e2ca8&gt;] (musb_cleanup_urb.isra.9+0x80/0x8c)
|[&lt;c01e2ca8&gt;] (musb_cleanup_urb.isra.9+0x80/0x8c) from [&lt;c01e2ed0&gt;] (musb_urb_dequeue+0xec/0x108)
|[&lt;c01e2ed0&gt;] (musb_urb_dequeue+0xec/0x108) from [&lt;c01cbb90&gt;] (unlink1+0xbc/0xcc)
|[&lt;c01cbb90&gt;] (unlink1+0xbc/0xcc) from [&lt;c01cc2ec&gt;] (usb_hcd_unlink_urb+0x54/0xa8)
|[&lt;c01cc2ec&gt;] (usb_hcd_unlink_urb+0x54/0xa8) from [&lt;c01c2a84&gt;] (unlink_urbs.isra.17+0x2c/0x58)
|[&lt;c01c2a84&gt;] (unlink_urbs.isra.17+0x2c/0x58) from [&lt;c01c2b44&gt;] (usbnet_terminate_urbs+0x94/0x10c)
|[&lt;c01c2b44&gt;] (usbnet_terminate_urbs+0x94/0x10c) from [&lt;c01c2d68&gt;] (usbnet_stop+0x100/0x15c)
|[&lt;c01c2d68&gt;] (usbnet_stop+0x100/0x15c) from [&lt;c020f718&gt;] (__dev_close_many+0x94/0xc8)

defer_bh() takes the lock which is hold during unlink_urbs(). The safe
walk suggest that the skb will be removed from the list and this is done
by defer_bh() so it seems to be okay to drop the lock here.

Reported-by: AnÃ­bal Almeida Pinto &lt;anibal.pinto@efacec.com&gt;
Signed-off-by: Sebastian Andrzej Siewior &lt;bigeasy@linutronix.de&gt;
Acked-by: Oliver Neukum &lt;oliver@neukum.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
(cherry picked from commit 4231d47e6fe69f061f96c98c30eaf9fb4c14b96d)
---------------------------------------------------------------------
net/usbnet: reserve headroom on rx skbs

network drivers should reserve some headroom on incoming skbs so that we
dont need expensive reallocations, eg forwarding packets in tunnels.

This NET_SKB_PAD padding is done in various helpers, like
__netdev_alloc_skb_ip_align() in this patch, combining NET_SKB_PAD and
NET_IP_ALIGN magic.

Signed-off-by: Eric Dumazet &lt;eric.dumazet@gmail.com&gt;
Cc: Oliver Neukum &lt;oneukum@suse.de&gt;
Cc: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Acked-by: Oliver Neukum &lt;oneukum@suse.de&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
(cherry picked from commit 7bdd402706cf26bfef9050dfee3f229b7f33ee4f)
---------------------------------------------------------------------
usbnet: use netif_tx_wake_queue instead of netif_start_queue

If host is going to autosuspend function with two interfaces and
if IP packet has arrived in-between of two usbnet_suspend() callbacks,
i.e usbnet_resume() is called in-between, tx data flow is stopped.
When autosuspend timer expires and device is put to autosuspend
again, tx queue is waked up and data can be sent again.
This behavior might be repeated several times in a row.

Tested on Intel/ARM.

Reviewed-by: Sjur Brændeland &lt;sjur.brandeland@stericsson.com&gt;
Tested-by: Dmitry Tarnyagin &lt;dmitry.tarnyagin@stericsson.com&gt;
Signed-off-by: Alexey Orishko &lt;alexey.orishko@stericsson.com&gt;
Acked-by: Oliver Neukum &lt;oneukum@suse.de&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
(cherry picked from commit 1aa9bc5b2f4cf8c48944fb9a607bf1dd674e2c10)
---------------------------------------------------------------------
usbnet: increase URB reference count before usb_unlink_urb

Commit 4231d47e6fe69f061f96c98c30eaf9fb4c14b96d(net/usbnet: avoid
recursive locking in usbnet_stop()) fixes the recursive locking
problem by releasing the skb queue lock, but it makes usb_unlink_urb
racing with defer_bh, and the URB to being unlinked may be freed before
or during calling usb_unlink_urb, so use-after-free problem may be
triggerd inside usb_unlink_urb.

The patch fixes the use-after-free problem by increasing URB
reference count with skb queue lock held before calling
usb_unlink_urb, so the URB won't be freed until return from
usb_unlink_urb.

Reported-by: Dave Jones &lt;davej@redhat.com&gt;
Signed-off-by: Ming Lei &lt;tom.leiming@gmail.com&gt;
Acked-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
(cherry picked from commit 0956a8c20b23d429e79ff86d4325583fc06f9eb4)
---------------------------------------------------------------------
usbnet: don't clear urb-&gt;dev in tx_complete

URB unlinking is always racing with its completion and tx_complete
may be called before or during running usb_unlink_urb, so tx_complete
must not clear urb-&gt;dev since it will be used in unlink path,
otherwise invalid memory accesses or usb device leak may be caused
inside usb_unlink_urb.

Signed-off-by: Ming Lei &lt;tom.leiming@gmail.com&gt;
Acked-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
(cherry picked from commit 5d5440a835710d09f0ef18da5000541ec98b537a)
---------------------------------------------------------------------
usbnet: consider device busy at each recieved packet

usbnet should centrally handle busy reporting in the rx path
so subdrivers need not worry. This hurts use cases which do
rx only or predominantly.

Signed-off-by: Oliver Neukum &lt;oneukum@suse.de&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
(cherry picked from commit 8a78335442cea429afb2b964318b6e257448ea00)
---------------------------------------------------------------------
usbnet: fix leak of transfer buffer of dev-&gt;interrupt

The transfer buffer of dev-&gt;interrupt is allocated in .probe path,
but not freed in .disconnet path, so mark the interrupt URB as
URB_FREE_BUFFER to free the buffer when the URB is destroyed.

Signed-off-by: Ming Lei &lt;tom.leiming@gmail.com&gt;
Acked-by: Oliver Neukum &lt;oneukum@suse.de&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
(cherry picked from commit 267a83e8e00dc5a878b24c39883643c20a8b1482)

Bug 1036768

Change-Id: I5d6620c8ff4e6cef52c3f467fb2196658c4d47b1
Signed-off-by: Steve Lin &lt;stlin@nvidia.com&gt;
Reviewed-on: http://git-master/r/125338
GVS: Gerrit_Virtual_Submit
</pre>
</div>
</content>
</entry>
<entry>
<title>usb: cdc_ether: Add rmnet device info to ZM5250</title>
<updated>2012-07-31T21:58:55+00:00</updated>
<author>
<name>BH Hsieh</name>
<email>bhsieh@nvidia.com</email>
</author>
<published>2012-07-30T07:16:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=f92af19b741e3566e64efae2fc4e5d56f189b4f1'/>
<id>f92af19b741e3566e64efae2fc4e5d56f189b4f1</id>
<content type='text'>
Modified device info element for ZM5250 to
sync with framework.

Change-Id: I855678edccef50c549960ee209e500ec6d692e36
Signed-off-by: BH Hsieh &lt;bhsieh@nvidia.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Modified device info element for ZM5250 to
sync with framework.

Change-Id: I855678edccef50c549960ee209e500ec6d692e36
Signed-off-by: BH Hsieh &lt;bhsieh@nvidia.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
