]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
net: stmmac: sun8i: drop unneeded default syscon value
authorAndre Przywara <andre.przywara@arm.com>
Mon, 25 Aug 2025 17:20:55 +0000 (18:20 +0100)
committerJakub Kicinski <kuba@kernel.org>
Thu, 28 Aug 2025 00:40:14 +0000 (17:40 -0700)
commit330355191a2d9a59137455b774b9a66dd6d068d4
tree2952f2ec96caa2e481bc833e2a2fb1136a470c77
parent40fb9751ccc6e2ad450a2b938d7c8583a34d4a56
net: stmmac: sun8i: drop unneeded default syscon value

For some odd reason we were very jealous about the value of the EMAC
clock register from the syscon block, insisting on a reset value and
only doing read-modify-write operations on that register, even though we
pretty much know the register layout.
This already led to a basically redundant entry for the H6, which only
differs by that value. We seem to have the same situation with the new
A523 SoC, which again is compatible to the A64, but has a different
syscon reset value.

Drop any assumptions about that value, and set or clear the bits that we
want to program, from scratch (starting with a value of 0). For the
remove() implementation, we just turn on the POWERDOWN bit, and deselect
the internal PHY, which mimics the existing code.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Jernej Skrabec <jernej.skrabec@gmail.com>
Acked-by: Corentin LABBE <clabbe.montjoie@gmail.com>
Tested-by: Corentin LABBE <clabbe.montjoie@gmail.com>
Tested-by: Paul Kocialkowski <paulk@sys-base.io>
Reviewed-by: Paul Kocialkowski <paulk@sys-base.io>
Reviewed-by: Jacob Keller <jacob.e.keller@intel.com>
Link: https://patch.msgid.link/20250825172055.19794-1-andre.przywara@arm.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/stmicro/stmmac/dwmac-sun8i.c