aboutsummaryrefslogtreecommitdiff
path: root/net/unix/af_unix.c
diff options
context:
space:
mode:
authorPetr Machata <petrm@nvidia.com>2023-06-09 19:32:09 +0200
committerDavid S. Miller <davem@davemloft.net>2023-06-12 09:49:30 +0100
commit14304e70634cb03913ec11b7f418df752d9ee3f8 (patch)
treeed1a67698c58095a904c7265b3d27c54926661a4 /net/unix/af_unix.c
parent48dde35ea157b4b17bcccb8cd6fed3dfd9627a7a (diff)
downloadlinux-14304e70634cb03913ec11b7f418df752d9ee3f8.tar.gz
linux-14304e70634cb03913ec11b7f418df752d9ee3f8.tar.bz2
linux-14304e70634cb03913ec11b7f418df752d9ee3f8.zip
mlxsw: spectrum_router: Use the available router pointer for netevent handling
This code handles NETEVENT_DELAY_PROBE_TIME_UPDATE, which is invoked every time the delay_probe_time changes. mlxsw router currently only maintains one timer, so the last delay_probe_time set wins. Currently, mlxsw uses mlxsw_sp_port_lower_dev_hold() to find a reference to the router. This is no longer necessary. But as a side effect, this makes sure that only updates to "interesting netdevices" (ones that have a physical netdevice lower) are projected. Retain that side effect by calling mlxsw_sp_port_dev_lower_find_rcu() and punting if there is none. Then just proceed using the router pointer that's already at hand in the helper. Note that previously, the code took and put a reference of the netdevice. Because the mlxsw_sp pointer is now obtained from the notifier block, the port pointer (non-) NULL-ness is all that's relevant, and the reference does not need to be taken anymore. Signed-off-by: Petr Machata <petrm@nvidia.com> Reviewed-by: Amit Cohen <amcohen@nvidia.com> Reviewed-by: Simon Horman <simon.horman@corigine.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/unix/af_unix.c')
0 files changed, 0 insertions, 0 deletions