diff options
author | Irfan Sheriff <isheriff@google.com> | 2010-06-07 09:03:04 -0700 |
---|---|---|
committer | Irfan Sheriff <isheriff@google.com> | 2010-07-27 11:59:29 -0700 |
commit | a2a1b911a31dd94ee75e94845f762b91f1db1368 (patch) | |
tree | fde9fc43315d8bee56efa6f326f45bf24a7b3641 /core/jni/android_net_wifi_Wifi.cpp | |
parent | 7d72e5ad7cebd3c2884793b940b1697dada6adc9 (diff) | |
download | frameworks_base-a2a1b911a31dd94ee75e94845f762b91f1db1368.zip frameworks_base-a2a1b911a31dd94ee75e94845f762b91f1db1368.tar.gz frameworks_base-a2a1b911a31dd94ee75e94845f762b91f1db1368.tar.bz2 |
Refactor WifiStateTracker
Implement WifiStateTracker as a HSM.
Change-Id: Ic12fd78f1f183b5c4dea8ad2301002267ceff0cb
Diffstat (limited to 'core/jni/android_net_wifi_Wifi.cpp')
-rw-r--r-- | core/jni/android_net_wifi_Wifi.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/core/jni/android_net_wifi_Wifi.cpp b/core/jni/android_net_wifi_Wifi.cpp index 7392442..aec537d 100644 --- a/core/jni/android_net_wifi_Wifi.cpp +++ b/core/jni/android_net_wifi_Wifi.cpp @@ -98,6 +98,11 @@ static jstring doStringCommand(JNIEnv *env, const char *cmd) } } +static jboolean android_net_wifi_isDriverLoaded(JNIEnv* env, jobject clazz) +{ + return (jboolean)(::is_wifi_driver_loaded() == 1); +} + static jboolean android_net_wifi_loadDriver(JNIEnv* env, jobject clazz) { return (jboolean)(::wifi_load_driver() == 0); @@ -524,6 +529,7 @@ static JNINativeMethod gWifiMethods[] = { /* name, signature, funcPtr */ { "loadDriver", "()Z", (void *)android_net_wifi_loadDriver }, + { "isDriverLoaded", "()Z", (void *)android_net_wifi_isDriverLoaded}, { "unloadDriver", "()Z", (void *)android_net_wifi_unloadDriver }, { "startSupplicant", "()Z", (void *)android_net_wifi_startSupplicant }, { "stopSupplicant", "()Z", (void *)android_net_wifi_stopSupplicant }, |