From c4c9333378ad5a7431a207781817545735109f29 Mon Sep 17 00:00:00 2001 From: Dheeraj CVR Date: Thu, 12 Mar 2015 08:13:40 +0530 Subject: smdk4412-common: fix wifi p2p Change-Id: Ie30f13e4aba6fe2d9b1ccc82f44aa310f47fc0a9 --- common.mk | 3 ++- configs/p2p_supplicant_overlay.conf | 11 +++++++++++ configs/wpa_supplicant.conf | 16 ---------------- configs/wpa_supplicant_overlay.conf | 4 ++++ rootdir/init.smdk4x12.rc | 17 +++++++---------- 5 files changed, 24 insertions(+), 27 deletions(-) create mode 100644 configs/p2p_supplicant_overlay.conf delete mode 100644 configs/wpa_supplicant.conf create mode 100644 configs/wpa_supplicant_overlay.conf diff --git a/common.mk b/common.mk index 4c6d787..38418f0 100644 --- a/common.mk +++ b/common.mk @@ -49,7 +49,8 @@ PRODUCT_COPY_FILES += \ # Wifi PRODUCT_COPY_FILES += \ - $(COMMON_PATH)/configs/wpa_supplicant.conf:system/etc/wifi/wpa_supplicant.conf + $(COMMON_PATH)/configs/wpa_supplicant_overlay.conf:system/etc/wifi/wpa_supplicant_overlay.conf \ + $(COMMON_PATH)/configs/p2p_supplicant_overlay.conf:system/etc/wifi/p2p_supplicant_overlay.conf PRODUCT_PROPERTY_OVERRIDES += \ wifi.interface=wlan0 \ diff --git a/configs/p2p_supplicant_overlay.conf b/configs/p2p_supplicant_overlay.conf new file mode 100644 index 0000000..1566988 --- /dev/null +++ b/configs/p2p_supplicant_overlay.conf @@ -0,0 +1,11 @@ +disable_scan_offload=1 +p2p_listen_reg_class=81 +p2p_listen_channel=1 +p2p_oper_reg_class=124 +p2p_oper_channel=149 +manufacturer=SAMSUNG_ELECTRONICS +model_name=SAMSUNG_MOBILE +model_number=2014 +serial_number=19691101 +update_config=1 +no_ctrl_interface= diff --git a/configs/wpa_supplicant.conf b/configs/wpa_supplicant.conf deleted file mode 100644 index 3c25e6f..0000000 --- a/configs/wpa_supplicant.conf +++ /dev/null @@ -1,16 +0,0 @@ -update_config=1 -ctrl_interface=wlan0 -eapol_version=1 -ap_scan=1 -fast_reauth=1 -p2p_disabled=1 -autoscan=samsung_exponential:8:128 -disable_scan_offload=1 -p2p_listen_reg_class=81 -p2p_listen_channel=1 -p2p_oper_reg_class=124 -p2p_oper_channel=149 -manufacturer=SAMSUNG_ELECTRONICS -model_name=SAMSUNG_MOBILE -model_number=2014 -serial_number=19691101 diff --git a/configs/wpa_supplicant_overlay.conf b/configs/wpa_supplicant_overlay.conf new file mode 100644 index 0000000..46504a2 --- /dev/null +++ b/configs/wpa_supplicant_overlay.conf @@ -0,0 +1,4 @@ +p2p_disabled=1 +autoscan=samsung_exponential:8:128 +update_config=1 +no_ctrl_interface= diff --git a/rootdir/init.smdk4x12.rc b/rootdir/init.smdk4x12.rc index 9a39e7c..a07a754 100755 --- a/rootdir/init.smdk4x12.rc +++ b/rootdir/init.smdk4x12.rc @@ -359,7 +359,6 @@ on post-fs-data chown system system /dev/ttyGS3 # for wifi - mkdir /data/misc/wifi/sockets 0770 wifi wifi mkdir /data/misc/dhcp 0775 dhcp dhcp chown dhcp dhcp /data/misc/dhcp chown wifi root /dev/rfkill @@ -426,11 +425,11 @@ service charger /sbin/healthd -c service p2p_supplicant /system/bin/wpa_supplicant \ -iwlan0 -Dnl80211 -c/data/misc/wifi/wpa_supplicant.conf \ - -I/system/etc/wifi/wpa_supplicant.conf \ - -O/data/misc/wifi/sockets -N \ - -ip2p0 -Dnl80211 -c/data/misc/wifi/p2p_supplicant.conf -e/data/misc/wifi/entropy.bin \ + -I/system/etc/wifi/wpa_supplicant_overlay.conf -N \ + -ip2p0 -Dnl80211 -c/data/misc/wifi/p2p_supplicant.conf \ + -I/system/etc/wifi/p2p_supplicant_overlay.conf \ -puse_p2p_group_interface=1 \ - -g@android:wpa_wlan0 + -e/data/misc/wifi/entropy.bin -g@android:wpa_wlan0 # we will start as root and wpa_supplicant will switch to user wifi # after setting up the capabilities required for WEXT # user wifi @@ -441,11 +440,9 @@ service p2p_supplicant /system/bin/wpa_supplicant \ oneshot service wpa_supplicant /system/bin/wpa_supplicant \ - -Dnl80211 -iwlan0 -e/data/misc/wifi/entropy.bin \ - -c/data/misc/wifi/wpa_supplicant.conf \ - -I/system/etc/wifi/wpa_supplicant.conf \ - -O/data/misc/wifi/sockets \ - -g@android:wpa_wlan0 + -iwlan0 -Dnl80211 -c/data/misc/wifi/wpa_supplicant.conf \ + -I/system/etc/wifi/wpa_supplicant_overlay.conf \ + -e/data/misc/wifi/entropy.bin -g@android:wpa_wlan0 # we will start as root and wpa_supplicant will switch to user wifi # after setting up the capabilities required for WEXT # user wifi -- cgit v1.1