@@ -543,7 +543,7 @@ static tBTM_PM_MODE btm_pm_get_set_mode(UINT8 pm_id, tBTM_PM_MCB *p_cb, tBTM_PM_
543543** Function btm_pm_snd_md_req
544544** Description get the resulting mode and send the resuest to host controller
545545** Returns tBTM_STATUS
546- **, BOOLEAN *p_chg_ind
546+ **
547547*******************************************************************************/
548548static tBTM_STATUS btm_pm_snd_md_req (UINT8 pm_id , UINT16 link_hdl , tBTM_PM_PWR_MD * p_mode )
549549{
@@ -565,6 +565,8 @@ static tBTM_STATUS btm_pm_snd_md_req(UINT8 pm_id, UINT16 link_hdl, tBTM_PM_PWR_M
565565 /* already in the resulting mode */
566566 if ( (mode == BTM_PM_MD_ACTIVE ) ||
567567 ((md_res .max >= p_cb -> interval ) && (md_res .min <= p_cb -> interval )) ) {
568+ // Clear request change indication because already in result mode
569+ p_cb -> chg_ind = FALSE;
568570 return BTM_CMD_STORED ;
569571 }
570572 /* Otherwise, needs to wake, then sleep */
@@ -689,7 +691,7 @@ static void btm_pm_check_stored(void)
689691** Description This function is called when an HCI command status event occurs
690692** for power manager related commands.
691693**
692- ** Input Parms status - status of the event (HCI_SUCCESS if no errors)
694+ ** Input Params status - status of the event (HCI_SUCCESS if no errors)
693695**
694696** Returns none.
695697**
@@ -717,7 +719,7 @@ void btm_pm_proc_cmd_status(UINT8 status)
717719#if BTM_PM_DEBUG == TRUE
718720 BTM_TRACE_DEBUG ( "btm_pm_proc_cmd_status new state:0x%x" , p_cb -> state );
719721#endif // BTM_PM_DEBUG
720- } else { /* the command was not successfull . Stay in the same state */
722+ } else { /* the command was not successful . Stay in the same state */
721723 pm_status = BTM_PM_STS_ERROR ;
722724 }
723725
@@ -743,7 +745,7 @@ void btm_pm_proc_cmd_status(UINT8 status)
743745**
744746** Description This function is called when an HCI mode change event occurs.
745747**
746- ** Input Parms hci_status - status of the event (HCI_SUCCESS if no errors)
748+ ** Input Params hci_status - status of the event (HCI_SUCCESS if no errors)
747749** hci_handle - connection handle associated with the change
748750** mode - HCI_MODE_ACTIVE, HCI_MODE_HOLD, HCI_MODE_SNIFF, or HCI_MODE_PARK
749751** interval - number of baseband slots (meaning depends on mode)
0 commit comments