linux-stable/drivers/net
Jesse Van Gavere 5af53577c6 net: dsa: microchip: KSZ9896 register regmap alignment to 32 bit boundaries
Commit 8d7ae22ae9 ("net: dsa: microchip: KSZ9477 register regmap
alignment to 32 bit boundaries") fixed an issue whereby regmap_reg_range
did not allow writes as 32 bit words to KSZ9477 PHY registers, this fix
for KSZ9896 is adapted from there as the same errata is present in
KSZ9896C as "Module 5: Certain PHY registers must be written as pairs
instead of singly" the explanation below is likewise taken from this
commit.

The commit provided code
to apply "Module 6: Certain PHY registers must be written as pairs instead
of singly" errata for KSZ9477 as this chip for certain PHY registers
(0xN120 to 0xN13F, N=1,2,3,4,5) must be accessed as 32 bit words instead
of 16 or 8 bit access.
Otherwise, adjacent registers (no matter if reserved or not) are
overwritten with 0x0.

Without this patch some registers (e.g. 0x113c or 0x1134) required for 32
bit access are out of valid regmap ranges.

As a result, following error is observed and KSZ9896 is not properly
configured:

ksz-switch spi1.0: can't rmw 32bit reg 0x113c: -EIO
ksz-switch spi1.0: can't rmw 32bit reg 0x1134: -EIO
ksz-switch spi1.0 lan1 (uninitialized): failed to connect to PHY: -EIO
ksz-switch spi1.0 lan1 (uninitialized): error -5 setting up PHY for tree 0, switch 0, port 0

The solution is to modify regmap_reg_range to allow accesses with 4 bytes
boundaries.

Fixes: 5c844d57aa ("net: dsa: microchip: fix writes to phy registers >= 0x10")
Signed-off-by: Jesse Van Gavere <jesse.vangavere@scioteq.com>
Link: https://patch.msgid.link/20241211092932.26881-1-jesse.vangavere@scioteq.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2024-12-12 07:10:11 -08:00
..
arcnet
bonding bonding: Fix feature propagation of NETIF_F_GSO_ENCAP_ALL 2024-12-12 11:59:18 +01:00
caif
can rtnetlink: fix double call of rtnl_link_get_net_ifla() 2024-12-03 11:29:29 +01:00
dsa net: dsa: microchip: KSZ9896 register regmap alignment to 32 bit boundaries 2024-12-12 07:10:11 -08:00
ethernet net: renesas: rswitch: fix initial MPIC register setting 2024-12-12 15:32:22 +01:00
fddi
fjes net: fjes: use ethtool string helpers 2024-10-31 19:36:59 -07:00
hamradio net: hamradio: scc: Switch to irq_get_nr_irqs() 2024-10-16 21:56:57 +02:00
hippi
hyperv Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2024-10-25 09:08:22 +02:00
ieee802154 net: Switch back to struct platform_driver::remove() 2024-10-04 16:39:57 -07:00
ipa net: Switch back to struct platform_driver::remove() 2024-10-04 16:39:57 -07:00
ipvlan ipvlan: Prepare ipvlan_process_v4_outbound() to future .flowi4_tos conversion. 2024-11-03 14:28:37 -08:00
mctp net: mctp: Expose transport binding identifier via IFLA attribute 2024-11-09 09:04:54 -08:00
mdio net: mdio-ipq4019: add missing error check 2024-11-26 11:01:39 +01:00
netdevsim netdevsim: add more hw_features 2024-11-11 14:12:20 -08:00
pcs net: pcs: xpcs: remove return statements in void function 2024-10-23 16:10:16 +02:00
phy net: phy: microchip: Reset LAN88xx PHY to ensure clean link state on LAN7800/7850 2024-12-02 18:56:41 -08:00
plip net: plip: fix break; causing plip to never transmit 2024-10-19 16:06:55 -05:00
ppp ppp: fix ppp_async_encode() illegal access 2024-10-10 08:47:13 -07:00
pse-pd net: pse-pd: Fix out of bound for loop 2024-10-19 15:55:56 -05:00
slip slip: make slhc_remember() more robust against malicious packets 2024-10-10 09:06:32 -07:00
team team: Fix feature propagation of NETIF_F_GSO_ENCAP_ALL 2024-12-12 11:59:18 +01:00
thunderbolt
usb net: usb: qmi_wwan: add Telit FE910C04 compositions 2024-12-11 20:21:42 -08:00
vmxnet3 Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2024-10-21 09:14:18 +02:00
vxlan ndo_fdb_del: Add a parameter to report whether notification was sent 2024-11-15 16:39:18 -08:00
wan net: Switch back to struct platform_driver::remove() 2024-10-04 16:39:57 -07:00
wireguard wireguard: device: support big tcp GSO 2024-11-18 19:32:27 -08:00
wireless A small set of fixes: 2024-12-10 18:44:25 -08:00
wwan net: wwan: t7xx: Change PM_AUTOSUSPEND_MS to 5000 2024-11-18 18:38:20 -08:00
xen-netback
amt.c net: convert to nla_get_*_default() 2024-11-11 10:32:06 -08:00
bareudp.c bareudp: Use pcpu stats to update rx_dropped counter. 2024-10-28 11:16:32 +00:00
dummy.c rtnetlink: Remove __rtnl_link_register() 2024-11-11 17:26:51 -08:00
eql.c
geneve.c geneve: do not assume mac header is set in geneve_xmit_skb() 2024-12-04 19:21:47 -08:00
gtp.c net: convert to nla_get_*_default() 2024-11-11 10:32:06 -08:00
ifb.c rtnetlink: Remove __rtnl_link_register() 2024-11-11 17:26:51 -08:00
Kconfig testing: net-drv: add basic shaper test 2024-10-10 08:30:23 -07:00
LICENSE.SRC
loopback.c
macsec.c macsec: inherit lower device's TSO limits when offloading 2024-11-11 14:12:21 -08:00
macvlan.c ndo_fdb_del: Add a parameter to report whether notification was sent 2024-11-15 16:39:18 -08:00
macvtap.c
Makefile
mdio.c mdio: Remove mdio45_ethtool_gset_npage() 2024-11-14 19:08:55 -08:00
mhi_net.c
mii.c
net_failover.c
netconsole.c net: netconsole: split send_msg_fragmented 2024-10-22 15:44:25 +02:00
netkit.c rtnetlink: fix double call of rtnl_link_get_net_ifla() 2024-12-03 11:29:29 +01:00
nlmon.c
ntb_netdev.c
pfcp.c
rionet.c
sb1000.c
Space.c
sungem_phy.c
tap.c [tree-wide] finally take no_llseek out 2024-09-27 08:18:43 -07:00
tun.c appletalk: Remove deadcode 2024-10-04 12:42:32 +01:00
veth.c rtnetlink: fix double call of rtnl_link_get_net_ifla() 2024-12-03 11:29:29 +01:00
virtio_net.c virtio_net: ensure netdev_tx_reset_queue is called on bind xsk for tx 2024-12-10 11:22:21 +01:00
vrf.c vrf: Prepare vrf_process_v4_outbound() to future .flowi4_tos conversion. 2024-11-03 14:29:05 -08:00
vsockmon.c
xen-netfront.c