瀏覽代碼

Bring up wifi interface

Bob Mottram 8 年之前
父節點
當前提交
d64782d20b
共有 2 個檔案被更改,包括 9 行新增0 行删除
  1. 5
    0
      src/freedombone-utils-wifi
  2. 4
    0
      src/freedombone-wifi

+ 5
- 0
src/freedombone-utils-wifi 查看文件

@@ -68,6 +68,11 @@ function setup_wifi_atheros {
68 68
     tar -xzvf $atheros_drivers_file
69 69
     reset_usb_devices
70 70
     cd $curr_dir
71
+    update_wifi_adaptors
72
+    if [ $IFACE ]; then
73
+        ifconfig $IFACE down
74
+        ifconfig $IFACE up
75
+    fi
71 76
 }
72 77
 
73 78
 function setup_wifi {

+ 4
- 0
src/freedombone-wifi 查看文件

@@ -85,6 +85,8 @@ do
85 85
             WIFI_INTERFACE=${1}
86 86
             wifi_interface_specified=1
87 87
             write_config_param "WIFI_INTERFACE" "$WIFI_INTERFACE"
88
+            ifconfig $WIFI_INTERFACE down
89
+            ifconfig $WIFI_INTERFACE up
88 90
             ;;
89 91
         -t|--type)
90 92
             shift
@@ -140,6 +142,8 @@ if [ ! $wifi_interface_specified= ]; then
140 142
     fi
141 143
     WIFI_INTERFACE=$IFACE
142 144
     write_config_param "WIFI_INTERFACE" "$WIFI_INTERFACE"
145
+    ifconfig $WIFI_INTERFACE down
146
+    ifconfig $WIFI_INTERFACE up
143 147
 fi
144 148
 
145 149
 if [ $WIFI_DISABLE ]; then