mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-11 23:24:22 -04:00
qcacmn: Update wmi ready to false when the legacy cb returns error
Presently even when the ready event legacy callback fails in creation of the pdev, the error is not propagated correctly. This can result in accessing the invalid memory. Check the legacy cb return status and update wmi ready status to false in case pdev creation fails. Change-Id: Ia4f94154357debedc94b4b20e789bff80a4047f7 CRs-Fixed: 2426611
This commit is contained in:
parent
5a4530f824
commit
65b02b4a8e
1 changed files with 7 additions and 2 deletions
|
|
@ -441,8 +441,12 @@ static int init_deinit_ready_event_handler(ol_scn_t scn_handle,
|
|||
|
||||
legacy_callback = target_if_get_psoc_legacy_service_ready_cb();
|
||||
if (legacy_callback)
|
||||
legacy_callback(wmi_ready_event_id,
|
||||
scn_handle, event, data_len);
|
||||
if (legacy_callback(wmi_ready_event_id,
|
||||
scn_handle, event, data_len)) {
|
||||
target_if_err("Legacy callback returned error!");
|
||||
tgt_hdl->info.wmi_ready = FALSE;
|
||||
goto exit;
|
||||
}
|
||||
|
||||
num_radios = target_psoc_get_num_radios(tgt_hdl);
|
||||
/*
|
||||
|
|
@ -502,6 +506,7 @@ static int init_deinit_ready_event_handler(ol_scn_t scn_handle,
|
|||
out:
|
||||
target_if_btcoex_cfg_enable(psoc, tgt_hdl, event);
|
||||
tgt_hdl->info.wmi_ready = TRUE;
|
||||
exit:
|
||||
init_deinit_wakeup_host_wait(psoc, tgt_hdl);
|
||||
|
||||
return 0;
|
||||
|
|
|
|||
Loading…
Reference in a new issue