linux/drivers/net/ethernet/micrel
Marek Vasut 69233bba65 net: ks8851-ml: Remove 8-bit bus accessors
This driver is mixing 8-bit and 16-bit bus accessors for reasons unknown,
however the speculation is that this was some sort of attempt to support
the 8-bit bus mode.

As per the KS8851-16MLL documentation, all two registers accessed via the
8-bit accessors are internally 16-bit registers, so reading them using
16-bit accessors is fine. The KS_CCR read can be converted to 16-bit read
outright, as it is already a concatenation of two 8-bit reads of that
register. The KS_RXQCR accesses are 8-bit only, however writing the top
8 bits of the register is OK as well, since the driver caches the entire
16-bit register value anyway.

Finally, the driver is not used by any hardware in the kernel right now.
The only hardware available to me is one with 16-bit bus, so I have no
way to test the 8-bit bus mode, however it is unlikely this ever really
worked anyway. If the 8-bit bus mode is ever required, it can be easily
added by adjusting the 16-bit accessors to do 2 consecutive accesses,
which is how this should have been done from the beginning.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: David S. Miller <davem@davemloft.net>
Cc: Lukas Wunner <lukas@wunner.de>
Cc: Petr Stetiar <ynezz@true.cz>
Cc: YueHaibing <yuehaibing@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2020-02-16 19:41:09 -08:00
..
Kconfig net: remove ks8695 driver 2019-09-04 17:57:43 +02:00
ks8842.c netdev: pass the stuck queue to the timeout handler 2019-12-12 21:38:57 -08:00
ks8851.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
ks8851.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
ks8851_mll.c net: ks8851-ml: Remove 8-bit bus accessors 2020-02-16 19:41:09 -08:00
ksz884x.c netdev: pass the stuck queue to the timeout handler 2019-12-12 21:38:57 -08:00
Makefile net: remove ks8695 driver 2019-09-04 17:57:43 +02:00