diff options
| author | Greg Kroah-Hartman <[email protected]> | 2025-05-22 11:21:47 +0000 |
|---|---|---|
| committer | Jakub Kicinski <[email protected]> | 2025-05-28 00:35:25 +0000 |
| commit | e9cb929670a1e98b592b30f03f06e9e20110f318 (patch) | |
| tree | 4035bade65f568139fa8d238f9ecbc5e4321f177 /lib/netdev-notifier-error-inject.c | |
| parent | net: Kconfig NET_DEVMEM selects GENERIC_ALLOCATOR (diff) | |
| download | kernel-e9cb929670a1e98b592b30f03f06e9e20110f318.tar.gz kernel-e9cb929670a1e98b592b30f03f06e9e20110f318.zip | |
net: phy: fix up const issues in to_mdio_device() and to_phy_device()
Both to_mdio_device() and to_phy_device() "throw away" the const pointer
attribute passed to them and return a non-const pointer, which generally
is not a good thing overall. Fix this up by using container_of_const()
which was designed for this very problem.
Cc: Alexander Lobakin <[email protected]>
Cc: Andrew Lunn <[email protected]>
Cc: Heiner Kallweit <[email protected]>
Cc: Russell King <[email protected]>
Fixes: 7eab14de73a8 ("mdio, phy: fix -Wshadow warnings triggered by nested container_of()")
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Link: https://patch.msgid.link/2025052246-conduit-glory-8fc9@gregkh
Signed-off-by: Jakub Kicinski <[email protected]>
Diffstat (limited to 'lib/netdev-notifier-error-inject.c')
0 files changed, 0 insertions, 0 deletions
