OnePlus Two Wifi keeps turning off / don't won't get on - OnePlus 2 Q&A, Help & Troubleshooting

Dear All
Since long i use my op2 only anymore as a navigation system, since i use my P20 - however, thats not the problem.
My Problem is that the Wifi and the following hotspot function is not more working.
Since i am having only less knowledge about android but a generell understanding about linux, thats how i got the debug output of dmesg:
I used this to fetch the log
Code:
dmesg -w | grep -Ev 'healthd|smbchg|mdss' > wifi.log
Output Log
[53402.543651] ------------[ cut here ]------------
[53402.543692] WARNING: at ../../../../../../kernel/oneplus/msm8994/fs/proc/generic.c:345 proc_register+0xb8/0x140()
[53402.543698] proc_dir_entry '/proc/cld' already registered
[53402.543707] CPU: 1 PID: 437 Comm: [email protected] Tainted: G W 3.10.108-perf+ #1
[53402.543712] Hardware name: Qualcomm Technologies, Inc. MSM8994v2.1 MTP (DT)
[53402.543718] Call trace:
[53402.543728] [<ffffffc000088780>] dump_backtrace+0x0/0x290
[53402.543735] [<ffffffc000088b1c>] show_stack+0x14/0x1c
[53402.543745] [<ffffffc000d8873c>] dump_stack+0x20/0x28
[53402.543754] [<ffffffc00009ee08>] warn_slowpath_fmt+0xa4/0x114
[53402.543760] [<ffffffc0001ff9a0>] proc_register+0xb8/0x140
[53402.543766] [<ffffffc0001ffd60>] proc_mkdir+0x40/0x64
[53402.543775] [<ffffffc000a2d3d8>] athdiag_procfs_init+0x30/0xa4
[53402.543784] [<ffffffc000a335b0>] HIF_PCIDeviceProbed+0x1b0/0x548
[53402.543793] [<ffffffc000a372b8>] hif_pci_configure+0x2bc/0x2ec
[53402.543798] [<ffffffc000a378f4>] hif_pci_probe+0x508/0x78c
[53402.543808] [<ffffffc0005c1a1c>] cnss_wlan_register_driver+0x1e0/0x6c0
[53402.543814] [<ffffffc000a37304>] hif_register_driver+0x18/0x20
[53402.543824] [<ffffffc00088f700>] hdd_hif_register_driver+0x38/0x7c
[53402.543830] [<ffffffc00088f830>] hdd_driver_init+0xec/0x214
[53402.543836] [<ffffffc00088fa04>] kickstart_driver+0xac/0xc8
[53402.543842] [<ffffffc00088fac8>] fwpath_changed_handler+0xa8/0xe8
[53402.543851] [<ffffffc0000c2ed0>] param_attr_store+0x5c/0x88
[53402.543857] [<ffffffc0000c2e48>] module_attr_store+0x20/0x34
[53402.543865] [<ffffffc000208a0c>] sysfs_write_file+0xe0/0x160
[53402.543875] [<ffffffc0001a0274>] vfs_write+0xa8/0x1ac
[53402.543881] [<ffffffc0001a0448>] SyS_write+0x44/0x8c
[53402.543886] ---[ end trace 413274e4083bab5e ]---
[53402.555976] HIFDiagReadMem failure (0xf8b008f8)
[53402.556145] ath: hif_pci_configure: Target probe failed.
[53402.556154] ERROR: Target Stalled : Target CPU Intr Cause 0x0
[53402.556187] Reset Device
[53402.558214] hif_pci_probe: HIF PCI Free needs to happen here
[53402.558561] msm_pcie_disable: PCIe: Assert the reset of endpoint of RC1.
[53402.584801] msm_pcie_enable: PCIe: Assert the reset of endpoint of RC1.
[53402.588947] msm_pcie_enable: PCIe RC1 PHY is ready!
[53402.599006] msm_pcie_enable: PCIe: Release the reset of endpoint of RC1.
[53402.625841] msm_pcie_enable: PCIe RC1 link initialized
[53402.626234] hif_pci_probe:, con_mode= 0x0
[53402.626245] PCI device id is 003e :003e
[53402.626266] cnss_wlan_pci 0001:01:00.0: BAR 0: assigned [mem 0xf8a00000-0xf8bfffff 64bit]
[53402.627482] \x0a hif_pci_configure : num_desired MSI set to 0
[53402.627553] \x0a Using PCI Legacy Interrupt
[53402.647857] ------------[ cut here ]------------
[53402.647897] WARNING: at ../../../../../../kernel/oneplus/msm8994/fs/proc/generic.c:345 proc_register+0xb8/0x140()
[53402.647903] proc_dir_entry '/proc/cld' already registered
[53402.647913] CPU: 1 PID: 437 Comm: [email protected] Tainted: G W 3.10.108-perf+ #1
[53402.647919] Hardware name: Qualcomm Technologies, Inc. MSM8994v2.1 MTP (DT)
[53402.647925] Call trace:
[53402.647937] [<ffffffc000088780>] dump_backtrace+0x0/0x290
[53402.647944] [<ffffffc000088b1c>] show_stack+0x14/0x1c
[53402.647955] [<ffffffc000d8873c>] dump_stack+0x20/0x28
[53402.647965] [<ffffffc00009ee08>] warn_slowpath_fmt+0xa4/0x114
[53402.647971] [<ffffffc0001ff9a0>] proc_register+0xb8/0x140
[53402.647978] [<ffffffc0001ffd60>] proc_mkdir+0x40/0x64
[53402.647989] [<ffffffc000a2d3d8>] athdiag_procfs_init+0x30/0xa4
[53402.647999] [<ffffffc000a335b0>] HIF_PCIDeviceProbed+0x1b0/0x548
[53402.648007] [<ffffffc000a372b8>] hif_pci_configure+0x2bc/0x2ec
[53402.648093] [<ffffffc000a378f4>] hif_pci_probe+0x508/0x78c
[53402.648105] [<ffffffc0005c1a1c>] cnss_wlan_register_driver+0x1e0/0x6c0
[53402.648111] [<ffffffc000a37304>] hif_register_driver+0x18/0x20
[53402.648123] [<ffffffc00088f700>] hdd_hif_register_driver+0x38/0x7c
[53402.648129] [<ffffffc00088f830>] hdd_driver_init+0xec/0x214
[53402.648135] [<ffffffc00088fa04>] kickstart_driver+0xac/0xc8
[53402.648142] [<ffffffc00088fac8>] fwpath_changed_handler+0xa8/0xe8
[53402.648151] [<ffffffc0000c2ed0>] param_attr_store+0x5c/0x88
[53402.648157] [<ffffffc0000c2e48>] module_attr_store+0x20/0x34
[53402.648167] [<ffffffc000208a0c>] sysfs_write_file+0xe0/0x160
[53402.648178] [<ffffffc0001a0274>] vfs_write+0xa8/0x1ac
[53402.648185] [<ffffffc0001a0448>] SyS_write+0x44/0x8c
[53402.648190] ---[ end trace 413274e4083bab5f ]---
[53402.660409] HIFDiagReadMem failure (0xf8b008f8)
[53402.660481] ath: hif_pci_configure: Target probe failed.
[53402.660489] ERROR: Target Stalled : Target CPU Intr Cause 0x0
[53402.660546] Reset Device
[53402.662566] hif_pci_probe: HIF PCI Free needs to happen here
[53402.662926] msm_pcie_disable: PCIe: Assert the reset of endpoint of RC1.
[53402.688790] msm_pcie_enable: PCIe: Assert the reset of endpoint of RC1.
[53402.693705] msm_pcie_enable: PCIe RC1 PHY is ready!
[53402.703799] msm_pcie_enable: PCIe: Release the reset of endpoint of RC1.
[53402.730571] msm_pcie_enable: PCIe RC1 link initialized
[53402.730978] hif_pci_probe:, con_mode= 0x0
[53402.730989] PCI device id is 003e :003e
[53402.731012] cnss_wlan_pci 0001:01:00.0: BAR 0: assigned [mem 0xf8a00000-0xf8bfffff 64bit]
[53402.732246] \x0a hif_pci_configure : num_desired MSI set to 0
[53402.732297] \x0a Using PCI Legacy Interrupt
[53402.752899] ------------[ cut here ]------------
[53402.752949] WARNING: at ../../../../../../kernel/oneplus/msm8994/fs/proc/generic.c:345 proc_register+0xb8/0x140()
[53402.752960] proc_dir_entry '/proc/cld' already registered
[53402.752976] CPU: 1 PID: 437 Comm: [email protected] Tainted: G W 3.10.108-perf+ #1
[53402.752986] Hardware name: Qualcomm Technologies, Inc. MSM8994v2.1 MTP (DT)
[53402.752997] Call trace:
[53402.753016] [<ffffffc000088780>] dump_backtrace+0x0/0x290
[53402.753029] [<ffffffc000088b1c>] show_stack+0x14/0x1c
[53402.753046] [<ffffffc000d8873c>] dump_stack+0x20/0x28
[53402.753062] [<ffffffc00009ee08>] warn_slowpath_fmt+0xa4/0x114
[53402.753074] [<ffffffc0001ff9a0>] proc_register+0xb8/0x140
[53402.753086] [<ffffffc0001ffd60>] proc_mkdir+0x40/0x64
[53402.753104] [<ffffffc000a2d3d8>] athdiag_procfs_init+0x30/0xa4
[53402.753120] [<ffffffc000a335b0>] HIF_PCIDeviceProbed+0x1b0/0x548
[53402.753135] [<ffffffc000a372b8>] hif_pci_configure+0x2bc/0x2ec
[53402.753146] [<ffffffc000a378f4>] hif_pci_probe+0x508/0x78c
[53402.753164] [<ffffffc0005c1a1c>] cnss_wlan_register_driver+0x1e0/0x6c0
[53402.753175] [<ffffffc000a37304>] hif_register_driver+0x18/0x20
[53402.753194] [<ffffffc00088f700>] hdd_hif_register_driver+0x38/0x7c
[53402.753206] [<ffffffc00088f830>] hdd_driver_init+0xec/0x214
[53402.753218] [<ffffffc00088fa04>] kickstart_driver+0xac/0xc8
[53402.753230] [<ffffffc00088fac8>] fwpath_changed_handler+0xa8/0xe8
[53402.753246] [<ffffffc0000c2ed0>] param_attr_store+0x5c/0x88
[53402.753258] [<ffffffc0000c2e48>] module_attr_store+0x20/0x34
[53402.753272] [<ffffffc000208a0c>] sysfs_write_file+0xe0/0x160
[53402.753288] [<ffffffc0001a0274>] vfs_write+0xa8/0x1ac
[53402.753300] [<ffffffc0001a0448>] SyS_write+0x44/0x8c
[53402.753309] ---[ end trace 413274e4083bab60 ]---
[53402.765424] HIFDiagReadMem failure (0xf8b008f8)
[53402.765498] ath: hif_pci_configure: Target probe failed.
[53402.765509] ERROR: Target Stalled : Target CPU Intr Cause 0x0
[53402.765558] Reset Device
[53402.767586] hif_pci_probe: HIF PCI Free needs to happen here
[53402.768391] msm_pcie_disable: PCIe: Assert the reset of endpoint of RC1.
[53402.795198] msm_pcie_enable: PCIe: Assert the reset of endpoint of RC1.
[53402.799705] msm_pcie_enable: PCIe RC1 PHY is ready!
[53402.809861] msm_pcie_enable: PCIe: Release the reset of endpoint of RC1.
[53402.836825] msm_pcie_enable: PCIe RC1 link initialized
[53402.837290] hif_pci_probe:, con_mode= 0x0
[53402.837304] PCI device id is 003e :003e
[53402.837330] cnss_wlan_pci 0001:01:00.0: BAR 0: assigned [mem 0xf8a00000-0xf8bfffff 64bit]
[53402.838587] \x0a hif_pci_configure : num_desired MSI set to 0
[53402.838648] \x0a Using PCI Legacy Interrupt
[53402.858948] ------------[ cut here ]------------
Output lspci
00:00.0 Class 0604: 17cb:0300
01:00.0 Class 0280: 168c:003e
But my problem is, i aint know how to fix this has someone fixed the wifi already in generelly under android?

