From a0b4f4cd286a66c74ea1621b7492486a0fd0a4e2 Mon Sep 17 00:00:00 2001 From: Luca Stefani Date: Sat, 9 Sep 2017 14:28:12 +0200 Subject: Set cnss-sh user to system * /persist/wlan_bt/ff_flag owner is system and running the script as root needs dac_override capability -> Run the script as system and change /sys/module/cnss_common/parameters/bdwlan_file owner accordly --- rootdir/etc/init.qcom.rc | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/rootdir/etc/init.qcom.rc b/rootdir/etc/init.qcom.rc index 3ab9a8a..b421b81 100755 --- a/rootdir/etc/init.qcom.rc +++ b/rootdir/etc/init.qcom.rc @@ -351,6 +351,9 @@ on boot write /sys/bus/msm_subsys/devices/subsys4/restart_level "related" write /sys/bus/msm_subsys/devices/subsys5/restart_level "related" + # Allow access for WLAN firmware + chown system system /sys/module/cnss_common/parameters/bdwlan_file + # msm specific files that need to be created on /data on post-fs-data mkdir /tombstones/modem 0771 system system @@ -1047,6 +1050,16 @@ service wifi_fccutild /system/bin/wifi_fccutild service cnss-daemon /system/bin/cnss-daemon -n -l class late_start + user system + group system inet net_admin wifi + +service cnss-sh /system/bin/init.cnss.sh + class core + user system + oneshot + +on property:sys.shutdown.requested=* + stop cnss-daemon service loc_launcher /system/bin/loc_launcher # loc_launcher will start as root and set its uid to gps -- cgit v1.2.3