Skip to content
Snippets Groups Projects
Commit 6b6ba00b authored by Kamal Negi's avatar Kamal Negi
Browse files

fm: Set lib_running variable only on cleanup

On SSR, we receive HW_ERR_EVENT,we set lib_running variable to 0.
Because of this, hci tx and monitor thread exits before cleanup or exit
happens, causing RX thread to be blocked on cond_wait and failure
happens.
Hence not setting variable during event read.

Change-Id: I82891e12c83fe5d06dbfec060d1ace1231fc25fd
parent 2cfb9a95
No related branches found
No related tags found
No related merge requests found
...@@ -229,7 +229,6 @@ static int read_fm_event(struct fm_hci_t *hci, struct fm_event_header_t *pbuf, i ...@@ -229,7 +229,6 @@ static int read_fm_event(struct fm_hci_t *hci, struct fm_event_header_t *pbuf, i
pthread_cond_signal(&hci->cmd_credits_cond); pthread_cond_signal(&hci->cmd_credits_cond);
} else if (pbuf->evt_code == FM_HW_ERR_EVENT) { } else if (pbuf->evt_code == FM_HW_ERR_EVENT) {
ALOGI("%s: FM H/w Err Event Recvd. Event Code: 0x%2x", __func__, pbuf->evt_code); ALOGI("%s: FM H/w Err Event Recvd. Event Code: 0x%2x", __func__, pbuf->evt_code);
lib_running =0;
hci->vendor->ssr_cleanup(0x22); hci->vendor->ssr_cleanup(0x22);
status = power(hci, FM_RADIO_DISABLE); status = power(hci, FM_RADIO_DISABLE);
if (status < 0) { if (status < 0) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment