diff options
author | Davide Garberi <dade.garberi@gmail.com> | 2019-05-15 23:15:09 +0200 |
---|---|---|
committer | Davide Garberi <dade.garberi@gmail.com> | 2019-05-16 14:36:53 +0200 |
commit | 6df37ecfba588b61bf873ffe933034fb6da5368c (patch) | |
tree | 4cec326038a9a83346e5530caa8eb04cb7d57fee /rootdir/bin/init.bt.sh | |
parent | 544f72589efed0d251f54377269d5ab43da8ca88 (diff) |
msm8996-common: Remove wcg_mac_tool
* Turns out we don't actually need to use this as /proc/mac_wifi and mac_bt can turn into normal mac address values just with hex dumping
* Remove bt_mac_prop as we can just set the mac path in vendor_prop.mk
Change-Id: I23665cdd5d39d5e090694cff5a63f55ecb9ea334
Diffstat (limited to 'rootdir/bin/init.bt.sh')
-rw-r--r-- | rootdir/bin/init.bt.sh | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/rootdir/bin/init.bt.sh b/rootdir/bin/init.bt.sh index 63ea643..ad4b03e 100644 --- a/rootdir/bin/init.bt.sh +++ b/rootdir/bin/init.bt.sh @@ -17,9 +17,11 @@ # # Set the proper hardware based BT mac address +bt_mac=$(xxd -p /proc/mac_bt | tr '[:lower:]' '[:upper:]' | sed 's/.\{2\}/&:/g' | sed 's/.$//'); bt_mac_path="/data/vendor/bluetooth/bdaddr" -bt_mac=$(getprop sys.bt.address); -if [[ ! -f $bt_mac_path ]] || [[ $(echo $bt_mac) != $(cat /data/vendor/bluetooth/bdaddr) ]]; then +if [[ ! -f $bt_mac_path ]] || [[ $(echo $bt_mac) != $(cat $bt_mac_path) ]]; then echo $bt_mac > $bt_mac_path + chmod 0644 $bt_mac_path + chown bluetooth $bt_mac_path + chgrp bluetooth $bt_mac_path fi; -setprop ro.vendor.bt.bdaddr_path $bt_mac_path |