netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] net: usb: asix88179_178a: Add support for the Belkin B2B128
@ 2017-06-26 17:41 Andrew F. Davis
  2017-06-27  9:01 ` David Laight
       [not found] ` <20170626174120.1293-1-afd-l0cyMroinI0@public.gmane.org>
  0 siblings, 2 replies; 3+ messages in thread
From: Andrew F. Davis @ 2017-06-26 17:41 UTC (permalink / raw)
  To: David S . Miller, Allan Chou, Geoffrey Tran
  Cc: linux-usb-u79uwXL29TY76Z2rM5mHXA, netdev-u79uwXL29TY76Z2rM5mHXA,
	Andrew F . Davis

The Belkin B2B128 is a USB 3.0 Hub + Gigabit Ethernet Adapter, the
Ethernet adapter uses the ASIX AX88179 USB 3.0 to Gigabit Ethernet
chip supported by this driver, add the USB ID for the same.

This patch is based on work by Geoffrey Tran <geoffrey.tran-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
who has indicated they would like this upstreamed by someone more
familiar with the upstreaming process.

Signed-off-by: Andrew F. Davis <afd-l0cyMroinI0@public.gmane.org>
---
 drivers/net/usb/ax88179_178a.c | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/drivers/net/usb/ax88179_178a.c b/drivers/net/usb/ax88179_178a.c
index 51cf60092a18..4037ab27734a 100644
--- a/drivers/net/usb/ax88179_178a.c
+++ b/drivers/net/usb/ax88179_178a.c
@@ -1722,6 +1722,18 @@ static const struct driver_info lenovo_info = {
 	.tx_fixup = ax88179_tx_fixup,
 };
 
+static const struct driver_info belkin_info = {
+	.description = "Belkin USB Ethernet Adapter",
+	.bind	= ax88179_bind,
+	.unbind = ax88179_unbind,
+	.status = ax88179_status,
+	.link_reset = ax88179_link_reset,
+	.reset	= ax88179_reset,
+	.flags	= FLAG_ETHER | FLAG_FRAMING_AX,
+	.rx_fixup = ax88179_rx_fixup,
+	.tx_fixup = ax88179_tx_fixup,
+};
+
 static const struct usb_device_id products[] = {
 {
 	/* ASIX AX88179 10/100/1000 */
@@ -1751,6 +1763,10 @@ static const struct usb_device_id products[] = {
 	/* Lenovo OneLinkDock Gigabit LAN */
 	USB_DEVICE(0x17ef, 0x304b),
 	.driver_info = (unsigned long)&lenovo_info,
+}, {
+	/* Belkin B2B128 USB 3.0 Hub + Gigabit Ethernet Adapter */
+	USB_DEVICE(0x050d, 0x0128),
+	.driver_info = (unsigned long)&belkin_info,
 },
 	{ },
 };
-- 
2.13.0

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* RE: [PATCH] net: usb: asix88179_178a: Add support for the Belkin B2B128
  2017-06-26 17:41 [PATCH] net: usb: asix88179_178a: Add support for the Belkin B2B128 Andrew F. Davis
@ 2017-06-27  9:01 ` David Laight
       [not found] ` <20170626174120.1293-1-afd-l0cyMroinI0@public.gmane.org>
  1 sibling, 0 replies; 3+ messages in thread
From: David Laight @ 2017-06-27  9:01 UTC (permalink / raw)
  To: 'Andrew F. Davis', David S . Miller, Allan Chou,
	Geoffrey Tran
  Cc: linux-usb@vger.kernel.org, netdev@vger.kernel.org

From: Andrew F. Davis
> Sent: 26 June 2017 18:41
> The Belkin B2B128 is a USB 3.0 Hub + Gigabit Ethernet Adapter, the
> Ethernet adapter uses the ASIX AX88179 USB 3.0 to Gigabit Ethernet
> chip supported by this driver, add the USB ID for the same.
...

I've just had a look at the current version of ax88179_178a.c.
It still makes me pull my hair out....

Not the least of the problems is that it lies about skb->truesize.
All the receive skb are longer than 16k - so will be 64k, but
it sets skb->truesize based on the actual receive frame size.

A lot of the code is also 'over complicated' - making it slower
that strictly necessary.

There is also the more general problem that usbnet is horribly
inefficient for anything trying to run at Ge speeds (never mind
anything faster.

	David

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] net: usb: asix88179_178a: Add support for the Belkin B2B128
       [not found] ` <20170626174120.1293-1-afd-l0cyMroinI0@public.gmane.org>
@ 2017-06-27 19:47   ` David Miller
  0 siblings, 0 replies; 3+ messages in thread
From: David Miller @ 2017-06-27 19:47 UTC (permalink / raw)
  To: afd-l0cyMroinI0
  Cc: allan-knRN6Y/kmf1NUHwG+Fw1Kw,
	geoffrey.tran-Re5JQEeQqe8AvxtiuMwx3w,
	linux-usb-u79uwXL29TY76Z2rM5mHXA, netdev-u79uwXL29TY76Z2rM5mHXA

From: "Andrew F. Davis" <afd-l0cyMroinI0@public.gmane.org>
Date: Mon, 26 Jun 2017 12:41:20 -0500

> The Belkin B2B128 is a USB 3.0 Hub + Gigabit Ethernet Adapter, the
> Ethernet adapter uses the ASIX AX88179 USB 3.0 to Gigabit Ethernet
> chip supported by this driver, add the USB ID for the same.
> 
> This patch is based on work by Geoffrey Tran <geoffrey.tran-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
> who has indicated they would like this upstreamed by someone more
> familiar with the upstreaming process.
> 
> Signed-off-by: Andrew F. Davis <afd-l0cyMroinI0@public.gmane.org>

Applied, thank you.
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-06-27 19:47 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-06-26 17:41 [PATCH] net: usb: asix88179_178a: Add support for the Belkin B2B128 Andrew F. Davis
2017-06-27  9:01 ` David Laight
     [not found] ` <20170626174120.1293-1-afd-l0cyMroinI0@public.gmane.org>
2017-06-27 19:47   ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).