[Intel-wired-lan] [PATCH net] ice: Respond to a NETDEV_UNREGISTER event for LAG

Dave Ertman david.m.ertman at intel.com
Tue Oct 5 14:30:03 UTC 2021


When the PF is a member of a link aggregate, and the driver
is removed, the process will hang unless we respond to the
NETDEV_UNREGISTER event that is sent to the event_handler
for LAG.

Add a case statement for the ice_lag_event_handler to unlink
the PF from the link aggregate.

Fixes: df006dd4b1dca ("Add initial support framework for LAG")
Signed-off-by: Dave Ertman <david.m.ertman at intel.com>
---
 drivers/net/ethernet/intel/ice/ice_lag.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/net/ethernet/intel/ice/ice_lag.c b/drivers/net/ethernet/intel/ice/ice_lag.c
index 37c18c66b5c7..1631f8995d3d 100644
--- a/drivers/net/ethernet/intel/ice/ice_lag.c
+++ b/drivers/net/ethernet/intel/ice/ice_lag.c
@@ -319,6 +319,9 @@ ice_lag_event_handler(struct notifier_block *notif_blk, unsigned long event,
 	case NETDEV_BONDING_INFO:
 		ice_lag_info_event(lag, ptr);
 		break;
+	case NETDEV_UNREGISTER:
+		ice_lag_unlink(lag, ptr);
+		break;
 	default:
 		break;
 	}
-- 
2.31.1



More information about the Intel-wired-lan mailing list