]> git.baikalelectronics.ru Git - kernel.git/commit
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)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 23 Sep 2023 09:11:01 +0000 (11:11 +0200)
commit5760a72b3060150b587eff3e879648c7470efddd
tree8ef888b140c7c0fbe9dbbad27eddbe66e95f707e
parentad58d7ebbf936c3e9730cc3164af9753b276851c
ice: Don't tx before switchdev is fully configured

[ Upstream commit 7aa529a69e92b9aff585e569d5003f7c15d8d60b ]

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>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/intel/ice/ice_eswitch.c