STK: Handle ICC refresh and card removal, and hotswap fix
--- Register for ICC refresh and let CatService's clients know when an ICC refresh occurs. Monitor card status. When card status moves to absent/present let clients know. Don't dispose CatService based on the number of applications. Instead dispose it when UiccCard goes away This helps avoid the race condition in the following scenario: 1. Radio is on and card is present 2. Turn Radio Off 3. Turn Radio On 4. Proactive command received If CatService was disposed when card goes away on radio off then it is possible for the unsol proactive command to be received before Catservice is up and running on radio on. --- Dispose objects properly for hotswap During hotswap, CatService object is disposed and new object is created. However RilMessageDecoder still holds reference to old object of CatService, and hence sends decoded command to old object of CatService leading to stk failure. In this fix below objects are disposed properly when CatService is disposed. 1) RilMessageDecoder 2) CommandParamsFactory 3) IconLoader Change-Id: Iee4ab009a0f9708a1ee2d87460e60765e46b4229
Loading
Please register or sign in to comment