net/ice/base: remove null check of port info
authorQi Zhang <qi.z.zhang@intel.com>
Mon, 23 Sep 2019 07:44:25 +0000 (15:44 +0800)
committerFerruh Yigit <ferruh.yigit@intel.com>
Mon, 7 Oct 2019 13:00:56 +0000 (15:00 +0200)
commitcfaeec82d2da2b4ba2a5dc793da168e784430e90
tree370a1195e2850e6436aa9e506422a8a72127aae6
parentbb8851a31d76f6b5a74fb232a7a2e218d12d42ec
net/ice/base: remove null check of port info

The code in ice_sched_cleanup_all checks whether the port info is NULL
prior to calling ice_sched_clear_port.

More importantly, it also checks whether the port structure has been
initialized by checking its port_state field as well.

Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Signed-off-by: Paul M Stillwell Jr <paul.m.stillwell.jr@intel.com>
Signed-off-by: Qi Zhang <qi.z.zhang@intel.com>
Acked-by: Qiming Yang <qiming.yang@intel.com>
drivers/net/ice/base/ice_sched.c