Telephony: Handle race condition during sim deactivation.
Issue: - config L/W/G + 1x - DDS sim is deactivated. DDS is being auto switched to 1x sub. - Modem/qcril reports 1x subscription in service before QtiDctController gets a chance to processRequests or could request EVENT_CONNECT to DcSwitchStateMachine. - During this window both of the DcSwitchStateMachines are IDLE. - ATTACHED event is handled by 1x DcSwitchStateMachine and it moves from IDLE to ATTACHED state without sending ALLOW_DATA(T) to modem. Solution: - Since the race conditon is due to the fact the both DcSwitchStateMachine are IDLE and ATTACHED event is handled before EVENT_CONNECT. The solution is to defer the ATTACHED event IFF DcSwitchStateMachine is IDLE and belongs to DDS sub also transition to ATTACHING state. - As we enter into ATTACHING state we would send out ALLOW_DATA(T) and the deferred event ATTACHED would be handled in this state which would kick us to ATTACHED state.This way modem and telephony both would be in sync with respect to DDS movement for this usecase. Change-Id: I8c7e0ea4d8a7c919703ef22c5df1b94902ab830c
Loading
Please register or sign in to comment