]> git.hungrycats.org Git - linux/commit
Revert "net: dsa: qca8k: cache lo and hi for mdio write"
authorChristian Marangi <ansuelsmth@gmail.com>
Thu, 29 Dec 2022 16:33:34 +0000 (17:33 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 12 Jan 2023 11:00:45 +0000 (12:00 +0100)
commit56970b68b38055497583ab00c92a2bf4afd9f607
treefb4b4ec5d0a4e97cd5d55d2c097bc0660fa91fdc
parentba251112d4c7b551a82254189bdfe6b1970de470
Revert "net: dsa: qca8k: cache lo and hi for mdio write"

commit 03cb9e6d0b32b768e3d9d473c5c4ca1100877664 upstream.

This reverts commit 2481d206fae7884cd07014fd1318e63af35e99eb.

The Documentation is very confusing about the topic.
The cache logic for hi and lo is wrong and actually miss some regs to be
actually written.

What the Documentation actually intended was that it's possible to skip
writing hi OR lo if half of the reg is not needed to be written or read.

Revert the change in favor of a better and correct implementation.

Reported-by: Ronald Wahl <ronald.wahl@raritan.com>
Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
Cc: stable@vger.kernel.org # v5.18+
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/dsa/qca/qca8k-8xxx.c
drivers/net/dsa/qca/qca8k.h