Commit Graph

7 Commits

Author SHA1 Message Date
Rambo Wang
5ac9d9c8fa Fix Settings restart during Reset mobile nework settings flow
This CL avoids restarting Settings in the reset mobile flow when phone
process is restarted, by switching the usage of the stable content
provider connection to the unstable client.

The CL also arranges restarting phone process as the last reset
operation in the flow (later than RILD reset) to avoid any reset
operation get impacted by phone process restarting.

Since the permission to protect the TelephonyContentProvider has been
renamed, the CL also renames the requsted permision.

Bug: 347047105
Test: atest ResetNetworkOperationBuilderTest
Test: Reset mobile network feature test
Flag: EXEMPT resource update with minor refactoring
Change-Id: I7bfa79bc9d7451a4a03269704b0009a3730e287f
2024-06-19 14:41:19 +00:00
Rambo Wang
98920c3714 eSIM profile is not erased during Reset mobile network settings flow
The CL fixes the bug that eSIM profile is not erased even if user
choose to erase eSIM during Reset Mobile Network Settings flow.

The issue was introduced when adding background operations to
restart Phone process and RILD. Restart Phone process performed earlier.
It may interrup the previous reset operations (e.g. eSIM erasing).

The fix here is to arrange reset Phone and RILD in the end of the flow,
only performed after all other reset operations.

Bug: 345854350
Test: atest ResetNetworkOperationBuilderTest
Test: Manual regression test
Change-Id: If2bd492d417a07a7056bf9fd0d051f8811ba6369
2024-06-11 18:18:15 +00:00
Chaohui Wang
446e0a18d1 Refresh the preferred APN after "Reset to default"
Previously, ApnSettings will updated the preferred APN selection when
data connection changes, but this is not the source of truth.

Observe the preferred APN directly to fix.

Fix: 257316932
Test: manual - on ApnSettings
Test: unit test
Change-Id: Ie323316ab8f7fa63edf5cf90633bcdd4486728c4
2024-04-25 11:14:21 +08:00
Rambo Wang
4c384506d5 Reset telephony stack during Reset Mobile Network flow
This CL introduces two more steps to restart Phone process and RILD
during the Reset mobile network flow by the help of the
TelephonyContentProvider which has been used by Pixel Adaptive
Connectivity Services ("SCONE") for a while.

The additional reset options can resolve issues like resources leak
and internal state stuck, effectively recover telephony stack into
fresh state.

The reset options are performed in the background and have no impact
on UX of the reset flow.

Bug: 271921464
Test: ResetNetworkOperationBuilderTest
Test: Feature test with both flag on and off
Change-Id: If09d20d79e908dd43f3f654fb7cca7f713b7f03a
2024-01-05 03:53:21 +00:00
rambowang
41ba9dc658 Support reset IMS stack in Reset Mobile Network flow
Reset the IMS stack for the specified subscription
with the help of API TelephonyManager#resetIms.

Bug: 271921464
Test: ResetNetworkOperationBuilderTest
Change-Id: I61575f18bcc300f362000dc7f4257b9d794b6b69
2023-12-22 10:33:46 -06:00
Bonian Chen
c2776e0e67 [Settings] Add some log
Add log to support debugging.

Bug: 259611847
Test: auto test
Change-Id: Ic7ea410604794e3b9caa8ab955e1406578a25425
2022-11-23 12:36:17 +00:00
Bonian Chen
c3028291ed [Settings] Code Refactor
Adjust code structure for maintainance.

Bug: 259611847
Test: auto test
Change-Id: I1fab8d0347f64c01ee768e4bb9ea838a9e7ad4fc
2022-11-19 13:14:07 +00:00