• Ivan Vecera's avatar
    i40e: Fix devlink port unregistering · aa54d846
    Ivan Vecera authored
    Ensure that devlink port is unregistered after unregistering
    of net device.
    
    Reproducer:
    [root@host ~]# rmmod i40e
    [ 4742.939386] i40e 0000:02:00.1: i40e_ptp_stop: removed PHC on enp2s0f1np1
    [ 4743.059269] ------------[ cut here ]------------
    [ 4743.063900] WARNING: CPU: 21 PID: 10766 at net/devlink/port.c:1078 devl_port_unregister+0x69/0x80
    ...
    
    Fixes: 9e479d64 ("i40e: Add initial devlink support")
    Signed-off-by: default avatarIvan Vecera <ivecera@redhat.com>
    Reviewed-by: default avatarJiri Pirko <jiri@nvidia.com>
    Tested-by: Pucha Himasekhar Reddy <himasekharx.reddy.pucha@intel.com> (A Contingent worker at Intel)
    Signed-off-by: default avatarTony Nguyen <anthony.l.nguyen@intel.com>
    aa54d846
i40e_main.c 463 KB