Don't check MAINLINE_NETWORK_STACK permission for network stack

Checking permissions requires a binder IPC to the system server.
There is cross process dead lock due to binder thread exhaustion.
1. Nework stack fired a IPC to netd.
2. Netd reqired binder IPC to check permission but no free binder
thread.
3. System server is waiting the resulting call in netd.

Fix this by not checking mainline_network_stack permission if the
caller is network stack.

Bug: 149766727
Test: ON/OFF hotspot

Change-Id: I8af7d4d2ff31b7a1ab4aa56070eecf893ace81d4
Merged-In: I8af7d4d2ff31b7a1ab4aa56070eecf893ace81d4
Merged-In: I9715fa0cb7c1157d134279717222dadedf0268c5
(cherry picked from commit 6eb4fb43cff2e55eb61712b08335f0a5f42b1990)
1 file changed