diff options
author | Guvenc Gulce <guvenc@linux.ibm.com> | 2020-12-01 20:20:40 +0100 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2020-12-02 02:56:12 +0100 |
commit | 3d453f53c786ac4f1c97022f4bc0e9d7613a05c3 (patch) | |
tree | 1e09ea9a98afc639fd62b67f4c411c655c755366 /net/smc/smc_pnet.c | |
parent | net/smc: Add link counters for IB device ports (diff) | |
download | linux-3d453f53c786ac4f1c97022f4bc0e9d7613a05c3.tar.xz linux-3d453f53c786ac4f1c97022f4bc0e9d7613a05c3.zip |
net/smc: Add diagnostic information to smc ib-device
During smc ib-device creation, add network device ifindex to smc
ib-device structure. Register for netdevice changes and update ib-device
accordingly. This is needed for diagnostic purposes.
Signed-off-by: Guvenc Gulce <guvenc@linux.ibm.com>
Signed-off-by: Karsten Graul <kgraul@linux.ibm.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'net/smc/smc_pnet.c')
-rw-r--r-- | net/smc/smc_pnet.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/net/smc/smc_pnet.c b/net/smc/smc_pnet.c index f3c18b991d35..6f6d33edb135 100644 --- a/net/smc/smc_pnet.c +++ b/net/smc/smc_pnet.c @@ -827,9 +827,11 @@ static int smc_pnet_netdev_event(struct notifier_block *this, case NETDEV_REBOOT: case NETDEV_UNREGISTER: smc_pnet_remove_by_ndev(event_dev); + smc_ib_ndev_change(event_dev, event); return NOTIFY_OK; case NETDEV_REGISTER: smc_pnet_add_by_ndev(event_dev); + smc_ib_ndev_change(event_dev, event); return NOTIFY_OK; case NETDEV_UP: smc_pnet_add_base_pnetid(net, event_dev, ndev_pnetid); |