]> git.baikalelectronics.ru Git - kernel.git/commit
net: dsa: microchip: Fix ksz_read64()
authorBen Hutchings <ben.hutchings@mind.be>
Mon, 9 Aug 2021 22:59:12 +0000 (00:59 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 18 Aug 2021 06:56:59 +0000 (08:56 +0200)
commit4a6e4159451b0887cf29ebc06e30ba7b482dd2fe
tree9e8b2807d1f68a94931960df995665b475a29841
parent7bf9c1dcca22420aeeb21723093b6fc34582f2f8
net: dsa: microchip: Fix ksz_read64()

[ Upstream commit c34f674c8875235725c3ef86147a627f165d23b4 ]

ksz_read64() currently does some dubious byte-swapping on the two
halves of a 64-bit register, and then only returns the high bits.
Replace this with a straightforward expression.

Fixes: dae88cfc78e9 ("net: dsa: ksz: Add Microchip KSZ8795 DSA driver")
Signed-off-by: Ben Hutchings <ben.hutchings@mind.be>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/dsa/microchip/ksz_common.h