qcacmn: Check for pdev/psoc before requesting serialization psoc object
The serialization vdev destroy handlers extracts the psoc from the vdev, and get its psoc component object. If the pdev or psoc is NULL for some reason, we get a crash in object manager while trying to retrieve the serialization psoc object. So check for valid pdev/psoc before we get the serialization psoc object. Change-Id: I9ca45654250403a8b5fe674431251defd1aac6e8 CRs-Fixed: 2524231
Esse commit está contido em:
@@ -158,10 +158,28 @@ QDF_STATUS wlan_serialization_cleanup_vdev_timers(
|
||||
struct wlan_serialization_timer *ser_timer;
|
||||
QDF_STATUS status = QDF_STATUS_SUCCESS;
|
||||
uint32_t i = 0;
|
||||
struct wlan_objmgr_pdev *pdev = NULL;
|
||||
struct wlan_objmgr_psoc *psoc = NULL;
|
||||
|
||||
ser_enter();
|
||||
psoc_ser_obj = wlan_serialization_get_psoc_obj(
|
||||
wlan_vdev_get_psoc(vdev));
|
||||
|
||||
pdev = wlan_vdev_get_pdev(vdev);
|
||||
if (!pdev) {
|
||||
QDF_BUG(0);
|
||||
ser_err("pdev is null");
|
||||
status = QDF_STATUS_E_FAILURE;
|
||||
goto error;
|
||||
}
|
||||
|
||||
psoc = wlan_pdev_get_psoc(pdev);
|
||||
if (!psoc) {
|
||||
QDF_BUG(0);
|
||||
ser_err("psoc is null");
|
||||
status = QDF_STATUS_E_FAILURE;
|
||||
goto error;
|
||||
}
|
||||
|
||||
psoc_ser_obj = wlan_serialization_get_psoc_obj(psoc);
|
||||
|
||||
if (!psoc_ser_obj) {
|
||||
ser_err("Invalid psoc_ser_obj");
|
||||
|
Referência em uma nova issue
Block a user