net/ice/base: check root pointer for validity
authorQi Zhang <qi.z.zhang@intel.com>
Thu, 29 Aug 2019 02:36:13 +0000 (10:36 +0800)
committerFerruh Yigit <ferruh.yigit@intel.com>
Mon, 7 Oct 2019 13:00:53 +0000 (15:00 +0200)
commita823afa55ff40b9b1d7792d9a5763195ef938396
treef674ec32c4adcfc5ca46c7cb07a06ea31c5f8b48
parent348ea028ea9fd9873c40d776035a76447aa666b1
net/ice/base: check root pointer for validity

ice_sched_get_tc_node uses pi->root without checking for NULL. Add a
check to prevent NULL pointer dereference.

Signed-off-by: Anirudh Venkataramanan <anirudh.venkataramanan@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: Xiaolong Ye <xiaolong.ye@intel.com>
drivers/net/ice/base/ice_sched.c