am e22eb863: Merge "fix start driver for corner cases DO NOT MERGE" into gingerbread
Merge commit 'e22eb863dc4419dcaf329e9e28e3dc1f71f82902' into gingerbread-plus-aosp * commit 'e22eb863dc4419dcaf329e9e28e3dc1f71f82902': fix start driver for corner cases DO NOT MERGE
This commit is contained in:
@@ -1286,15 +1286,13 @@ public class WifiStateTracker extends NetworkStateTracker {
|
||||
if (macaddr != null) {
|
||||
mWifiInfo.setMacAddress(macaddr);
|
||||
}
|
||||
if (mRunState == RUN_STATE_STARTING) {
|
||||
mRunState = RUN_STATE_RUNNING;
|
||||
if (!mIsScanOnly) {
|
||||
reconnectCommand();
|
||||
} else {
|
||||
// In some situations, supplicant needs to be kickstarted to
|
||||
// start the background scanning
|
||||
scan(true);
|
||||
}
|
||||
mRunState = RUN_STATE_RUNNING;
|
||||
if (!mIsScanOnly) {
|
||||
reconnectCommand();
|
||||
} else {
|
||||
// In some situations, supplicant needs to be kickstarted to
|
||||
// start the background scanning
|
||||
scan(true);
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -1614,12 +1612,10 @@ public class WifiStateTracker extends NetworkStateTracker {
|
||||
}
|
||||
|
||||
public synchronized boolean restart() {
|
||||
if (mRunState == RUN_STATE_STOPPED) {
|
||||
if (isDriverStopped()) {
|
||||
mRunState = RUN_STATE_STARTING;
|
||||
resetConnections(true);
|
||||
return startDriver();
|
||||
} else if (mRunState == RUN_STATE_STOPPING) {
|
||||
mRunState = RUN_STATE_STARTING;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user