Have you tried to restore/reflash your op2 to stock OOS?

Yes without success

djc82k said:
Yes without success
Click to expand...
Click to collapse
Without success to restore or wifi still not working after restore?

lucyr03 said:
Without success to restore or wifi still not working after restore?
Click to expand...
Click to collapse
Yes i tried a restore but the wifi still not working

djc82k said:
Yes i tried a restore but the wifi still not working
Click to expand...
Click to collapse
https://forums.oneplus.com/threads/...ck-guide-for-a-hard-bricked-oneplus-2.347607/
Try method 2, if it's still not working you either have a corrupted EFS or faulty motherboard.

lucyr03 said:
https://forums.oneplus.com/threads/...ck-guide-for-a-hard-bricked-oneplus-2.347607/
Try method 2, if it's still not working you either have a corrupted EFS or faulty motherboard.
Click to expand...
Click to collapse
Update:
[20190405_16:21:26.449145]@1 type=1400 "NetworkMonitorN"
[20190405_16:21:26.469361]@3 audit: audit_lost=2317 audit_rate_limit=20 audit_backlog_limit=64
[20190405_16:21:26.469381]@3 audit: rate limit exceeded
[20190405_16:21:26.474291]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.474532]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.474609]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.474673]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.474736]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.474796]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.474854]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.474912]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.474970]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.475028]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.475092]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.475157]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.475215]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.475273]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.475335]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.475393]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.475453]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.475511]@0 type=1400 "WifiStateMachin"
[20190405_16:21:26.475569]@0 type=1400 "WifiStateMachin"
[20190405_16:21:26.475632]@0 type=1400 "WifiStateMachin"
[20190405_16:21:26.475694]@0 type=1400 "WifiStateMachin"
[20190405_16:21:26.475754]@0 type=1400 "ConnectivitySer"
[20190405_16:21:26.475834]@0 type=1400 "WifiStateMachin"
[20190405_16:21:26.476223]@0 type=1400 "WifiStateMachin"
[20190405_16:21:26.476293]@0 type=1400 "WifiStateMachin"
[20190405_16:21:26.476351]@0 type=1400 "WifiStateMachin"
[20190405_16:21:26.476408]@0 type=1400 "EthernetService"
[20190405_16:21:26.476865]@0 type=1400 "EthernetService"
[20190405_16:21:26.476989]@0 type=1400 "EthernetService"
[20190405_16:21:26.706368]@3 msm8994_quat_mi2s_snd_shutdown Quaternary MI2S Clock is Disabled
[20190405_16:21:26.706380]@3 msm8994_quat_mi2s_snd_startup: dai name qcom,msm-dai-q6-mi2s-quat.207 ffffffc0d7096010 substream = subdevice #0 stream = 0 bit width =2 sample rate =48000
[20190405_16:21:26.730975]@0 tfa98xx_dsp_system_stable(left): MTP0 1
Stockrom is now live, but wifi still not working
[email protected]:/ # uname -a
Linux localhost 3.10.84-perf+ #1 SMP PREEMPT Sat Jun 4 13:05:25 CST 2016 aarch64

Related

HD-505 smart-tv wifi problem

Hello,
i just got my smart-tv android stick
it's from arena scientific model named HD-505
it's RK3066-cortex-A9 and has SDK-ENG_4.1_HD505_20000101 and Kernel 3.0.8+
i'm not able to enable wifi, and tried allot of applications and the same problem
i also downloaded terminal emulator and tried
svc wifi enable
but i got killed and not working
tried to disable and then enable but not working
I need to know if any have a solution
and also if i can upgrade/reimage it and from where to go the firmware and how to do it
thx for you help
here is the output of logcat
I/Xposed ( 7263): -----------------
I/Xposed ( 7263): Added Xposed (/data/data/de.robv.android.xposed.installer/bin/XposedBridge.jar) to CLASSPATH.
D/AndroidRuntime( 7263):
D/AndroidRuntime( 7263): >>>>>> AndroidRuntime START de.robv.android.xposed.XposedBridge <<<<<<
D/AndroidRuntime( 7263): CheckJNI is ON
I/AndroidRuntime( 7263): JNI options: '-Xjniopts:warnonly'
D/dalvikvm( 7263): Unable to stat classpath element '/system/framework/filterfw.jar'
D/dalvikvm( 7263): Trying to load lib libjavacore.so 0x0
D/dalvikvm( 7263): Added shared lib libjavacore.so 0x0
D/dalvikvm( 7263): Trying to load lib libnativehelper.so 0x0
D/dalvikvm( 7263): Added shared lib libnativehelper.so 0x0
D/Xposed ( 7263): Using structure member offsets for mode WITH_JIT
I/Xposed ( 7263): Found Xposed class 'de/robv/android/xposed/XposedBridge', now initializing
I/Xposed ( 7263): -----------------
I/Xposed ( 7263): Oct 19, 2013 6:28:12 PM UTC
I/Xposed ( 7263): Loading Xposed (for com.android.commands.svc.Svc)...
I/Xposed ( 7263): Loading modules from /data/app/org.tracetool.hackconnectivityservice-1.apk
I/Xposed ( 7263): Loading class org.tracetool.hackconnectivityservice.Mod
D/AndroidRuntime( 7263): Calling main entry com.android.commands.svc.Svc
D/AndroidRuntime( 7263): Shutting down VM
D/WifiService( 265): setWifiEnabled: true pid=7263, uid=0
D/dalvikvm( 7263): GC_CONCURRENT freed 610K, 77% free 978K/4096K, paused 0ms+0ms, total 13ms
D/WifiHW ( 265): Read wifi chip type OK ! wifi_chip_type = RTL8188EU
D/WifiHW ( 265): wifi_load_driver: DRIVER_MODULE_PATH = /system/lib/modules/8188eu.ko, DRIVER_MODULE_ARG =
I/WidgetPrefs( 3393): Loaded widget prefs for 4
W/CommandListener( 80): Failed to retrieve HW addr for wlan0 (No such device)
D/CommandListener( 80): Setting iface cfg
E/WifiStateMachine( 265): Unable to change interface settings: java.lang.IllegalStateException: command '133 interface
setcfg wlan0 0.0.0.0 0 down' failed with '400 133 Failed to set address (No such device)'
E/WifiHW ( 265): Unable to open connection to supplicant on "wlan0": No such file or directory
I/wpa_supplicant( 7295): rfkill: Cannot open RFKILL control device
E/wpa_supplicant( 7295): nl80211: Could not configure driver to use managed mode
E/wpa_supplicant( 7295): Could not read interface wlan0 flags: No such device
E/wpa_supplicant( 7295): wlan0: Failed to initialize driver interface
E/WifiHW ( 265): Supplicant not running, cannot connect
E/WifiHW ( 265): Supplicant not running, cannot connect
E/WifiHW ( 265): Supplicant not running, cannot connect
E/WifiHW ( 265): Supplicant not running, cannot connect
E/WifiHW ( 265): Supplicant not running, cannot connect
E/WifiStateMachine( 265): Failed to setup control channel, restart supplicant
W/CommandListener( 80): Failed to retrieve HW addr for wlan0 (No such device)
D/CommandListener( 80): Setting iface cfg
E/WifiStateMachine( 265): Unable to change interface settings: java.lang.IllegalStateException: command '135 interface
setcfg wlan0 0.0.0.0 0 down' failed with '400 135 Failed to set address (No such device)'
I/wpa_supplicant( 7325): rfkill: Cannot open RFKILL control device
E/wpa_supplicant( 7325): nl80211: Could not configure driver to use managed mode
E/wpa_supplicant( 7325): Could not read interface wlan0 flags: No such device
E/wpa_supplicant( 7325): wlan0: Failed to initialize driver interface
E/WifiHW ( 265): Supplicant not running, cannot connect
E/WifiHW ( 265): Supplicant not running, cannot connect
E/WifiHW ( 265): Supplicant not running, cannot connect
E/WifiHW ( 265): Supplicant not running, cannot connect
E/WifiHW ( 265): Supplicant not running, cannot connect
E/WifiStateMachine( 265): Failed to setup control channel, restart supplicant
W/CommandListener( 80): Failed to retrieve HW addr for wlan0 (No such device)
D/CommandListener( 80): Setting iface cfg
E/WifiStateMachine( 265): Unable to change interface settings: java.lang.IllegalStateException: command '137 interface
setcfg wlan0 0.0.0.0 0 down' failed with '400 137 Failed to set address (No such device)'
I/wpa_supplicant( 7355): rfkill: Cannot open RFKILL control device
E/wpa_supplicant( 7355): nl80211: Could not configure driver to use managed mode
E/wpa_supplicant( 7355): Could not read interface wlan0 flags: No such device
E/wpa_supplicant( 7355): wlan0: Failed to initialize driver interface
E/WifiStateMachine( 265): Failed to start supplicant!
I/WidgetPrefs( 3393): Loaded widget prefs for 4
and the output of dmesg
<4>[ 3659.320483] Realtek 8188EU USB WiFi driver (Powered by Rockchip,Ver 1.10) init.
<6>[ 3659.327835] usbcore: deregistering interface driver rtl8188eu
<6>[ 3970.236599] EXT4-fs (mtdblock8): re-mounted. Opts: (null)
<3>[ 3995.978894] init: untracked pid 6914 exited
<4>[ 4103.728041] Current WiFi chip is RTL8188EU.
<4>[ 4103.773033] =======================================================
<4>[ 4103.779414] ==== Launching Wi-Fi driver! (Powered by Rockchip) ====
<4>[ 4103.790871] =======================================================
<4>[ 4103.797142] Realtek 8188EU USB WiFi driver (Powered by Rockchip,Ver 1.10) init.
<6>[ 4103.806603] usbcore: registered new interface driver rtl8188eu
<3>[ 4242.564293] init: untracked pid 7103 exited
<4>[ 4244.402560] =======================================================
<4>[ 4244.408850] ==== Dislaunching Wi-Fi driver! (Powered by Rockchip) ====
<4>[ 4244.415446] =======================================================
<4>[ 4244.422095] Realtek 8188EU USB WiFi driver (Powered by Rockchip,Ver 1.10) init.
<6>[ 4244.429710] usbcore: deregistering interface driver rtl8188eu
<4>[ 4277.579884] Current WiFi chip is RTL8188EU.
<4>[ 4277.617428] =======================================================
<4>[ 4277.624450] ==== Launching Wi-Fi driver! (Powered by Rockchip) ====
<4>[ 4277.631286] =======================================================
<4>[ 4277.638904] Realtek 8188EU USB WiFi driver (Powered by Rockchip,Ver 1.10) init.
<6>[ 4277.647255] usbcore: registered new interface driver rtl8188eu
<4>[ 4308.063197] =======================================================
<4>[ 4308.069571] ==== Dislaunching Wi-Fi driver! (Powered by Rockchip) ====
<4>[ 4308.076144] =======================================================
<4>[ 4308.082492] Realtek 8188EU USB WiFi driver (Powered by Rockchip,Ver 1.10) init.
<6>[ 4308.089923] usbcore: deregistering interface driver rtl8188eu
<3>[ 4372.112169] init: untracked pid 7303 exited
<6>[ 4377.603039] EXT4-fs (mtdblock8): re-mounted. Opts: (null)
<3>[ 4562.414517] init: untracked pid 7385 exited

setools-android with sepolicy-inject

