ONS: Consolidate ONS work to a single Worker thread
Summary:
1. ONS creates its worker thread via HandlerThread now
2. ONSProfileSelector and ONSNetworkScanCtlr now use the ONS Looper and thread instead of their own
3. Most IOns methods post work to the worker thread
4. Lock acquisition for remaining protected state is consolidated to the relevant helper functions
5. FlaggedLock is introduced to provide clarity on the conditions in which locks should be acquired
Bug: 240081918
Test: atest ONSTests
Flag: com.android.internal.telephony.flags.ons_thread_consolidation
Change-Id: Ic0c3644ca8469b4aed22fd8ba55034bf8d0f97f5
8 files changed