Files
android_kernel_xiaomi_sm8450/drivers/net/ethernet/intel/ice
Krzysztof Goreczny 4686a26e95 ice: prevent ice_open and ice_stop during reset
commit e95fc8573e07c5e4825df4650fd8b8c93fad27a7 upstream.

There is a possibility of race between ice_open or ice_stop calls
performed by OS and reset handling routine both trying to modify VSI
resources. Observed scenarios:
- reset handler deallocates memory in ice_vsi_free_arrays and ice_open
  tries to access it in ice_vsi_cfg_txq leading to driver crash
- reset handler deallocates memory in ice_vsi_free_arrays and ice_close
  tries to access it in ice_down leading to driver crash
- reset handler clears port scheduler topology and sets port state to
  ICE_SCHED_PORT_STATE_INIT leading to ice_ena_vsi_txq fail in ice_open

To prevent this additional checks in ice_open and ice_stop are
introduced to make sure that OS is not allowed to alter VSI config while
reset is in progress.

Fixes: cdedef59de ("ice: Configure VSIs for Tx/Rx")
Signed-off-by: Krzysztof Goreczny <krzysztof.goreczny@intel.com>
Tested-by: Tony Brelinski <tonyx.brelinski@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-04-14 08:41:59 +02:00
..
2020-05-22 22:02:34 -07:00
2020-05-22 22:02:34 -07:00
2020-07-29 08:38:54 -07:00
2020-07-29 08:38:55 -07:00
2020-07-29 08:38:54 -07:00
2019-11-08 12:02:14 -08:00
2020-07-29 08:38:54 -07:00
2021-02-03 23:28:48 +01:00
2020-05-22 21:44:48 -07:00
2020-10-09 13:14:19 -07:00
2020-10-09 13:14:19 -07:00
2020-05-21 22:10:04 -07:00
2020-05-21 22:10:04 -07:00
2020-08-01 08:44:04 -07:00
2020-08-01 08:44:04 -07:00
2018-03-26 09:59:08 -07:00
2020-08-01 08:44:04 -07:00
2020-08-01 08:44:04 -07:00