Loading services/core/java/com/android/server/connectivity/Tethering.java +2 −21 Original line number Diff line number Diff line Loading @@ -278,29 +278,10 @@ public class Tethering extends BaseNetworkObserver { sm.start(); } } else { if (isUsb(iface)) { // ignore usb0 down after enabling RNDIS if (isUsb(iface) || isBluetooth(iface) || isWifi(iface) ) { // ignore usb0, bt-pan or wlan0 down after enabling tethering // we will handle disconnect in interfaceRemoved instead if (VDBG) Log.d(TAG, "ignore interface down for " + iface); } else if (isWifi(iface) && (mWifiManager != null) && mWifiManager.getWifiStaSapConcurrency()) { int wifiApState = 0; wifiApState = mWifiManager.getWifiApState(); // Ignore AP interface down after enabling STA connection. // If STA connects to same band the SAP is enabled, the // driver stops SAP before it proceeds for STA connection // hence ignore interface down. After STA connection, // driver starts SAP on STA channel. if ((wifiApState == WifiManager.WIFI_AP_STATE_DISABLING) || (wifiApState == WifiManager.WIFI_AP_STATE_DISABLED)) { if (VDBG) Log.d(TAG, "Got interface down for " + iface); sm.sendMessage(TetherInterfaceSM.CMD_INTERFACE_DOWN); mIfaces.remove(iface); } else { if (VDBG) Log.d(TAG, "ignore interface down for " + iface); } } else if (sm != null) { sm.sendMessage(TetherInterfaceSM.CMD_INTERFACE_DOWN); mIfaces.remove(iface); Loading Loading
services/core/java/com/android/server/connectivity/Tethering.java +2 −21 Original line number Diff line number Diff line Loading @@ -278,29 +278,10 @@ public class Tethering extends BaseNetworkObserver { sm.start(); } } else { if (isUsb(iface)) { // ignore usb0 down after enabling RNDIS if (isUsb(iface) || isBluetooth(iface) || isWifi(iface) ) { // ignore usb0, bt-pan or wlan0 down after enabling tethering // we will handle disconnect in interfaceRemoved instead if (VDBG) Log.d(TAG, "ignore interface down for " + iface); } else if (isWifi(iface) && (mWifiManager != null) && mWifiManager.getWifiStaSapConcurrency()) { int wifiApState = 0; wifiApState = mWifiManager.getWifiApState(); // Ignore AP interface down after enabling STA connection. // If STA connects to same band the SAP is enabled, the // driver stops SAP before it proceeds for STA connection // hence ignore interface down. After STA connection, // driver starts SAP on STA channel. if ((wifiApState == WifiManager.WIFI_AP_STATE_DISABLING) || (wifiApState == WifiManager.WIFI_AP_STATE_DISABLED)) { if (VDBG) Log.d(TAG, "Got interface down for " + iface); sm.sendMessage(TetherInterfaceSM.CMD_INTERFACE_DOWN); mIfaces.remove(iface); } else { if (VDBG) Log.d(TAG, "ignore interface down for " + iface); } } else if (sm != null) { sm.sendMessage(TetherInterfaceSM.CMD_INTERFACE_DOWN); mIfaces.remove(iface); Loading