Introduction
In Android 5.0, SELinux is in enforcing mode and sometimes you (or some root application) need to change SELinux policy. There has been only one tool capable of this at runtime - Chainfire's supolicy (part of SuperSU). But this tool is closed source and closed source root apps are great security risk. So I have fixed and enhanced sepolicy-inject from Joshua Brindle and combined it with setools-android by Dmitry Podgorny (pasis) to make it buildable with Android NDK.
Installation instructions
You must have android-ndk installed. Then run:
Code:
git clone https://github.com/xmikos/setools-android.git
cd setools-android
ndk-build
Now you can copy executables from libs/armeabi directory (sepolicy-inject, sesearch and seinfo) to /system/xbin directory on your device.
Usage
Code:
sepolicy-inject -s <source type> -t <target type> -c <class> -p <perm>[,<perm2>,<perm3>,...] [-P <policy file>] [-o <output file>] [-l|--load]
sepolicy-inject -Z type_to_make_permissive [-P <policy file>] [-o <output file>] [-l|--load]
sepolicy-inject -z type_to_make_nonpermissive [-P <policy file>] [-o <output file>] [-l|--load]
For example if you want to allow vdc to write to pseudo-terminal (so you can see replies from vdc command):
Code:
sepolicy-inject -s vdc -t devpts -c chr_file -p read,write -l
Download
Latest binaries for all architectures
Project on GitHub
XDA:DevDB Information
setools-android with sepolicy-inject, Tool/Utility for all devices (see above for details)
Contributors
Mikos, joshua_brindle, Dmitry Podgorny (pasis)
Source Code: https://github.com/xmikos/setools-android
Version Information
Status: Stable
Current Stable Version: 1.3
Stable Release Date: 2017-08-22
Created 2014-12-19
Last Updated 2017-08-22
Mikos,
hi,
i was wondering if you would go further into depth on the command line options,
specifically can i "piggy-back" supolicy onto sepolicy or can you provide a non-generic example of
how to inject say a static su binary with the proper context [seapp_context,file_context,property_context,service_context]
i would be doing this in a debian arm chroot,
the policy is for samsung galaxy tab 4 8.0 sm-t330nu LP 5.1.1 firmware release.
i'm battling apparently selinux AND knox
my current adventure is outlined here..,
http://forum.xda-developers.com/tab-4/general/sm-lp-5-1-1-supersu-t3160110
i have clone your repo and am downloading either ndk or studio.
thanks
m
moonbutt74 said:
Mikos,
i was wondering if you would go further into depth on the command line options,
specifically can i "piggy-back" supolicy onto sepolicy or can you provide a non-generic example of
how to inject say a static su binary with the proper context [seapp_context,file_context,property_context,service_context]
Click to expand...
Click to collapse
Hello, the syntax is simple, if you want comparison with supolicy, here is one example (taken from my SnooperStopper app):
Code:
supolicy --live 'allow vdc init fifo_file {read write getattr}'
is equivalent to:
Code:
sepolicy-inject -s vdc -t init -c fifo_file -p read,write,getattr -l
Mikos,
thanks i got your toolkit built API 19 armeabi-v7a
seinfo is neat.
okay so i am a bit of a dumb dumb, would be up for jumping in on my thread and helping out.
the problem with supersu seems to be at app_process -> /system/xbin/daemonsu
Code:
F/appproc ( 305): Error changing dalvik-cache ownership : Permission denied
F/libc ( 305): Fatal signal 6 (SIGABRT), code -6 in tid 305 (app_process32_o)
and that's where i'm stuck,
also how do i build these tools fully static if possible ? the deb arm chroot doesn't seem to like them
thanks
m
I have released version 1.1 (with support for allowing multiple SELinux permissions at once). I have also updated binaries (now built for armeabi, armeabi-v7a, mips and x86). You can download them from XDA Developers or GitHub.
moonbutt74 said:
okay so i am a bit of a dumb dumb, would be up for jumping in on my thread and helping out.
the problem with supersu seems to be at app_process -> /system/xbin/daemonsu
Code:
F/appproc ( 305): Error changing dalvik-cache ownership : Permission denied
F/libc ( 305): Fatal signal 6 (SIGABRT), code -6 in tid 305 (app_process32_o)
Click to expand...
Click to collapse
Sorry, I don't know what can be your problem. But have you looked at logcat? You should see exact missing SELinux permissions there...
moonbutt74 said:
also how do i build these tools fully static if possible ? the deb arm chroot doesn't seem to like them
Click to expand...
Click to collapse
These binaries are built static. Or at least static for Android (standard NDK build). Debian in chroot may use different libc or something like that.
Mikos,
hi , thanks again i got sorted on working with the toolkit :good:
i am 33 permissive domains and numerous modified permissions in and still haven't hit on the right one yet, but i'm having fun.
i am guessing file_lnk or a trans permission is what i should be focusing on ?
a quick question, the policy injection is permanent or do i need to script out an init.rc or init.d function ?
i ask because i did an experiment while in recovery with system mounted to restrict/remove a permission/permissive domain and on rebooting to recovery the change stuck, i modified access to sbin and sure enough after rebooting to recovery i could not run the custom utillities i have installed even with root access.
also i can not access allow/neverallow [av rules] rules when using sesearch, is this an intended limitation, or is there some additional code/patching required?
thanks.
m
Nice tool, thanks. Is there a way to inject new source and target types or is it only possible to expand existing contexts?
cloooned said:
Nice tool, thanks. Is there a way to inject new source and target types or is it only possible to expand existing contexts?
Click to expand...
Click to collapse
C,
hi, you can only work with what's in the policy if i'm doing the following correctly
for -s <source type>
Code:
sepolicy-inject -s [COLOR="Red"]hack[/COLOR] -t system -c process -p write -P sepolicy -o sepolicy-UNdead
libsepol.policydb_index_others: security: 1 users, 2 roles, 1331 types, 0 bools
libsepol.policydb_index_others: security: 1 sens, 1024 cats
libsepol.policydb_index_others: security: 86 classes, 15661 rules, 0 cond rules
source type hack does not exist
Could not add rule
same for -t <target type>
Code:
sepolicy-inject -s shell -t [COLOR="Red"]hack[/COLOR] -c process -p write -P sepolicy -o sepolicy-UNdead
"blah blah"
target type hack does not exist
Could not add rule
NOT the same for -c <class> , with class i was looking through external/sepolicy/security_classes to find a valid class not in policy
# More SE-X Windows stuff
class x_resource # userspace
so
Code:
sepolicy-inject -s shell -t system -c [COLOR="Red"]x_resource[/COLOR] -p write -P sepolicy -o sepolicy-UNdead
libsepol.policydb_index_others: security: 1 users, 2 roles, 1331 types, 0 bools
libsepol.policydb_index_others: security: 1 sens, 1024 cats
libsepol.policydb_index_others: security: 86 classes, 15661 rules, 0 cond rules
sesearch -A -c x_resource sepolicy-UNdead
Found 1 semantic av rules:
allow shell system_server : [COLOR="Red"]x_resource[/COLOR] write ;
so, again i am probably doing the first two wrong but i'm having a difficult time finding out what valid entries i can attempt
for <source> and <target> that aren't in the policy. <class> was easier as i figured there would be any x_window stuff.
m
Mikos said:
In Android 5.0, SELinux is in enforcing mode and sometimes you (or some root application) need to change SELinux policy. There has been only one tool capable of this at runtime - Chainfire's supolicy (part of SuperSU). But this tool is closed source and closed source root apps are great security risk. So I have fixed and enhanced sepolicy-inject from Joshua Brindle and combined it with setools-android by Dmitry Podgorny (pasis) to make it buildable with Android NDK.
Click to expand...
Click to collapse
Hi and thank you for the awesome tool!
A little question (probably also a dumb one) - will it work if called for init service, user root group root, default init service context?
Something like
Code:
service humble_sepatcher /system/bin/sh /system/xbin/sepolicy-inject "[ [I]parameters go here I suppose ;)[/I] ]"
user root
group root
class core
oneshot
Usecase:
I want to temporarily switch Selinux to Permissive mode very early in the init sequence (adding early initd to a ROM I don't have sources for)
setenforce and "write /sys/fs/selinux/enforce 0" do not work during init (but after the system boots completely and SUperSu finally does its deed, I can do setenforce 0 and enter permissive mode)
Also, since I am rather lame when it comes to Selinux what would be the best way to go about it ? (I suspect that allowing /system/bin/sh and echo to write to /sys/fs/selinux/enforce might be enough, but so far I can't even think of where to start)
Hello @Mikos,
I was wondering if your tool would get an update to support android 6 and policydb version 30. In the attachment is the error I receive.
I made a modification to sepolicy-inject to add a command (sepolicy-inject -R) to revert all the sepolicy changes. It does this by simply loading the original sepolicy in the ramdisk (/sepolicy) without modifying it.
http://pastebin.com/fKTu3FRC
@pittvandewitt I have uploaded new version 1.2 which does support policydb version 30 (Android 6) and also supports 64-bit architectures (arm64-v8a, mips64, x86_64).
Mikos said:
@pittvandewitt I have uploaded new version 1.2 which does support policydb version 30 (Android 6) and also supports 64-bit architectures (arm64-v8a, mips64, x86_64).
Click to expand...
Click to collapse
This is awesome news! Thank you for your work and also for letting me know
Is there anywhere that explains the usage of the injection tools - specifically how to manipulate the commands to achieve your intent? The instructions are limited and my time with selinux has only just begun and I am having a difficult time getting good search results on making the sepolicy changes I need. I specifically need to create an allowance to let a kernel script run at boot. I currently have a kernel script that gets pushed to the system partition during the flash and runs on boot without superSU installed in marshmallow, but on N-preview it does not run and I get sepolicy denials. If anyone can either give me a few pointers on using this tool, or knows of a good guide somewhere for me to get going - it would be much appreciated. TIA.
delete this somehow plz
Hy, everyone
This tool is musthave for the root\kernel devs, but it is so "unfinished"
I have added a few lines of code to make it powerfull and understand tool.
(#) Usage:
Injecting a rule:
./sepolicy-inject -s <source>[,...] -t <target>[,...] -c <class> -p <perm>[,...] [-N] -P <input> [-o <output>] [-v]
Injecting a rule no-audit (AUDITDENY):
./sepolicy-inject -s <source>[,...] -t <target>[,...] -c <class> -p <perm>[,...] -n [-N] -P <inpit> [-o <output>] [-v]
Change a permissive domain to non-permissive:
./sepolicy-inject -z <type> -P <input> [-o <output>] [-v]
Injecting a permissive domain, create new if missing:
./sepolicy-inject -Z <type> -P <input> [-o <output>] [-v]
Add a type attribute to a domain:
./sepolicy-inject -s <type>[,...] -a <attribute>[,...] -P <input> [-o <output>] [-v]
Remove a type attribute from a domain:
./sepolicy-inject -s <type>[,...] -A <attribute>[,...] -P <input> [-o <output>] [-v]
Add a transition source-->target (class) [new]:
./sepolicy-inject -s <source> -t <target> -c <class> -f <new> -P <input> [-o <output>] [-v]
Test a SELinux type exists:
./sepolicy-inject -e -s <type> -P <input> [-v]
Test a SELinux class exists:
./sepolicy-inject -e -c <class> -P <input> [-v]
Test a SELinux type has attribute:
./sepolicy-inject -e -s <type> -a <attribute> -P <input> [-v]
Test a SELinux type missing attribute:
./sepolicy-inject -e -s <type> -A <attribute> -P <input> [-v]
Use -v for verbose
Use -o for output file, rewriting the input file otherwise
Click to expand...
Click to collapse
This way it can work lke this:
.
/sepolicy-inject -s system_server,system_app,untrusted_app -t logd -c dir -p search,add_name,remove_name,open,read,write,getattr,setattr,relabelfrom,relabelto -P sepolicy
./sepolicy-inject -n -s shell -t kernel -c system -p module_request,ipc_info,syslog_console -N -P sepolicy
./sepolicy-inject -s shell -a system_domain,mlstrustedsubject -P sepolicy
./sepolicy-inject -s shell -A trstdomain_no_access_subject -P sepolicy
Click to expand...
Click to collapse
Attaching the source and precompiled cygwin and android binaries
darkmen said:
Hy, everyone
This tool is musthave for the root\kernel devs, but it is so "unfinished"
I have added a few lines of code to make it powerfull and understand tool.
This way it can work lke this:
.
Attaching the source and precompiled cygwin and android binaries
Click to expand...
Click to collapse
Hi, I'm using CM14.1 right now, I am having issue modifying system files, for examples, I am using FasterGPS to modify /system/etc/gps.conf, but FasterGPS failed to modify that file because of selinux is enforcing, because FasterGPS is working normally if I set set selinux is permissive using command setenforce=0 from root shell...
Can I use this setools-android to add rule(s) to selinux policy to allow some certain apps to modify system files without have to manually set selinux as permissive first?
If I can do that using this tool, how do I do it?
I have logcat from the app with selinux=enforce and selinux=policy to compare:
selinux=enforce
Code:
12-10 20:02:49.309 15389 15389 I FasterGPS: Loading /system/etc/gps.conf...
12-10 20:02:49.336 4598 4598 I MicroDetector: Keeping mic open: false
12-10 20:02:49.336 4598 16532 I DeviceStateChecker: DeviceStateChecker cancelled
12-10 20:02:49.337 4598 16514 I AudioController: internalShutdown
12-10 20:02:49.337 4598 16514 I MicrophoneInputStream: mic_close [email protected]
12-10 20:02:49.337 4598 9769 I MicroRecognitionRunner: Stopping hotword detection.
12-10 20:02:49.341 4598 4598 W SearchService: Abort, client detached.
12-10 20:02:49.353 369 369 I MSM-irqbalance: Decided to move IRQ128 from CPU5 to CPU4
12-10 20:02:49.357 1128 16590 D audio_hw_primary: in_standby: enter: stream (0xf6351f80) usecase(7: audio-record)
12-10 20:02:49.390 1128 16590 D audio_hw_primary: disable_audio_route: reset and update mixer path: audio-record
12-10 20:02:49.391 1128 16590 D hardware_info: hw_info_append_hw_type : device_name = voice-rec-mic
12-10 20:02:49.391 1128 16590 D audio_hw_primary: disable_snd_device: snd_device(66: voice-rec-mic)
12-10 20:02:49.394 1128 16590 D audio_hw_primary: in_set_parameters: enter: kvpairs=routing=0
12-10 20:02:49.397 1981 2106 I ActivityManager: Displayed org.fastergps/.ui.BaseActivity: +189ms
12-10 20:02:49.403 4598 16533 I MicroRecognitionRunner: Detection finished
12-10 20:02:49.406 1128 1326 D audio_hw_primary: adev_close_input_stream: enter:stream_handle(0xf6351f80)
12-10 20:02:49.406 1128 1326 D audio_hw_primary: in_standby: enter: stream (0xf6351f80) usecase(7: audio-record)
12-10 20:02:49.651 372 372 W SurfaceFlinger: couldn't log to binary event log: overflow.
12-10 20:02:49.883 16740 16740 D AndroidRuntime: >>>>>> START com.android.internal.os.RuntimeInit uid 0 <<<<<<
12-10 20:02:49.887 16740 16740 D AndroidRuntime: CheckJNI is OFF
12-10 20:02:49.976 16740 16740 D ICU : No timezone override file found: /data/misc/zoneinfo/current/icu/icu_tzdata.dat
12-10 20:02:49.975 16740 16740 W main : type=1400 audit(0.0:207): avc: denied { write } for name="arm64" dev="mmcblk0p31" ino=278530 scontext=u:r:shell:s0 tcontext=u:object_r:dalvikcache_data_file:s0 tclass=dir permissive=0
12-10 20:02:49.975 16740 16740 W main : type=1400 audit(0.0:208): avc: denied { write } for name="arm64" dev="mmcblk0p31" ino=278530 scontext=u:r:shell:s0 tcontext=u:object_r:dalvikcache_data_file:s0 tclass=dir permissive=0
12-10 20:02:50.025 16740 16740 I Radio-JNI: register_android_hardware_Radio DONE
12-10 20:02:50.042 16740 16740 D AndroidRuntime: Calling main entry com.android.commands.am.Am
12-10 20:02:50.045 16757 16757 W main : type=1400 audit(0.0:209): avc: denied { dac_override } for capability=1 scontext=u:r:shell:s0 tcontext=u:r:shell:s0 tclass=capability permissive=0
12-10 20:02:50.045 16757 16757 W main : type=1400 audit(0.0:210): avc: denied { dac_override } for capability=1 scontext=u:r:shell:s0 tcontext=u:r:shell:s0 tclass=capability permissive=0
12-10 20:02:50.045 16757 16757 W main : type=1400 audit(0.0:211): avc: denied { dac_override } for capability=1 scontext=u:r:shell:s0 tcontext=u:r:shell:s0 tclass=capability permissive=0
12-10 20:02:50.045 16757 16757 W main : type=1400 audit(0.0:212): avc: denied { dac_override } for capability=1 scontext=u:r:shell:s0 tcontext=u:r:shell:s0 tclass=capability permissive=0
12-10 20:02:50.081 16740 16740 D AndroidRuntime: Shutting down VM
12-10 20:02:52.089 1981 1981 W WindowManager: Attempted to remove non-existing token: [email protected]
12-10 20:02:53.159 3698 3698 W InputMethodService: Window size has been changed. This may cause jankiness of resizing window: -1 -> -2
12-10 20:02:53.197 3698 3698 I LatinIME: Starting input. Cursor position = 0,0
12-10 20:02:53.333 379 379 E VM_BMS : failed to set wake_lock rc=-13
12-10 20:02:53.333 379 379 D VM_BMS : New BMS data - Size=56
12-10 20:02:53.333 379 379 D VM_BMS : Start process_bms_data
12-10 20:02:53.337 379 379 D VM_BMS : For batt_temp=338 fcc_mah=4032
12-10 20:02:53.337 379 379 D VM_BMS : For ocv=4196145 batt_temp=338 soc=86
12-10 20:02:53.337 379 379 D VM_BMS : fifo_count=5 acc_count=0
12-10 20:02:53.337 379 379 D VM_BMS : INIT: ocv=4196145 last_ocv=4196145 batt_temp=338 soc=86
12-10 20:02:53.337 379 379 D VM_BMS : For soc=86 batt_temp=338 slope=11600
12-10 20:02:53.337 379 379 D VM_BMS : For soc=86 batt_temp=338 rbatt_sf=92
12-10 20:02:53.337 379 379 D VM_BMS : rbatt_mohm_default=120, rbatt_mohm=110, sf=92 batt_temp=338
12-10 20:02:53.337 379 379 D VM_BMS : For ocv=4195968 batt_temp=338 soc=85
12-10 20:02:53.337 379 379 D VM_BMS : FIFO=0 fifo_avg=4.166385 rbatt=0.120000 slope=1.160000 ibatt=0.247261 ocv=4.195968 soc=85 fcc_ah=4.032000 sample_count=128 sample_interval=70 seq_num=80
12-10 20:02:53.337 379 379 D VM_BMS : For soc=85 batt_temp=338 slope=11600
12-10 20:02:53.337 379 379 D VM_BMS : For soc=85 batt_temp=338 rbatt_sf=93
12-10 20:02:53.337 379 379 D VM_BMS : rbatt_mohm_default=120, rbatt_mohm=111, sf=93 batt_temp=338
12-10 20:02:53.337 379 379 D VM_BMS : For ocv=4195738 batt_temp=338 soc=85
12-10 20:02:53.337 379 379 D VM_BMS : FIFO=1 fifo_avg=4.156925 rbatt=0.121000 slope=1.160000 ibatt=0.321717 ocv=4.195738 soc=85 fcc_ah=4.032000 sample_count=128 sample_interval=70 seq_num=80
12-10 20:02:53.337 379 379 D VM_BMS : For soc=85 batt_temp=338 slope=11600
12-10 20:02:53.337 379 379 D VM_BMS : For soc=85 batt_temp=338 rbatt_sf=93
12-10 20:02:53.338 379 379 D VM_BMS : rbatt_mohm_default=120, rbatt_mohm=111, sf=93 batt_temp=338
12-10 20:02:53.338 379 379 D VM_BMS : For ocv=4195592 batt_temp=338 soc=85
12-10 20:02:53.338 379 379 D VM_BMS : FIFO=2 fifo_avg=4.171121 rbatt=0.121000 slope=1.160000 ibatt=0.202844 ocv=4.195592 soc=85 fcc_ah=4.032000 sample_count=128 sample_interval=70 seq_num=80
12-10 20:02:53.338 379 379 D VM_BMS : For soc=85 batt_temp=338 slope=11600
12-10 20:02:53.338 379 379 D VM_BMS : For soc=85 batt_temp=338 rbatt_sf=93
12-10 20:02:53.338 379 379 D VM_BMS : rbatt_mohm_default=120, rbatt_mohm=111, sf=93 batt_temp=338
12-10 20:02:53.338 379 379 D VM_BMS : For ocv=4195721 batt_temp=338 soc=85
12-10 20:02:53.338 379 379 D VM_BMS : FIFO=3 fifo_avg=4.217594 rbatt=0.121000 slope=1.160000 ibatt=-0.181300 ocv=4.195722 soc=85 fcc_ah=4.032000 sample_count=128 sample_interval=70 seq_num=80
12-10 20:02:53.338 379 379 D VM_BMS : For soc=85 batt_temp=338 slope=11600
12-10 20:02:53.338 379 379 D VM_BMS : For soc=85 batt_temp=338 rbatt_sf=93
12-10 20:02:53.338 379 379 D VM_BMS : rbatt_mohm_default=120, rbatt_mohm=111, sf=93 batt_temp=338
12-10 20:02:53.338 379 379 D VM_BMS : For ocv=4195817 batt_temp=338 soc=85
12-10 20:02:53.338 379 379 D VM_BMS : FIFO=4 fifo_avg=4.211973 rbatt=0.121000 slope=1.160000 ibatt=-0.133918 ocv=4.195817 soc=85 fcc_ah=4.032000 sample_count=128 sample_interval=70 seq_num=80
12-10 20:02:53.338 379 379 I VM_BMS : power_supply_update: ocv_uv=4195817 ibatt=-133918 soc=85 seq_num=80
12-10 20:02:53.338 379 379 D VM_BMS : End process_bms_data
12-10 20:02:53.338 379 379 E VM_BMS : failed to wake_unlock rc=-13
12-10 20:02:53.540 380 498 I ThermalEngine: TM Id 'CHARGING_MONITOR' Sensor 'pop_mem' - alarm raised 1 at 43.0 degC
12-10 20:02:53.540 380 498 E ThermalEngine: Unable to set battery charging mitigation to 1
12-10 20:02:54.353 369 369 I MSM-irqbalance: Decided to move IRQ166 from CPU5 to CPU4
12-10 20:02:54.359 11980 13827 I PlayCommon: [497] com.google.android.play.a.g.e(900): Preparing logs for uploading
12-10 20:02:54.360 11980 13827 I PlayCommon: [497] com.google.android.play.a.g.e(902): No file ready to send
12-10 20:02:54.803 11980 12020 I PlayCommon: [444] com.google.android.play.a.g.e(900): Preparing logs for uploading
12-10 20:02:54.804 11980 12020 I PlayCommon: [444] com.google.android.play.a.g.e(902): No file ready to send
12-10 20:02:55.638 15389 15389 W IInputConnectionWrapper: finishComposingText on inactive InputConnection
12-10 20:02:55.638 15389 15389 W IInputConnectionWrapper: finishComposingText on inactive InputConnection
12-10 20:02:55.639 3698 3698 W InputMethodService: Window size has been changed. This may cause jankiness of resizing window: -1 -> -2
12-10 20:02:55.640 15389 15389 W IInputConnectionWrapper: finishComposingText on inactive InputConnection
12-10 20:02:58.920 1981 4461 W InputMethodManagerService: Window already focused, ignoring focus gain of: [email protected] attribute=null, token = [email protected]
12-10 20:02:59.354 369 369 I MSM-irqbalance: Decided to move IRQ155 from CPU7 to CPU4
12-10 20:03:04.353 369 369 I MSM-irqbalance: Decided to move IRQ215 from CPU7 to CPU6
12-10 20:03:06.102 15389 15389 W InputEventReceiver: Attempted to finish an input event but the input event receiver has already been disposed.
12-10 20:03:06.102 15389 15389 I FasterGPS: Writing gps.conf to private files...
12-10 20:03:06.108 16797 16797 E linker : normalize_path - invalid input: "null", the input path should be absolute
12-10 20:03:06.108 16797 16797 W linker : Warning: unable to normalize "null"
12-10 20:03:06.145 15389 15389 I FasterGPS: Remounting for RW...
12-10 20:03:06.149 16807 16807 E linker : normalize_path - invalid input: "null", the input path should be absolute
12-10 20:03:06.149 16807 16807 W linker : Warning: unable to normalize "null"
12-10 20:03:06.215 15389 15389 W org.fastergps: type=1400 audit(0.0:213): avc: denied { read } for name="RootToolsMounts" dev="mmcblk0p31" ino=565251 scontext=u:r:untrusted_app:s0:c512,c768 tcontext=u:object_r:system_data_file:s0 tclass=file permissive=0
12-10 20:03:06.225 15389 15389 E RootCommands: Exception
12-10 20:03:06.225 15389 15389 E RootCommands: java.io.FileNotFoundException: /data/local/RootToolsMounts (Permission denied)
12-10 20:03:06.225 15389 15389 E RootCommands: at java.io.FileInputStream.open(Native Method)
12-10 20:03:06.225 15389 15389 E RootCommands: at java.io.FileInputStream.<init>(FileInputStream.java:146)
12-10 20:03:06.225 15389 15389 E RootCommands: at java.io.FileInputStream.<init>(FileInputStream.java:99)
12-10 20:03:06.225 15389 15389 E RootCommands: at java.io.FileReader.<init>(FileReader.java:58)
12-10 20:03:06.225 15389 15389 E RootCommands: at org.sufficientlysecure.rootcommands.Remounter.getMounts(Remounter.java:173)
12-10 20:03:06.225 15389 15389 E RootCommands: at org.sufficientlysecure.rootcommands.Remounter.remount(Remounter.java:66)
12-10 20:03:06.225 15389 15389 E RootCommands: at org.sufficientlysecure.rootcommands.Toolbox.remount(Toolbox.java:733)
12-10 20:03:06.225 15389 15389 E RootCommands: at org.fastergps.util.Utils.writeConfig(Utils.java:241)
12-10 20:03:06.225 15389 15389 E RootCommands: at org.fastergps.ui.BaseActivity$2.onPreferenceChange(BaseActivity.java:250)
12-10 20:03:06.225 15389 15389 E RootCommands: at android.preference.Preference.callChangeListener(Preference.java:939)
12-10 20:03:06.225 15389 15389 E RootCommands: at android.preference.ListPreference.onDialogClosed(ListPreference.java:282)
12-10 20:03:06.225 15389 15389 E RootCommands: at android.preference.DialogPreference.onDismiss(DialogPreference.java:402)
12-10 20:03:06.225 15389 15389 E RootCommands: at android.app.Dialog$ListenersHandler.handleMessage(Dialog.java:1343)
12-10 20:03:06.225 15389 15389 E RootCommands: at android.os.Handler.dispatchMessage(Handler.java:102)
12-10 20:03:06.225 15389 15389 E RootCommands: at android.os.Looper.loop(Looper.java:154)
12-10 20:03:06.225 15389 15389 E RootCommands: at android.app.ActivityThread.main(ActivityThread.java:6126)
12-10 20:03:06.225 15389 15389 E RootCommands: at java.lang.reflect.Method.invoke(Native Method)
12-10 20:03:06.225 15389 15389 E RootCommands: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:886)
12-10 20:03:06.225 15389 15389 E RootCommands: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:776)
12-10 20:03:06.225 15389 15389 E FasterGPS: remount failed!
selinux=permissive
Code:
12-10 20:19:13.707 9292 9292 I FasterGPS: Loading /system/etc/gps.conf...
12-10 20:19:13.774 9292 9324 I Adreno : QUALCOMM build : d842ad3, Ia10634f51b
12-10 20:19:13.774 9292 9324 I Adreno : Build Date : 01/04/16
12-10 20:19:13.774 9292 9324 I Adreno : OpenGL ES Shader Compiler Version: XE031.06.00.05
12-10 20:19:13.774 9292 9324 I Adreno : Local Branch : mybranch17585849
12-10 20:19:13.774 9292 9324 I Adreno : Remote Branch : quic/LA.BR.1.2.6_rb1.7
12-10 20:19:13.774 9292 9324 I Adreno : Remote Branch : NONE
12-10 20:19:13.774 9292 9324 I Adreno : Reconstruct Branch : NOTHING
12-10 20:19:13.780 9292 9324 I OpenGLRenderer: Initialized EGL, version 1.4
12-10 20:19:13.780 9292 9324 D OpenGLRenderer: Swap behavior 1
12-10 20:19:13.851 1277 1305 I ActivityManager: Displayed org.fastergps/.ui.BaseActivity: +459ms
12-10 20:19:13.886 371 371 W SurfaceFlinger: couldn't log to binary event log: overflow.
12-10 20:19:13.919 388 511 I ThermalEngine: TM Id 'CHARGING_MONITOR' Sensor 'pop_mem' - alarm raised 2 at 45.0 degC
12-10 20:19:13.920 388 511 E ThermalEngine: Unable to set battery charging mitigation to 2
12-10 20:19:14.273 9322 9322 D AndroidRuntime: >>>>>> START com.android.internal.os.RuntimeInit uid 0 <<<<<<
12-10 20:19:14.277 9322 9322 D AndroidRuntime: CheckJNI is OFF
12-10 20:19:14.422 9322 9322 I main : type=1400 audit(0.0:26): avc: denied { execmem } for scontext=u:r:zygote:s0 tcontext=u:r:zygote:s0 tclass=process permissive=1
12-10 20:19:14.422 9322 9322 I main : type=1400 audit(0.0:27): avc: denied { execute } for path="/dev/ashmem" dev="tmpfs" ino=5858 scontext=u:r:zygote:s0 tcontext=u:object_r:ashmem_device:s0 tclass=chr_file permissive=1
12-10 20:19:14.422 9322 9322 I main : type=1400 audit(0.0:28): avc: denied { execute } for path=2F6465762F6173686D656D2F64616C76696B2D6A69742D636F64652D6361636865202864656C6574656429 dev="tmpfs" ino=85393 scontext=u:r:zygote:s0 tcontext=u:object_r:zygote_tmpfs:s0 tclass=file permissive=1
12-10 20:19:14.448 9322 9322 D ICU : No timezone override file found: /data/misc/zoneinfo/current/icu/icu_tzdata.dat
--------- beginning of crash
12-10 20:19:14.471 9328 9328 F libc : CANNOT LINK EXECUTABLE "/system/bin/dex2oat": "/system/lib64/libsigchain.so" is 64-bit instead of 32-bit
12-10 20:19:14.471 9328 9328 F libc : Fatal signal 6 (SIGABRT), code -6 in tid 9328 (dex2oat)
12-10 20:19:14.478 243 243 W : debuggerd: handling request: pid=9328 uid=0 gid=0 tid=9328
12-10 20:19:14.544 9329 9329 F DEBUG : *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
12-10 20:19:14.544 9329 9329 F DEBUG : CM Version: '14.1-20161210-NIGHTLY-ido'
12-10 20:19:14.544 9329 9329 F DEBUG : Build fingerprint: 'Xiaomi/cm_ido/ido:7.1.1/NMF26O/40801d0bc7:userdebug/test-keys'
12-10 20:19:14.544 9329 9329 F DEBUG : Revision: '0'
12-10 20:19:14.544 9329 9329 F DEBUG : ABI: 'arm'
12-10 20:19:14.545 9329 9329 F DEBUG : pid: 9328, tid: 9328, name: dex2oat >>> /system/bin/dex2oat <<<
12-10 20:19:14.545 9329 9329 F DEBUG : signal 6 (SIGABRT), code -6 (SI_TKILL), fault addr --------
12-10 20:19:14.545 9329 9329 F DEBUG : r0 00000000 r1 00002470 r2 00000006 r3 00000008
12-10 20:19:14.545 9329 9329 F DEBUG : r4 f744258c r5 00000006 r6 f7442534 r7 0000010c
12-10 20:19:14.545 9329 9329 F DEBUG : r8 fff2ea58 r9 00000001 sl fff2ea80 fp f73d0010
12-10 20:19:14.545 9329 9329 F DEBUG : ip 00000002 sp fff2e9f0 lr f7422d5f pc f7423778 cpsr 200f0010
12-10 20:19:14.559 9329 9329 F DEBUG :
12-10 20:19:14.559 9329 9329 F DEBUG : backtrace:
12-10 20:19:14.562 9329 9329 F DEBUG : #00 pc 00046778 /system/bin/linker (__dl_tgkill+12)
12-10 20:19:14.562 9329 9329 F DEBUG : #01 pc 00045d5b /system/bin/linker (__dl_pthread_kill+34)
12-10 20:19:14.562 9329 9329 F DEBUG : #02 pc 0003e0ff /system/bin/linker (__dl_raise+10)
12-10 20:19:14.562 9329 9329 F DEBUG : #03 pc 0003cbbb /system/bin/linker (__dl___libc_android_abort+34)
12-10 20:19:14.562 9329 9329 F DEBUG : #04 pc 0003bb18 /system/bin/linker (__dl_abort+4)
12-10 20:19:14.563 9329 9329 F DEBUG : #05 pc 0003dbfb /system/bin/linker (__dl___libc_fatal+22)
12-10 20:19:14.563 9329 9329 F DEBUG : #06 pc 00009c47 /system/bin/linker (__dl__ZL29__linker_init_post_relocationR19KernelArgumentBlockj+3146)
12-10 20:19:14.563 9329 9329 F DEBUG : #07 pc 00008f67 /system/bin/linker (__dl___linker_init+358)
12-10 20:19:14.563 9329 9329 F DEBUG : #08 pc 000027c0 /system/bin/linker (_start+4)
12-10 20:19:14.604 1277 2062 W NativeCrashListener: Couldn't find ProcessRecord for pid 9328
12-10 20:19:14.607 243 243 W : debuggerd: resuming target 9328
12-10 20:19:14.607 243 243 E : debuggerd: failed to send signal 18 to target: No such process
12-10 20:19:14.614 1277 1302 I BootReceiver: Copying /data/tombstones/tombstone_01 to DropBox (SYSTEM_TOMBSTONE)
12-10 20:19:14.622 9322 9322 W art : Failed execv(/system/bin/dex2oat --runtime-arg -classpath --runtime-arg /system/framework/am.jar --instruction-set=arm64 --instruction-set-features=smp,a53 --runtime-arg -Xrelocate --boot-image=/system/framework/boot.art --runtime-arg -Xms64m --runtime-arg -Xmx512m --instruction-set-variant=cortex-a53 --instruction-set-features=default --no-watch-dog --dex-file=/system/framework/am.jar --oat-fd=11 --oat-location=/data/dalvik-cache/arm64/[email protected]@[email protected] --compiler-filter=speed) because non-0 exit status
12-10 20:19:14.690 9322 9322 I Radio-JNI: register_android_hardware_Radio DONE
12-10 20:19:14.715 9322 9322 D AndroidRuntime: Calling main entry com.android.commands.am.Am
12-10 20:19:14.733 370 370 E SELinux : avc: denied { find } for service=activity pid=9322 uid=0 scontext=u:r:zygote:s0 tcontext=u:object_r:activity_service:s0 tclass=service_manager permissive=1
12-10 20:19:14.734 370 370 E SELinux : avc: denied { find } for service=package pid=9322 uid=0 scontext=u:r:zygote:s0 tcontext=u:object_r:package_service:s0 tclass=service_manager permissive=1
12-10 20:19:14.732 9322 9322 I main : type=1400 audit(0.0:29): avc: denied { call } for scontext=u:r:zygote:s0 tcontext=u:r:system_server:s0 tclass=binder permissive=1
12-10 20:19:14.732 9322 9322 I main : type=1400 audit(0.0:30): avc: denied { transfer } for scontext=u:r:zygote:s0 tcontext=u:r:system_server:s0 tclass=binder permissive=1
12-10 20:19:14.762 3169 3169 I Binder:1277_7: type=1400 audit(0.0:31): avc: denied { call } for scontext=u:r:system_server:s0 tcontext=u:r:zygote:s0 tclass=binder permissive=1
12-10 20:19:14.774 9322 9322 D AndroidRuntime: Shutting down VM
12-10 20:19:16.169 368 368 I MSM-irqbalance: Decided to move IRQ166 from CPU7 to CPU6
12-10 20:19:16.789 1277 1277 W WindowManager: Attempted to remove non-existing token: [email protected]
12-10 20:19:16.979 388 511 I ThermalEngine: TM Id 'CHARGING_MONITOR' Sensor 'pop_mem' - alarm cleared 2 at 43.0 degC
12-10 20:19:16.979 388 511 E ThermalEngine: Unable to set battery charging mitigation to 1
12-10 20:19:18.558 3073 3497 E ctxmgr : [ProducerActiveIntervalImpl]closeActiveInterval: Error: ongoing, trying to close
12-10 20:19:18.593 3073 5394 I PlaceInferenceEngine: [anon] Setup for configuration 105:[]
12-10 20:19:18.593 3073 5394 I PlaceInferenceEngine: [anon] Active modules after start(): 0
12-10 20:19:21.168 368 368 I MSM-irqbalance: Decided to move IRQ155 from CPU7 to CPU6
12-10 20:19:22.869 9292 9292 W InputEventReceiver: Attempted to finish an input event but the input event receiver has already been disposed.
12-10 20:19:22.878 1277 6085 W InputMethodManagerService: Window already focused, ignoring focus gain of: [email protected] attribute=null, token = [email protected]
12-10 20:19:26.168 368 368 I MSM-irqbalance: Decided to move IRQ57 from CPU7 to CPU6
12-10 20:19:27.781 388 513 I ThermalEngine: Mitigation:CLUSTER[1]:1459200 Khz
12-10 20:19:28.486 9292 9292 W InputEventReceiver: Attempted to finish an input event but the input event receiver has already been disposed.
12-10 20:19:28.486 9292 9292 I FasterGPS: Writing gps.conf to private files...
12-10 20:19:28.493 9371 9371 E linker : normalize_path - invalid input: "null", the input path should be absolute
12-10 20:19:28.493 9371 9371 W linker : Warning: unable to normalize "null"
12-10 20:19:28.529 9292 9292 I FasterGPS: Remounting for RW...
12-10 20:19:28.532 9381 9381 E linker : normalize_path - invalid input: "null", the input path should be absolute
12-10 20:19:28.532 9381 9381 W linker : Warning: unable to normalize "null"
12-10 20:19:28.602 9292 9292 I org.fastergps: type=1400 audit(0.0:32): avc: denied { read } for name="RootToolsMounts" dev="mmcblk0p31" ino=565251 scontext=u:r:untrusted_app:s0:c512,c768 tcontext=u:object_r:system_data_file:s0 tclass=file permissive=1
12-10 20:19:28.602 9292 9292 I org.fastergps: type=1400 audit(0.0:33): avc: denied { getattr } for path="/data/local/RootToolsMounts" dev="mmcblk0p31" ino=565251 scontext=u:r:untrusted_app:s0:c512,c768 tcontext=u:object_r:system_data_file:s0 tclass=file permissive=1
12-10 20:19:28.612 9394 9394 E linker : normalize_path - invalid input: "null", the input path should be absolute
12-10 20:19:28.613 9394 9394 W linker : Warning: unable to normalize "null"
12-10 20:19:28.702 388 511 I ThermalEngine: TM Id 'CHARGING_MONITOR' Sensor 'pop_mem' - alarm raised 2 at 45.0 degC
12-10 20:19:28.702 388 511 E ThermalEngine: Unable to set battery charging mitigation to 2
12-10 20:19:28.715 9407 9407 E linker : normalize_path - invalid input: "null", the input path should be absolute
12-10 20:19:28.715 9407 9407 W linker : Warning: unable to normalize "null"
12-10 20:19:28.815 9421 9421 E linker : normalize_path - invalid input: "null", the input path should be absolute
12-10 20:19:28.815 9421 9421 W linker : Warning: unable to normalize "null"
12-10 20:19:29.039 9438 9438 E linker : normalize_path - invalid input: "null", the input path should be absolute
12-10 20:19:29.039 9438 9438 W linker : Warning: unable to normalize "null"
12-10 20:19:29.122 9292 9292 I FasterGPS: Copying gps.conf from private files to system partition...
12-10 20:19:29.124 9378 9378 D AndroidRuntime: >>>>>> START com.android.internal.os.RuntimeInit uid 0 <<<<<<
12-10 20:19:29.128 9378 9378 D AndroidRuntime: CheckJNI is OFF
12-10 20:19:29.161 9292 9292 I FasterGPS: Remounting back to RO...
--------------------- update ---------------------
I try one of your example command I get this error:
Code:
1|ido:/system/xbin # ./sepolicy-inject -e -c untrusted_app -P /sepolicy -v
libsepol.avtab_read_item: more than one specifier
libsepol.avtab_read: failed on entry 100 of 19609
error(s) encountered while parsing configuration
Could not load policy
Failed
Help me please with the rule. I'm having an error when running the APPS.
E dex2oat : Failed to create oat file: /data/dalvik-cache/arm/[email protected]@[email protected][email protected]: Permission denied
E dex2oat : Failed to create oat file: /data/dalvik-cache/arm/[email protected]@[email protected][email protected]: Permission denied
I think "sepolicy-inject" help me.
Andrew.
can u update it to inject into android 7.1.x sepolicy ...

Phone freezing while calling/audio problem?

My phone is freezing while in call, neither I or my caller can hear each other while this happens.
From logcat it looks like some kid of audio problem but I don't know what is the real problem.
Could anyone better than me in logs reading tell me how the fix this or what's causing this?
Code:
D/TelephonyProvider( 3294): subIdString = 1 subId = 1
I/FastMixerState(12846): sMaxFastTracks = 8
D/TelephonyProvider( 3294): subIdString = 1 subId = 1
I/audioserver(12846): ServiceManager: 0xf5c18540
D/vndksupport(12846): Loading /vendor/lib/hw/[email protected] from current namespace instead of sphal namespace.
D/vndksupport(12846): Loading /vendor/lib/hw/[email protected] from current namespace instead of sphal namespace.
I/AudioFlinger(12846): Using default 3000 mSec as standby time.
D/TelephonyProvider( 3294): subIdString = 1 subId = 1
W/APM::ConfigParsingUtils(12846): loadOutput() invalid supported devices
W/APM::ConfigParsingUtils(12846): loadInput() invalid supported devices
W/APM::ConfigParsingUtils(12846): loadInput() invalid supported devices
I/APM::ConfigParsingUtils(12846): loadAudioPolicyConfig() loaded /system/etc/audio_policy.conf
W/audio_hw_primary(12846): mixer_init: Failed to open mixer paths from /vendor/etc/mixer_paths_0.xml, retrying with legacy location
E/audio_route(12846): Control 'HPL Mixer ADCL Switch' doesn't exist - skipping
E/audio_route(12846): Control 'HPL Mixer ADCR Switch' doesn't exist - skipping
E/audio_route(12846): Control 'HPR Mixer ADCL Switch' doesn't exist - skipping
E/audio_route(12846): Control 'HPR Mixer ADCR Switch' doesn't exist - skipping
E/audio_route(12846): Control 'EP Mixer ADCL Switch' doesn't exist - skipping
E/audio_route(12846): Control 'EP Mixer ADCR Switch' doesn't exist - skipping
E/audio_route(12846): Control 'SPK Mixer ADCL Switch' doesn't exist - skipping
E/audio_route(12846): Control 'SPK Mixer ADCR Switch' doesn't exist - skipping
E/audio_route(12846): Control 'SPK Mixer ADCL Switch' doesn't exist - skipping
E/audio_route(12846): Control 'SPK Mixer ADCR Switch' doesn't exist - skipping
E/audio_route(12846): Control 'HPL Mixer ADCL Switch' doesn't exist - skipping
E/audio_route(12846): Control 'HPR Mixer ADCR Switch' doesn't exist - skipping
D/TelephonyProvider( 3294): subIdString = 1 subId = 1
E/audio_route(12846): Control 'EP EP On' already exists in path 'fm_radio-speaker-headset'
D/TelephonyProvider( 3294): subIdString = 1 subId = 1
V/audio_hw_voice(12846): voice_session_init: Forcing voice config: wide
E/audio_hw_primary(12846): Amplifier initialization failed
W/DeviceHAL(12846): Device 0xf5c3c400 get_master_volume: Function not implemented
W/DeviceHAL(12846): Device 0xf5c3c400 get_master_mute: Function not implemented
W/DeviceHAL(12846): Device 0xf5c3c400 set_master_volume: Function not implemented
W/DeviceHAL(12846): Device 0xf5c3c400 set_master_mute: Function not implemented
I/AudioFlinger(12846): loadHwModule() Loaded primary audio interface, handle 10
I/AudioFlinger(12846): openOutput() this 0xf5c3d000, module 10 Device 2, SamplingRate 48000, Format 0x000001, Channels 3, flags 2
I/AudioFlinger(12846): HAL output buffer size 256 frames, normal sink buffer size 768 frames
D/vndksupport(12846): Loading /vendor/lib/hw/[email protected] from current namespace instead of sphal namespace.
D/TelephonyProvider( 3294): subIdString = 1 subId = 1
I/ViPER4Android_v2(12846): Enter EffectGetDescriptor()
I/ViPER4Android_v2(12846): EffectGetDescriptor(), uuid = 41d3c987-e6cf-11e3-a88a-11aba5d5c51b
I/BufferProvider(12846): found effect "Multichannel Downmix To Stereo" from The Android Open Source Project
I/AudioFlinger(12846): Using module 10 as the primary audio interface
W/AudioFlinger(12846): moveEffects() bad srcOutput 0
I/AudioFlinger(12846): AudioFlinger's thread 0xf4c83a00 tid=12862 ready to run
W/AudioFlinger(12846): no wake lock to update, system not ready yet
W/AudioFlinger(12846): no wake lock to update, system not ready yet
I/AudioFlinger(12846): openOutput() this 0xf5c3d000, module 10 Device 2, SamplingRate 48000, Format 0x000001, Channels 3, flags 8
I/AudioFlinger(12846): HAL output buffer size 480 frames, normal sink buffer size 960 frames
I/AudioFlinger(12846): AudioFlinger's thread 0xf4603980 tid=12865 ready to run
W/AudioFlinger(12846): no wake lock to update, system not ready yet
W/AudioFlinger(12846): no wake lock to update, system not ready yet
I/AudioFlinger(12846): AudioFlinger's thread 0xf42032c0 tid=12867 ready to run
I/bt_a2dp_hw(12846): adev_open: adev_open in A2dp_hw module
I/AudioFlinger(12846): loadHwModule() Loaded a2dp audio interface, handle 18
D/vndksupport(12846): Loading /vendor/lib/hw/audio.usb.default.so from current namespace instead of sphal namespace.
D/TelephonyProvider( 3294): subIdString = 1 subId = 1
I/AudioFlinger(12846): loadHwModule() Loaded usb audio interface, handle 26
D/vndksupport(12846): Loading /vendor/lib/hw/audio.r_submix.default.so from current namespace instead of sphal namespace.
I/r_submix(12846): adev_open(name=audio_hw_if)
I/r_submix(12846): adev_init_check()
W/DeviceHAL(12846): Device 0xf4666640 set_master_mute: Function not implemented
I/AudioFlinger(12846): loadHwModule() Loaded r_submix audio interface, handle 34
D/r_submix(12846): adev_open_input_stream(addr=0)
D/r_submix(12846): submix_audio_device_create_pipe_l(addr=0, idx=9)
D/r_submix(12846): now using address 0 for route 9
I/AudioFlinger(12846): AudioFlinger's thread 0xf4203d80 tid=12871 ready to run
D/r_submix(12846): adev_close_input_stream()
D/r_submix(12846): submix_audio_device_release_pipe_l(idx=9) addr=0
D/r_submix(12846): submix_audio_device_destroy_pipe_l(): pipe destroyed
E/SoundTriggerHwService(12846): could not read implementation properties
D/TelephonyProvider( 3294): subIdString = 1 subId = 1
I/Telecom ( 2955): InCallController: Sending updateCall [[email protected], DIALING, com.android.phone/com.android.services.telephony.TelephonyConnectionService, tel:*********, A, childs(0), has_parent(false), [Capabilities: CAPABILITY_SUPPORT_HOLD CAPABILITY_MUTE CAPABILITY_CANNOT_DOWNGRADE_VIDEO_TO_AUDIO], [Properties:]]: [email protected]
I/Telecom ( 2955): InCallController: Components updated: [ComponentInfo{com.android.dialer/com.android.incallui.InCallServiceImpl}]: [email protected]
I/Dialer ( 6324): CallList.onUpdateCall - [DialerCall_1, DIALING, [Capabilities: CAPABILITY_SUPPORT_HOLD CAPABILITY_MUTE CAPABILITY_CANNOT_DOWNGRADE_VIDEO_TO_AUDIO], [Properties:], children:[], parent:null, conferenceable:[], videoState:Audio Only, mSessionModificationState:0, CameraDir:-1]
I/Dialer ( 6324): InCallPresenter.onCallListChange - Phone switching state: OUTGOING -> OUTGOING
I/Dialer ( 6324): VideoPauseController.onStateChange - hasPrimaryCallChanged: false, videoCanPause: false, isInBackground: false
I/Dialer ( 6324): InCallFragment.setSecondary - SecondaryInfo, show: false, name: null, label: null, providerLabel: null
W/ResourceType( 6324): Failure getting entry for 0x7f100292 (t=15 e=658) (error -75)
I/Dialer ( 6324): InCallFragment.setCallState - PrimaryCallState, state: 6, connectionLabel:
I/Dialer ( 6324): InCallActivity.onPrimaryCallStateChanged
I/Dialer ( 6324): InCallActivity.showMainInCallFragment - shouldShowAnswerUi: false, shouldShowVideoUi: false, didShowAnswerScreen: false, didShowInCallScreen: true, didShowVideoCallScreen: false
W/ResourceType( 6324): Failure getting entry for 0x7f100292 (t=15 e=658) (error -75)
I/Dialer ( 6324): InCallFragment.setCallState - PrimaryCallState, state: 6, connectionLabel:
I/Dialer ( 6324): InCallActivity.onPrimaryCallStateChanged
I/Dialer ( 6324): InCallActivity.showMainInCallFragment - shouldShowAnswerUi: false, shouldShowVideoUi: false, didShowAnswerScreen: false, didShowInCallScreen: true, didShowVideoCallScreen: false
I/AudioFlinger(12846): systemReady
D/PermissionCache(12846): checking android.permission.MODIFY_AUDIO_SETTINGS for uid=1000 => granted (1574 us)
E/AudioService( 2955): Audioserver started.
D/PermissionCache(12846): checking android.permission.CAPTURE_AUDIO_HOTWORD for uid=10181 => granted (340 us)
I/AudioFlinger(12846): AudioFlinger's thread 0xf3803c40 tid=12881 ready to run
I/audio_hw_primary(12846): adev_set_mode mode = 2
D/com.gsamlabs.bbm.lib.NotifyingService( 8880): ===:91:4309:41.4:1
V/audio_hw_voice(12846): prepare_voice_session: active_out_devices: 0x1
V/audio_hw_voice(12846): set_voice_session_audio_path: ril_set_call_audio_path(0)
I/rild ( 2512): type=1400 audit(0.0:1793): avc: denied { search } for name="12846" dev="proc" ino=87474 scontext=u:r:rild:s0 tcontext=u:r:audioserver:s0 tclass=dir permissive=1
I/rild ( 2512): type=1400 audit(0.0:1794): avc: denied { read } for name="cmdline" dev="proc" ino=87476 scontext=u:r:rild:s0 tcontext=u:r:audioserver:s0 tclass=file permissive=1
I/rild ( 2512): type=1400 audit(0.0:1795): avc: denied { open } for path="/proc/12846/cmdline" dev="proc" ino=87476 scontext=u:r:rild:s0 tcontext=u:r:audioserver:s0 tclass=file permissive=1
I/rild ( 2512): type=1400 audit(0.0:1796): avc: denied { getattr } for path="/proc/12846/cmdline" dev="proc" ino=87476 scontext=u:r:rild:s0 tcontext=u:r:audioserver:s0 tclass=file permissive=1
D/audio_route(12846): Apply path: voice-earpiece-wb
D/audio_route(12846): Apply path: voice-earpiece-mic-wb
V/audio_hw_voice(12846): start_voice_session: Opening voice PCMs
V/audio_hw_voice(12846): start_voice_session: pcm_config wideband
I/ActivityManager( 2955): Killing 10371:com.google.process.gapps/u0a113 (adj 906): empty #17
W/zygote ( 2955): kill(-10371, 9) failed: No such process
I/chatty ( 2955): uid=1000(system) ActivityManager identical 2 lines
W/zygote ( 2955): kill(-10371, 9) failed: No such process
I/zygote ( 2955): Successfully killed process cgroup uid 10113 pid 10371 in 135ms
E/BufferQueueProducer( 2475): [com.socialnmobile.dictapps.notepad.color.note/com.socialnmobile.colornote.activity.NoteEditor#0] disconnect: not connected (req=1)
W/libEGL (12010): EGLNativeWindowType 0xd3c7e008 disconnect failed
V/audio_hw_voice(12846): start_voice_session: enabling two mic control
F/libc (12846): Fatal signal 11 (SIGSEGV), code 1, fault addr 0x98 in tid 12889 (reader), pid 12846 (audioserver)
I/crash_dump32(12891): type=1400 audit(0.0:1797): avc: denied { noatsecure } for scontext=u:r:audioserver:s0 tcontext=u:r:crash_dump:s0 tclass=process permissive=1
I/crash_dump32(12893): obtaining output fd from tombstoned, type: kDebuggerdTombstone
I//system/bin/tombstoned( 2515): received crash request for pid 12846
I/crash_dump32(12893): performing dump of process 12846 (target tid = 12889)
F/DEBUG (12893): *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
F/DEBUG (12893): AospExtended Version: 'v5.8'
F/DEBUG (12893): Build fingerprint: 'samsung/s5neoltexx/s5neolte:6.0.1/MMB29K/G903FXXU1BQC1:user/release-keys'
F/DEBUG (12893): Revision: '0'
F/DEBUG (12893): ABI: 'arm'
F/DEBUG (12893): pid: 12846, tid: 12889, name: reader >>> /system/bin/audioserver <<<
F/DEBUG (12893): signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x98
F/DEBUG (12893): Cause: null pointer dereference
F/DEBUG (12893): r0 00000000 r1 00000160 r2 00000001 r3 f32dc2fc
F/DEBUG (12893): r4 00000160 r5 f5c3ca88 r6 f5c3ca58 r7 f5c3c400
F/DEBUG (12893): r8 f52993f0 r9 00000002 sl 000002c0 fp f5c3ca00
F/DEBUG (12893): ip f511fefc sp f3182880 lr f51189dc pc f50f40c4 cpsr 80070030
F/DEBUG (12893):
F/DEBUG (12893): backtrace:
F/DEBUG (12893): #00 pc 000020c4 /system/lib/libtinyalsa.so (pcm_bytes_to_frames+39)
F/DEBUG (12893): #01 pc 000079d8 /system/lib/hw/audio.primary.universal7580.so (in_read+792)
F/DEBUG (12893): #02 pc 0001f45d /system/vendor/lib/hw/[email protected] (android::hardware::audio::V2_0::implementation::(anonymous namespace)::ReadThread::threadLoop()+216)
F/DEBUG (12893): #03 pc 0000d1b9 /system/lib/libutils.so (android::Thread::_threadLoop(void*)+144)
F/DEBUG (12893): #04 pc 00047ecf /system/lib/libc.so (__pthread_start(void*)+22)
F/DEBUG (12893): #05 pc 0001af59 /system/lib/libc.so (__start_thread+32)
W/NativeCrashListener( 2955): Couldn't find ProcessRecord for pid 12846
E//system/bin/tombstoned( 2515): Tombstone written to: /data/tombstones/tombstone_21
I/BootReceiver( 2955): Copying /data/tombstones/tombstone_21 to DropBox (SYSTEM_TOMBSTONE)
W/AudioSystem( 3132): AudioPolicyService server died!
W/AudioSystem( 2955): AudioPolicyService server died!
W/AudioSystem( 2955): AudioFlinger server died!
W/AudioSystem( 3737): AudioPolicyService server died!
W/AudioSystem( 3737): AudioFlinger server died!
W/AudioRecord( 3737): dead IAudioRecord, creating a new one from obtainBuffer()
I/ServiceManager( 2341): service 'media.audio_flinger' died
I/ServiceManager( 2341): service 'media.audio_policy' died
I/ServiceManager( 2341): service 'media.sound_trigger_hw' died
I/ServiceManager( 3737): Waiting for service media.audio_flinger...
I/ServiceManager( 2955): Waiting for service media.audio_policy...
W/BroadcastQueue( 2955): Background execution not allowed: receiving Intent { act=android.intent.action.DROPBOX_ENTRY_ADDED flg=0x10 (has extras) } to com.google.android.gms/.stats.service.DropBoxEntryAddedReceiver
W/BroadcastQueue( 2955): Background execution not allowed: receiving Intent { act=android.intent.action.DROPBOX_ENTRY_ADDED flg=0x10 (has extras) } to com.google.android.gms/.chimera.GmsIntentOperationService$PersistentTrustedReceiver
I/ServiceManager( 3737): Waiting for service media.audio_flinger...
I/ServiceManager( 2955): Waiting for service media.audio_policy...
I/Xposed ( 3132): fsbi >> nc >> onDataChanged >> 0 > true > 75 > H+
I/ServiceManager( 3737): Waiting for service media.audio_flinger...
I/ServiceManager( 2955): Waiting for service media.audio_policy...
I/Xposed ( 3132): fsbi >> nc >> onDataChanged >> 0 > true > 50 > H+
I/ServiceManager( 3737): Waiting for service media.audio_flinger...
I/ServiceManager( 2955): Waiting for service media.audio_policy...
I/Telecom ( 2955): InCallController: Sending updateCall [[email protected], DIALING, com.android.phone/com.android.services.telephony.TelephonyConnectionService, tel:*********, A, childs(0), has_parent(false), [Capabilities: CAPABILITY_SUPPORT_HOLD CAPABILITY_MUTE CAPABILITY_CANNOT_DOWNGRADE_VIDEO_TO_AUDIO], [Properties:]]: [email protected]
I/Telecom ( 2955): InCallController: Components updated: [ComponentInfo{com.android.dialer/com.android.incallui.InCallServiceImpl}]: [email protected]
I/Telecom ( 2955): CallsManager: setCallState DIALING -> ACTIVE, call: [[email protected], DIALING, com.android.phone/com.android.services.telephony.TelephonyConnectionService, tel:*********, A, childs(0), has_parent(false), [Capabilities: CAPABILITY_SUPPORT_HOLD CAPABILITY_MUTE CAPABILITY_CANNOT_DOWNGRADE_VIDEO_TO_AUDIO], [Properties:]]: [email protected]

Trouble compiling 8.2.0 kernel from source for ShieldTV 2017

I am trying to compile the 8.2.0 Kernel for my Shield TV 2017. I am hoping to adding the Wireguard kernel module.
I downloaded the source linked from https://developer.nvidia.com/shield-open-source following the instructions links here https://nv-tegra.nvidia.com/gitweb/...7;hb=1a508fa42d6ae55ee0fe62a3e07559a484794108
The source code checks out fine. I set up my cross compiler by setting these environment variables
Code:
ARCH=arm64
SUBARCH=arm64
CROSS_COMPILE=/absolute/path/shield-open-source/prebuilts/gcc/linux-x86/aarch64/aarch64-linux-android-4.9/bin/aarch64-linux-android-
I removed the CONFIG_SYSTEM_TRUSTED_KEYS="signing_key.x509" from the tegra_android_defconfig file
I then went to ~/shield-open-source/kernel/kernel-4.9 and ran
Code:
make mrproper
make tegra_android_defconfig
make -j4
There were a few warnings that got flagged as errors and caused the build to failed. I modified the make files so the warnings wouldn't be flagged as errors (ex: ccflags-y += -Wno-error=maybe-uninitialized)
There is one more error with ~/shield-open-source/hardware/nvidia/platform/t210b01/ers/kernel-dts/ers-platforms/tegra210b01-ers-common.dtsi in that it can't find <tegra210b01-cpufreq.dtsi>. I changed this to include "darcy-platforms/tegra210b01-darcy-cpufreq.dtsi"
I also added Wireguard by following the kernel instructions from https://forum.xda-developers.com/android/development/wireguard-rom-integration-t3711635
At this point I am able build the Image.gz file. I took the boot.img from the recovery images that NVidia provides and used AndroidImageKitchen (https://forum.xda-developers.com/showthread.php?t=2073775) to unpack the boot.img, swap out boot.img-Image.gz with the one Image.gz that I compiled and re-packed the boot.img I flashed this boot.img to my device using fastboot, and the device never boots.
I have some logs from the bootloop - here is the snipit that seems most relevant but I don't really know what I am looking for or how to determine what needs to change
Code:
09-12 22:00:42.120 3384 3384 I ConfigStore: android::hardware::configstore::V1_0::ISurfaceFlingerConfigs::hasWideColorDisplay retrieved: 1
09-12 22:00:42.120 3384 3384 I ConfigStore: android::hardware::configstore::V1_0::ISurfaceFlingerConfigs::hasHDRDisplay retrieved: 1
09-12 22:00:42.120 3383 3383 E Netd : cannot find interface dummy0
09-12 22:00:42.120 3383 3383 I Netd : Initializing RouteController: 1.3ms
09-12 22:00:42.120 3384 3384 F libc : Fatal signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0 in tid 3384 (surfaceflinger), pid 3384 (surfaceflinger)
09-12 22:00:42.120 3383 3383 D XfrmController: Sending Netlink XFRM Message: XFRM_MSG_FLUSHSA
09-12 22:00:42.120 3383 3383 D XfrmController: Sending Netlink XFRM Message: XFRM_MSG_FLUSHPOLICY
09-12 22:00:42.120 3383 3383 I Netd : Initializing XfrmController: 0.2ms
09-12 22:00:42.121 3383 3383 I Netd : Registering NetdNativeService: 0.5ms
09-12 22:00:42.122 3383 3383 I Netd : Starting CommandListener: 0.1ms
09-12 22:00:42.123 3383 3383 I Netd : Registering NetdHwService: 1.0ms
09-12 22:00:42.123 3383 3383 I Netd : Netd started in 219ms
09-12 22:00:42.132 3378 3378 D Zygote : begin preload
09-12 22:00:42.132 3378 3378 I Zygote : Installing ICU cache reference pinning...
09-12 22:00:42.132 3378 3378 I Zygote : Preloading ICU data...
09-12 22:00:42.135 3379 3379 I Zygote : Accepting command socket connections
09-12 22:00:42.138 3378 3378 I Zygote : Preloading classes...
09-12 22:00:42.140 3436 3436 I crash_dump64: obtaining output fd from tombstoned, type: kDebuggerdTombstone
09-12 22:00:42.140 3184 3184 I /system/bin/tombstoned: received crash request for pid 3384
09-12 22:00:42.141 3436 3436 I crash_dump64: performing dump of process 3384 (target tid = 3384)
09-12 22:00:42.143 3436 3436 F DEBUG : *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
09-12 22:00:42.143 3436 3436 F DEBUG : Build fingerprint: 'NVIDIA/darcy/darcy:9/PPR1.180610.011/4079208_2235.1395:user/release-keys'
09-12 22:00:42.143 3436 3436 F DEBUG : Revision: '0'
09-12 22:00:42.143 3436 3436 F DEBUG : ABI: 'arm64'
09-12 22:00:42.143 3436 3436 F DEBUG : pid: 3384, tid: 3384, name: surfaceflinger >>> /system/bin/surfaceflinger <<<
09-12 22:00:42.143 3436 3436 F DEBUG : signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0
09-12 22:00:42.143 3436 3436 F DEBUG : Cause: null pointer dereference
09-12 22:00:42.143 3436 3436 F DEBUG : x0 0000000000000000 x1 0000000000000000 x2 0000000000000000 x3 00000025b1c537d0
09-12 22:00:42.143 3436 3436 F DEBUG : x4 0000000000000000 x5 0000007fe38db898 x6 0000000000000000 x7 0000000000000030
09-12 22:00:42.143 3436 3436 F DEBUG : x8 0101010101010101 x9 b72fc0062f2280b8 x10 000000005f647079 x11 0000000000000000
09-12 22:00:42.143 3436 3436 F DEBUG : x12 0000000000000001 x13 0000000000000000 x14 0000000000000001 x15 00000025b1c81a88
09-12 22:00:42.143 3436 3436 F DEBUG : x16 000000252f3b9e58 x17 00000025307de610 x18 0000000000000001 x19 00000025b1c537d0
09-12 22:00:42.143 3436 3436 F DEBUG : x20 0000000000000000 x21 0000000000000000 x22 000000252ed0c5e0 x23 0000000000000000
09-12 22:00:42.143 3436 3436 F DEBUG : x24 0000000000000001 x25 0000007fe38dbb00 x26 00000000000f4240 x27 0000007fe38dbb00
09-12 22:00:42.143 3436 3436 F DEBUG : x28 0000007fe38dba90 x29 0000007fe38db900
09-12 22:00:42.143 3436 3436 F DEBUG : sp 0000007fe38db8e0 lr 000000252f396f78 pc 00000025307de620
09-12 22:00:42.146 3378 3378 I PackageBackwardCompatibility: Loaded android.content.pm.OrgApacheHttpLegacyUpdater
Any pointers to what I am doing wrong, or how to further debug would be appreciated.
Also if there is already a kernel built with Wireguard support, a reference to that would be :good:
Hi, I've compiled kernel for Shield 2017 following your steps and I'm probably facing same issue. My boot hangs on Nvidia logo. I have a question - how you've obtained boot logs? ADB don't work from fastboot menu for me.
Hi, did you finally succeed in compiling a kernel for shield 2017 ?

Steam Link app not working on Lineage

I am using Lineage 17.1 no GAPS / no MicroG on a shield TV pro. When I launch the steamlink app I just get a blank screen. I thought maybe it needs gaps but I loaded it on to my OP9P with Linage 18.1 no gaps no micro-g and it works just fine. Logcat shows this for app startup. Any ideas? TIA!
01-28 10:32:50.149 5369 5393 D SteamLink: Added controller with mapping 030000005e0400001907000000006800,*,a:b0,b:b1,back:b4,dpdown:b12,dpleft:b13,dpright:b14,dpup:b11,guide:b5,leftshoulder:b9,leftstick:b7,lefttrigger:a4,leftx:a0,lefty:a1,rightshoulder:b10,rightstick:b8,righttrigger:a5,rightx:a2,righty:a3,start:b6,x:b2,y:b3,
01-28 10:32:50.183 5369 5393 W Gralloc2: lock(0x2278db7d80, ...) failed: 5
01-28 10:32:50.183 5369 5393 W Surface : failed locking buffer (handle = 0x2278db7d80)
01-28 10:32:50.179 5369 5369 W MainThrd: type=1400 audit(0.0:480): avc: denied { open } for path="/dev/ashmem" dev="tmpfs" ino=3306 scontext=u:r:untrusted_app:s0:c44,c256,c512,c768 tcontext=ubject_r:ashmem_device:s0 tclass=chr_file permissive=0 app=com.valvesoftware.steamlink
01-28 10:32:50.183 5369 5393 W SteamLink: ANativeWindow_lock() failed! error= -38
01-28 10:32:50.249 5369 5393 W Gralloc2: lock(0x2278db9d00, ...) failed: 5
01-28 10:32:50.249 5369 5393 W Surface : failed locking buffer (handle = 0x2278db9d00)
01-28 10:32:50.249 5369 5393 W SteamLink: ANativeWindow_lock() failed! error= -38
01-28 10:32:50.253 5369 5393 W Gralloc2: lock(0x2278db9e80, ...) failed: 5
01-28 10:32:50.253 5369 5393 W Surface : failed locking buffer (handle = 0x2278db9e80)
01-28 10:32:50.253 5369 5393 W SteamLink: ANativeWindow_lock() failed! error= -38
01-28 10:32:50.559 5369 5393 I SDL/APP : Connected to Remote Client service with session 8489617317367984890
01-28 10:32:50.921 3660 3781 W HdmiCecController: Failed to send <Give Device Power Status> 40:8F with errorCode=3
01-28 10:32:51.132 3660 4249 E TaskPersister: File error accessing recents directory (directory doesn't exist?).
01-28 10:32:52.179 5369 5382 I tware.steamlin: ThreadFlipBegin blocked for 485.264ms
01-28 10:32:52.179 5369 5401 I tware.steamlin: IncrementDisableThreadFlip blocked for 34.931ms
01-28 10:32:52.190 5369 5382 I tware.steamlin: Background young concurrent copying GC freed 11156(3166KB) AllocSpace objects, 4(144KB) LOS objects, 95% free, 1167KB/25MB, paused 103us total 497.913ms
01-28 10:32:52.391 3660 3660 W WindowManager: removeWindowToken: Attempted to remove non-existing token: [email protected]
01-28 10:32:52.922 3660 3781 W HdmiCecController: Failed to send <Give Device Power Status> 40:8F with errorCode=3
01-28 10:32:53.373 3364 5221 W nvaudio_hw: UNDERRUN DETECTED for hdmi-playback ret 0 avail 835
01-28 10:32:54.986 3660 3702 E LightsService: Light requested not available on this device. 2
01-28 10:32:58.811 3660 3660 W WindowManager: One touch play failed: 1

Categories

Resources