mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-08-30 19:13:03 -04:00
mlxsw: Convert to async version of ndo_set_rx_mode
Commitc5b9b518ad("mlxsw: spectrum: Add set_rx_mode ndo stub") added a stub for ndo_set_rx_mode to prevent dev_ifsioc() from returning an error for the SIOCADDMULTI and SIOCDELMULTI cases. Since then dev_ifsioc() was taught to also accept ndo_set_rx_mode_async and commit3cbd229388("net: warn ops-locked drivers still using ndo_set_rx_mode") modified register_netdevice() to warn when registering an ops-locked net device that still uses ndo_set_rx_mode instead of ndo_set_rx_mode_async. In preparation for converting the driver to be ops-locked, convert the ndo_set_rx_mode stub to a ndo_set_rx_mode_async stub. Reviewed-by: Danielle Ratson <danieller@nvidia.com> Signed-off-by: Ido Schimmel <idosch@nvidia.com> Link: https://patch.msgid.link/20260708123933.1303291-2-idosch@nvidia.com Signed-off-by: Paolo Abeni <pabeni@redhat.com>
This commit is contained in:
committed by
Paolo Abeni
parent
c1e8a25716
commit
a5faaa079c
@@ -663,8 +663,11 @@ static netdev_tx_t mlxsw_sp_port_xmit(struct sk_buff *skb,
|
||||
return NETDEV_TX_OK;
|
||||
}
|
||||
|
||||
static void mlxsw_sp_set_rx_mode(struct net_device *dev)
|
||||
static int mlxsw_sp_set_rx_mode_async(struct net_device *dev,
|
||||
struct netdev_hw_addr_list *uc,
|
||||
struct netdev_hw_addr_list *mc)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int mlxsw_sp_port_set_mac_address(struct net_device *dev, void *p)
|
||||
@@ -1191,7 +1194,7 @@ static const struct net_device_ops mlxsw_sp_port_netdev_ops = {
|
||||
.ndo_stop = mlxsw_sp_port_stop,
|
||||
.ndo_start_xmit = mlxsw_sp_port_xmit,
|
||||
.ndo_setup_tc = mlxsw_sp_setup_tc,
|
||||
.ndo_set_rx_mode = mlxsw_sp_set_rx_mode,
|
||||
.ndo_set_rx_mode_async = mlxsw_sp_set_rx_mode_async,
|
||||
.ndo_set_mac_address = mlxsw_sp_port_set_mac_address,
|
||||
.ndo_change_mtu = mlxsw_sp_port_change_mtu,
|
||||
.ndo_get_stats64 = mlxsw_sp_port_get_stats64,
|
||||
|
||||
Reference in New Issue
Block a user