dl2k: Add support for IP1000A-based cards
authorOndrej Zary <linux@rainbow-software.org>
Sun, 15 Nov 2015 21:36:11 +0000 (22:36 +0100)
committerDavid S. Miller <davem@davemloft.net>
Mon, 16 Nov 2015 22:11:31 +0000 (17:11 -0500)
commitc3f45d322cbd379c46466cc2ecab7e2d719b22ed
treef8bbc735fb79fbc7306dd4e96098c834aea58c9a
parent41033f029e393a64e81966cbe34d66c6cf8a2e7e
dl2k: Add support for IP1000A-based cards

Add support for IP1000A chips to dl2k driver.
IP1000A chip looks like a TC9020 with integrated PHY.

This allows IP1000A chips to work reliably because the ipg driver is
buggy - it loses packets under load and then completely stops
transmitting data.

Tested with Asus NX1101 v2.0 at 10, 100 and 1000Mbps:
vendor=0x13f0 device=0x1023 (rev 0x41)
subsystem vendor=0x1043 device=0x8180

MAC address registers access needed to be changed from 8-bit to 16-bit
because 8-bit does not work on IP1000A. 8-bit access is not even
allowed in the TC9020 datasheet (although it worked). 16-bit access
works on both.

Tested that it does not break D-Link DGE-550T (DL-2000 chip, probably
a rebranded TC9020):
vendor=0x1186 device=0x4000 (rev 0x0c)
subsystem vendor=0x1186 device=0x4000

Signed-off-by: Ondrej Zary <linux@rainbow-software.org>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/dlink/Kconfig
drivers/net/ethernet/dlink/dl2k.c
drivers/net/ethernet/dlink/dl2k.h