ice: Don't tx before switchdev is fully configured
authorWojciech Drewek <wojciech.drewek@intel.com>
Wed, 12 Jul 2023 11:03:28 +0000 (13:03 +0200)
committerTony Nguyen <anthony.l.nguyen@intel.com>
Mon, 24 Jul 2023 15:52:43 +0000 (08:52 -0700)
commit7aa529a69e92b9aff585e569d5003f7c15d8d60b
treecb44ff3a3ba3a6f57a808f2d654dc26650802985
parent2571a3fa6251662e5201372f889bf93f234c8261
ice: Don't tx before switchdev is fully configured

There is possibility that ice_eswitch_port_start_xmit might be
called while some resources are still not allocated which might
cause NULL pointer dereference. Fix this by checking if switchdev
configuration was finished.

Reviewed-by: Paul Menzel <pmenzel@molgen.mpg.de>
Reviewed-by: Simon Horman <simon.horman@corigine.com>
Signed-off-by: Wojciech Drewek <wojciech.drewek@intel.com>
Tested-by: Sujai Buvaneswaran <sujai.buvaneswaran@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
drivers/net/ethernet/intel/ice/ice_eswitch.c