Merge "Add background scan capability callback broadcast radio HAL."
diff --git a/audio/2.0/Android.bp b/audio/2.0/Android.bp
index 69ff791..f7975ec 100644
--- a/audio/2.0/Android.bp
+++ b/audio/2.0/Android.bp
@@ -42,6 +42,7 @@
],
out: [
"android/hardware/audio/2.0/types.h",
+ "android/hardware/audio/2.0/hwtypes.h",
"android/hardware/audio/2.0/IDevice.h",
"android/hardware/audio/2.0/IHwDevice.h",
"android/hardware/audio/2.0/BnHwDevice.h",
diff --git a/audio/common/2.0/Android.bp b/audio/common/2.0/Android.bp
index 5330086..ad599ed 100644
--- a/audio/common/2.0/Android.bp
+++ b/audio/common/2.0/Android.bp
@@ -28,6 +28,7 @@
],
out: [
"android/hardware/audio/common/2.0/types.h",
+ "android/hardware/audio/common/2.0/hwtypes.h",
],
}
diff --git a/audio/effect/2.0/Android.bp b/audio/effect/2.0/Android.bp
index 83a702a..937a4e6 100644
--- a/audio/effect/2.0/Android.bp
+++ b/audio/effect/2.0/Android.bp
@@ -56,6 +56,7 @@
],
out: [
"android/hardware/audio/effect/2.0/types.h",
+ "android/hardware/audio/effect/2.0/hwtypes.h",
"android/hardware/audio/effect/2.0/IAcousticEchoCancelerEffect.h",
"android/hardware/audio/effect/2.0/IHwAcousticEchoCancelerEffect.h",
"android/hardware/audio/effect/2.0/BnHwAcousticEchoCancelerEffect.h",
diff --git a/audio/effect/2.0/vts/functional/VtsHalAudioEffectV2_0TargetTest.cpp b/audio/effect/2.0/vts/functional/VtsHalAudioEffectV2_0TargetTest.cpp
index f6da213..15a564a 100644
--- a/audio/effect/2.0/vts/functional/VtsHalAudioEffectV2_0TargetTest.cpp
+++ b/audio/effect/2.0/vts/functional/VtsHalAudioEffectV2_0TargetTest.cpp
@@ -31,8 +31,10 @@
using android::hardware::audio::common::V2_0::AudioDevice;
using android::hardware::audio::common::V2_0::AudioHandleConsts;
using android::hardware::audio::common::V2_0::AudioMode;
+using android::hardware::audio::common::V2_0::AudioSource;
using android::hardware::audio::common::V2_0::Uuid;
using android::hardware::audio::effect::V2_0::AudioBuffer;
+using android::hardware::audio::effect::V2_0::EffectAuxChannelsConfig;
using android::hardware::audio::effect::V2_0::EffectBufferConfig;
using android::hardware::audio::effect::V2_0::EffectConfig;
using android::hardware::audio::effect::V2_0::EffectDescriptor;
@@ -278,6 +280,33 @@
EXPECT_EQ(Result::OK, ret2);
}
+TEST_F(AudioEffectHidlTest, GetConfigReverse) {
+ description("Verify that GetConfigReverse does not crash");
+ Return<void> ret =
+ effect->getConfigReverse([&](Result, const EffectConfig&) {});
+ EXPECT_TRUE(ret.isOk());
+}
+
+TEST_F(AudioEffectHidlTest, GetSupportedAuxChannelsConfigs) {
+ description("Verify that GetSupportedAuxChannelsConfigs does not crash");
+ Return<void> ret = effect->getSupportedAuxChannelsConfigs(
+ 0, [&](Result, const hidl_vec<EffectAuxChannelsConfig>&) {});
+ EXPECT_TRUE(ret.isOk());
+}
+
+TEST_F(AudioEffectHidlTest, GetAuxChannelsConfig) {
+ description("Verify that GetAuxChannelsConfig does not crash");
+ Return<void> ret = effect->getAuxChannelsConfig(
+ [&](Result, const EffectAuxChannelsConfig&) {});
+ EXPECT_TRUE(ret.isOk());
+}
+
+TEST_F(AudioEffectHidlTest, SetAuxChannelsConfig) {
+ description("Verify that SetAuxChannelsConfig does not crash");
+ Return<Result> ret = effect->setAuxChannelsConfig(EffectAuxChannelsConfig());
+ EXPECT_TRUE(ret.isOk());
+}
+
// Not generated automatically because AudioBuffer contains
// instances of hidl_memory which can't be compared properly
// in general case due to presence of handles.
@@ -394,6 +423,25 @@
EXPECT_EQ(Result::OK, ret);
}
+TEST_F(AudioEffectHidlTest, SetConfigReverse) {
+ description("Verify that SetConfigReverse does not crash");
+ Return<Result> ret =
+ effect->setConfigReverse(EffectConfig(), nullptr, nullptr);
+ EXPECT_TRUE(ret.isOk());
+}
+
+TEST_F(AudioEffectHidlTest, SetInputDevice) {
+ description("Verify that SetInputDevice does not crash");
+ Return<Result> ret = effect->setInputDevice(AudioDevice::IN_BUILTIN_MIC);
+ EXPECT_TRUE(ret.isOk());
+}
+
+TEST_F(AudioEffectHidlTest, SetAudioSource) {
+ description("Verify that SetAudioSource does not crash");
+ Return<Result> ret = effect->setAudioSource(AudioSource::MIC);
+ EXPECT_TRUE(ret.isOk());
+}
+
TEST_F(AudioEffectHidlTest, Offload) {
description("Verify that calling Offload methods works for an effect");
EffectOffloadParameter offloadParam;
@@ -434,17 +482,48 @@
EXPECT_EQ(Result::OK, ret2);
}
-// Testing getConfigReverse, getAuxChannelsConfig,
-// getSupportedAuxChannelsConfigs, setAudioSource, setConfigReverse,
-// setInputDevice doesn't make sense, because normally they are not supported by
-// the Equalizer, but it wouldn't be a problem if some vendor implementation
-// supports them, thus we can't test these methods neither for success, nor for
-// failure.
+TEST_F(AudioEffectHidlTest, Command) {
+ description("Verify that Command does not crash");
+ Return<void> ret = effect->command(0, hidl_vec<uint8_t>(), 0,
+ [&](int32_t, const hidl_vec<uint8_t>&) {});
+ EXPECT_TRUE(ret.isOk());
+}
-// command, getParameter, getSupportedConfigsForFeature,
-// getCurrentConfigForFeature, setCurrentConfigForFeature, setParameter are
-// opaque channels between vendor apps and HALs, and can't be meaningfully
-// tested with effects that don't support them.
+TEST_F(AudioEffectHidlTest, SetParameter) {
+ description("Verify that SetParameter does not crash");
+ Return<Result> ret =
+ effect->setParameter(hidl_vec<uint8_t>(), hidl_vec<uint8_t>());
+ EXPECT_TRUE(ret.isOk());
+}
+
+TEST_F(AudioEffectHidlTest, GetParameter) {
+ description("Verify that GetParameter does not crash");
+ Return<void> ret = effect->getParameter(
+ hidl_vec<uint8_t>(), 0, [&](Result, const hidl_vec<uint8_t>&) {});
+ EXPECT_TRUE(ret.isOk());
+}
+
+TEST_F(AudioEffectHidlTest, GetSupportedConfigsForFeature) {
+ description("Verify that GetSupportedConfigsForFeature does not crash");
+ Return<void> ret = effect->getSupportedConfigsForFeature(
+ 0, 0, 0, [&](Result, uint32_t, const hidl_vec<uint8_t>&) {});
+ EXPECT_TRUE(ret.isOk());
+}
+
+TEST_F(AudioEffectHidlTest, GetCurrentConfigForFeature) {
+ description("Verify that GetCurrentConfigForFeature does not crash");
+ Return<void> ret = effect->getCurrentConfigForFeature(
+ 0, 0, [&](Result, const hidl_vec<uint8_t>&) {});
+ EXPECT_TRUE(ret.isOk());
+}
+
+TEST_F(AudioEffectHidlTest, SetCurrentConfigForFeature) {
+ description("Verify that SetCurrentConfigForFeature does not crash");
+ Return<Result> ret =
+ effect->setCurrentConfigForFeature(0, hidl_vec<uint8_t>());
+ EXPECT_TRUE(ret.isOk());
+}
+
// The main test class for Equalizer Audio Effect HIDL HAL.
class EqualizerAudioEffectHidlTest : public AudioEffectHidlTest {
diff --git a/automotive/evs/1.0/Android.bp b/automotive/evs/1.0/Android.bp
index 042becd..ec56c8f 100644
--- a/automotive/evs/1.0/Android.bp
+++ b/automotive/evs/1.0/Android.bp
@@ -36,6 +36,7 @@
],
out: [
"android/hardware/automotive/evs/1.0/types.h",
+ "android/hardware/automotive/evs/1.0/hwtypes.h",
"android/hardware/automotive/evs/1.0/IEvsCamera.h",
"android/hardware/automotive/evs/1.0/IHwEvsCamera.h",
"android/hardware/automotive/evs/1.0/BnHwEvsCamera.h",
diff --git a/automotive/vehicle/2.0/Android.bp b/automotive/vehicle/2.0/Android.bp
index e08d3ca..6957bf8 100644
--- a/automotive/vehicle/2.0/Android.bp
+++ b/automotive/vehicle/2.0/Android.bp
@@ -32,6 +32,7 @@
],
out: [
"android/hardware/automotive/vehicle/2.0/types.h",
+ "android/hardware/automotive/vehicle/2.0/hwtypes.h",
"android/hardware/automotive/vehicle/2.0/IVehicle.h",
"android/hardware/automotive/vehicle/2.0/IHwVehicle.h",
"android/hardware/automotive/vehicle/2.0/BnHwVehicle.h",
diff --git a/automotive/vehicle/2.1/Android.bp b/automotive/vehicle/2.1/Android.bp
index cf4d8b0..825ec1f 100644
--- a/automotive/vehicle/2.1/Android.bp
+++ b/automotive/vehicle/2.1/Android.bp
@@ -30,6 +30,7 @@
],
out: [
"android/hardware/automotive/vehicle/2.1/types.h",
+ "android/hardware/automotive/vehicle/2.1/hwtypes.h",
"android/hardware/automotive/vehicle/2.1/IVehicle.h",
"android/hardware/automotive/vehicle/2.1/IHwVehicle.h",
"android/hardware/automotive/vehicle/2.1/BnHwVehicle.h",
diff --git a/biometrics/fingerprint/2.1/Android.bp b/biometrics/fingerprint/2.1/Android.bp
index 586e1b3..e928f9b 100644
--- a/biometrics/fingerprint/2.1/Android.bp
+++ b/biometrics/fingerprint/2.1/Android.bp
@@ -32,6 +32,7 @@
],
out: [
"android/hardware/biometrics/fingerprint/2.1/types.h",
+ "android/hardware/biometrics/fingerprint/2.1/hwtypes.h",
"android/hardware/biometrics/fingerprint/2.1/IBiometricsFingerprint.h",
"android/hardware/biometrics/fingerprint/2.1/IHwBiometricsFingerprint.h",
"android/hardware/biometrics/fingerprint/2.1/BnHwBiometricsFingerprint.h",
diff --git a/biometrics/fingerprint/2.1/vts/functional/VtsHalBiometricsFingerprintV2_1TargetTest.cpp b/biometrics/fingerprint/2.1/vts/functional/VtsHalBiometricsFingerprintV2_1TargetTest.cpp
index cd38f2e..d3f6612 100644
--- a/biometrics/fingerprint/2.1/vts/functional/VtsHalBiometricsFingerprintV2_1TargetTest.cpp
+++ b/biometrics/fingerprint/2.1/vts/functional/VtsHalBiometricsFingerprintV2_1TargetTest.cpp
@@ -23,6 +23,10 @@
#include <hidl/HidlTransportSupport.h>
#include <VtsHalHidlTargetTestBase.h>
+#include <cinttypes>
+#include <future>
+#include <utility>
+
using android::Condition;
using android::hardware::biometrics::fingerprint::V2_1::IBiometricsFingerprint;
using android::hardware::biometrics::fingerprint::V2_1::IBiometricsFingerprintClientCallback;
@@ -34,156 +38,423 @@
using android::Mutex;
using android::sp;
+namespace {
+
+static const uint32_t kTimeout = 3;
+static const std::chrono::seconds kTimeoutInSeconds = std::chrono::seconds(kTimeout);
+static const uint32_t kGroupId = 99;
+static const std::string kTmpDir = "/data/local/tmp/";
+static const uint32_t kIterations = 1000;
+
+// Wait for a callback to occur (signaled by the given future) up to the
+// provided timeout. If the future is invalid or the callback does not come
+// within the given time, returns false.
+template<class ReturnType>
+bool waitForCallback(
+ std::future<ReturnType> future,
+ std::chrono::milliseconds timeout = kTimeoutInSeconds) {
+ auto expiration = std::chrono::system_clock::now() + timeout;
+
+ EXPECT_TRUE(future.valid());
+ if (future.valid()) {
+ std::future_status status = future.wait_until(expiration);
+ EXPECT_NE(std::future_status::timeout, status)
+ << "Timed out waiting for callback";
+ if (status == std::future_status::ready) {
+ return true;
+ }
+ }
+
+ return false;
+}
+
+// Base callback implementation that just logs all callbacks by default
+class FingerprintCallbackBase : public IBiometricsFingerprintClientCallback {
+ public:
+ // implement methods of IBiometricsFingerprintClientCallback
+ virtual Return<void> onEnrollResult(uint64_t, uint32_t, uint32_t, uint32_t)
+ override {
+ ALOGD("Enroll callback called.");
+ return Return<void>();
+ }
+
+ virtual Return<void> onAcquired(uint64_t, FingerprintAcquiredInfo, int32_t)
+ override {
+ ALOGD("Acquired callback called.");
+ return Return<void>();
+ }
+
+ virtual Return<void> onAuthenticated(uint64_t, uint32_t, uint32_t,
+ const hidl_vec<uint8_t>&) override {
+ ALOGD("Authenticated callback called.");
+ return Return<void>();
+ }
+
+ virtual Return<void> onError(uint64_t, FingerprintError, int32_t)
+ override {
+ ALOGD("Error callback called.");
+ EXPECT_TRUE(false); // fail any test that triggers an error
+ return Return<void>();
+ }
+
+ virtual Return<void> onRemoved(uint64_t, uint32_t, uint32_t, uint32_t)
+ override {
+ ALOGD("Removed callback called.");
+ return Return<void>();
+ }
+
+ virtual Return<void> onEnumerate(uint64_t, uint32_t, uint32_t, uint32_t)
+ override {
+ ALOGD("Enumerate callback called.");
+ return Return<void>();
+ }
+};
+
+class EnumerateCallback : public FingerprintCallbackBase {
+ public:
+ virtual Return<void> onEnumerate(uint64_t deviceId, uint32_t fingerId,
+ uint32_t groupId, uint32_t remaining) override {
+ this->deviceId = deviceId;
+ this->fingerId = fingerId;
+ this->groupId = groupId;
+ this->remaining = remaining;
+
+ if(remaining == 0UL) {
+ promise.set_value();
+ }
+ return Return<void>();
+ }
+
+ uint64_t deviceId;
+ uint32_t fingerId;
+ uint32_t groupId;
+ uint32_t remaining;
+ std::promise<void> promise;
+};
+
+class ErrorCallback : public FingerprintCallbackBase {
+ public:
+ ErrorCallback(
+ bool filterErrors=false,
+ FingerprintError errorType=FingerprintError::ERROR_NO_ERROR) {
+ this->filterErrors = filterErrors;
+ this->errorType = errorType;
+ }
+
+ virtual Return<void> onError(uint64_t deviceId, FingerprintError error,
+ int32_t vendorCode) override {
+ if ((this->filterErrors && this->errorType == error) || !this->filterErrors) {
+ this->deviceId = deviceId;
+ this->error = error;
+ this->vendorCode = vendorCode;
+ promise.set_value();
+ }
+ return Return<void>();
+ }
+
+ bool filterErrors;
+ FingerprintError errorType;
+ uint64_t deviceId;
+ FingerprintError error;
+ int32_t vendorCode;
+ std::promise<void> promise;
+};
+
+class RemoveCallback : public FingerprintCallbackBase {
+ public:
+ RemoveCallback(uint32_t groupId) {
+ this->removeGroupId = groupId;
+ }
+
+ virtual Return<void> onRemoved(uint64_t, uint32_t, uint32_t groupId,
+ uint32_t remaining) override {
+ EXPECT_EQ(this->removeGroupId, groupId);
+ if(remaining == 0UL) {
+ promise.set_value();
+ }
+ return Return<void>();
+ }
+
+ uint32_t removeGroupId;
+ std::promise<void> promise;
+};
+
class FingerprintHidlTest : public ::testing::VtsHalHidlTargetTestBase {
+ public:
+ virtual void SetUp() override {
+ mService = ::testing::VtsHalHidlTargetTestBase::getService<IBiometricsFingerprint>();
+ ASSERT_FALSE(mService == nullptr);
-protected:
- class MyCallback : public IBiometricsFingerprintClientCallback {
+ // Create an active group
+ Return<RequestStatus> res = mService->setActiveGroup(kGroupId, kTmpDir);
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+ }
- // implement methods of IBiometricsFingerprintClientCallback
- virtual Return<void> onEnrollResult(uint64_t, uint32_t, uint32_t,
- uint32_t) override {
- callBackCalled();
- return Return<void>();
- }
+ virtual void TearDown() override {}
- virtual Return<void> onAcquired(uint64_t, FingerprintAcquiredInfo,
- int32_t) override {
- callBackCalled();
- return Return<void>();
- }
-
- virtual Return<void> onAuthenticated(uint64_t, uint32_t, uint32_t,
- const hidl_vec<uint8_t>&) override {
- callBackCalled();
- return Return<void>();
- }
-
- virtual Return<void> onError(uint64_t, FingerprintError error, int32_t)
- override {
- mTestCase->mErr = error;
- callBackCalled();
- return Return<void>();
- }
-
- virtual Return<void> onRemoved(uint64_t, uint32_t, uint32_t, uint32_t)
- override {
- callBackCalled();
- return Return<void>();
- }
-
- virtual Return<void> onEnumerate(uint64_t, uint32_t, uint32_t,
- uint32_t) override {
- callBackCalled();
- return Return<void>();
- }
-
- void callBackCalled () {
- mTestCase->mCallbackCalled = true;
- mTestCase->mCallbackCond.broadcast();
- }
-
- FingerprintHidlTest* mTestCase;
- public:
- MyCallback(FingerprintHidlTest* aTest) : mTestCase(aTest) {}
- };
-
- sp<MyCallback> mCallback;
- bool mCallbackCalled;
- Condition mCallbackCond;
- FingerprintError mErr;
- Mutex mLock;
- sp<IBiometricsFingerprint> mService;
- static const unsigned int kThresholdInSeconds = 3;
-
- void clearErr () {
- mErr = FingerprintError::ERROR_NO_ERROR;
- }
-
- // Timed callback mechanism. Will block up to kThresholdInSeconds,
- // returning true if callback was invoked in that time frame.
- bool waitForCallback(const unsigned int seconds = kThresholdInSeconds) {
- nsecs_t reltime = seconds_to_nanoseconds(seconds);
- Mutex::Autolock _l(mLock);
- nsecs_t endTime = systemTime() + reltime;
- while (!mCallbackCalled) {
- if (reltime == 0) {
- mCallbackCond.wait(mLock);
- } else {
- nsecs_t now = systemTime();
- if (now > endTime) {
- return false;
- }
- mCallbackCond.waitRelative(mLock, endTime - now);
- }
- }
- return true;
- }
-public:
- FingerprintHidlTest (): mCallbackCalled(false) {}
-
- virtual void SetUp() override {
- mService = ::testing::VtsHalHidlTargetTestBase::getService<IBiometricsFingerprint>();
-
- ASSERT_NE(mService, nullptr);
- clearErr();
-
- mCallback = new MyCallback(this);
- // TODO: instantly fail any test that receives a death notification
- }
-
- virtual void TearDown() override {}
+ sp<IBiometricsFingerprint> mService;
};
-class FingerprintHidlEnvironment : public ::testing::Environment {
-public:
- virtual void SetUp() {}
- virtual void TearDown() {}
-};
// The service should be reachable.
TEST_F(FingerprintHidlTest, ConnectTest) {
- Return<uint64_t> rc = mService->setNotify(mCallback);
- EXPECT_NE(rc, 0UL);
+ sp<FingerprintCallbackBase> cb = new FingerprintCallbackBase();
+ Return<uint64_t> rc = mService->setNotify(cb);
+ ASSERT_NE(0UL, static_cast<uint64_t>(rc));
+}
+
+// Starting the service with null callback should succeed.
+TEST_F(FingerprintHidlTest, ConnectNullTest) {
+ Return<uint64_t> rc = mService->setNotify(NULL);
+ ASSERT_NE(0UL, static_cast<uint64_t>(rc));
+}
+
+// Pre-enroll should always return unique, cryptographically secure, non-zero number
+TEST_F(FingerprintHidlTest, PreEnrollTest) {
+ std::map<uint64_t, uint64_t> m;
+
+ for(unsigned int i = 0; i < kIterations; ++i) {
+ uint64_t res = static_cast<uint64_t>(mService->preEnroll());
+ EXPECT_NE(0UL, res);
+ m[res]++;
+ EXPECT_EQ(1UL, m[res]);
+ }
+}
+
+// Enroll with an invalid (all zeroes) HAT should fail.
+TEST_F(FingerprintHidlTest, EnrollInvalidHatTest) {
+ sp<ErrorCallback> cb = new ErrorCallback();
+ Return<uint64_t> rc = mService->setNotify(cb);
+ ASSERT_NE(0UL, static_cast<uint64_t>(rc));
+
+ uint8_t token[69];
+ for(int i=0; i<69; i++) {
+ token[i] = 0;
+ }
+
+ Return<RequestStatus> res = mService->enroll(token, kGroupId, kTimeout);
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+
+ // At least one call to onError should occur
+ ASSERT_TRUE(waitForCallback(cb->promise.get_future()));
+ ASSERT_NE(FingerprintError::ERROR_NO_ERROR, cb->error);
+}
+
+// Enroll with an invalid (null) HAT should fail.
+TEST_F(FingerprintHidlTest, EnrollNullTest) {
+ sp<ErrorCallback> cb = new ErrorCallback();
+ Return<uint64_t> rc = mService->setNotify(cb);
+ ASSERT_NE(0UL, static_cast<uint64_t>(rc));
+
+ uint8_t token[69];
+ Return<RequestStatus> res = mService->enroll(token, kGroupId, kTimeout);
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+
+ // At least one call to onError should occur
+ ASSERT_TRUE(waitForCallback(cb->promise.get_future()));
+ ASSERT_NE(FingerprintError::ERROR_NO_ERROR, cb->error);
+}
+
+// PostEnroll should always return within 3s
+TEST_F(FingerprintHidlTest, PostEnrollTest) {
+ sp<FingerprintCallbackBase> cb = new FingerprintCallbackBase();
+ Return<uint64_t> rc = mService->setNotify(cb);
+
+ auto start = std::chrono::system_clock::now();
+ Return<RequestStatus> res = mService->postEnroll();
+ auto elapsed = std::chrono::system_clock::now() - start;
+ ASSERT_GE(kTimeoutInSeconds, elapsed);
+}
+
+// getAuthenticatorId should always return non-zero numbers
+TEST_F(FingerprintHidlTest, GetAuthenticatorIdTest) {
+ Return<uint64_t> res = mService->getAuthenticatorId();
+ EXPECT_NE(0UL, static_cast<uint64_t>(res));
+}
+
+// Enumerate should always trigger onEnumerated(fid=0, rem=0) when there are no fingerprints
+TEST_F(FingerprintHidlTest, EnumerateTest) {
+ sp<EnumerateCallback> cb = new EnumerateCallback();
+ Return<uint64_t> rc = mService->setNotify(cb);
+ ASSERT_NE(0UL, static_cast<uint64_t>(rc));
+
+ // Callback will return when rem=0 is found
+ Return<RequestStatus> res = mService->enumerate();
+ ASSERT_TRUE(waitForCallback(cb->promise.get_future()));
+ EXPECT_EQ(0UL, cb->fingerId);
+ EXPECT_EQ(0UL, cb->remaining);
+
+}
+
+// Remove should succeed on any inputs
+// At least one callback with "remaining=0" should occur
+TEST_F(FingerprintHidlTest, RemoveFingerprintTest) {
+ // Register callback
+ sp<RemoveCallback> cb = new RemoveCallback(kGroupId);
+ Return<uint64_t> rc = mService->setNotify(cb);
+ ASSERT_NE(0UL, static_cast<uint64_t>(rc));
+
+ // Remove a fingerprint
+ Return<RequestStatus> res = mService->remove(kGroupId, 1);
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+
+ // At least one call to onRemove with remaining=0 should occur
+ ASSERT_TRUE(waitForCallback(cb->promise.get_future()));
+}
+
+// Remove should accept 0 to delete all fingerprints
+// At least one callback with "remaining=0" should occur.
+TEST_F(FingerprintHidlTest, RemoveAllFingerprintsTest) {
+ // Register callback
+ sp<RemoveCallback> cb = new RemoveCallback(kGroupId);
+ Return<uint64_t> rc = mService->setNotify(cb);
+ ASSERT_NE(0UL, static_cast<uint64_t>(rc));
+
+ // Remove all fingerprints
+ Return<RequestStatus> res = mService->remove(kGroupId, 0);
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+ ASSERT_TRUE(waitForCallback(cb->promise.get_future()));
+}
+
+// Active group should successfully set to a writable location.
+TEST_F(FingerprintHidlTest, SetActiveGroupTest) {
+ // Create an active group
+ Return<RequestStatus> res = mService->setActiveGroup(2, kTmpDir);
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+
+ // Reset active group
+ res = mService->setActiveGroup(kGroupId, kTmpDir);
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+}
+
+// Active group should fail to set to an unwritable location.
+TEST_F(FingerprintHidlTest, SetActiveGroupUnwritableTest) {
+ // Create an active group to an unwritable location (device root dir)
+ Return<RequestStatus> res = mService->setActiveGroup(3, "/");
+ ASSERT_NE(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+
+ // Reset active group
+ res = mService->setActiveGroup(kGroupId, kTmpDir);
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+}
+
+// Active group should fail to set to a null location.
+TEST_F(FingerprintHidlTest, SetActiveGroupNullTest) {
+ // Create an active group to a null location.
+ Return<RequestStatus> res = mService->setActiveGroup(4, nullptr);
+ ASSERT_NE(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+
+ // Reset active group
+ res = mService->setActiveGroup(kGroupId, kTmpDir);
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
}
// Cancel should always return ERROR_CANCELED from any starting state including
// the IDLE state.
TEST_F(FingerprintHidlTest, CancelTest) {
- Return<uint64_t> rc = mService->setNotify(mCallback);
- EXPECT_NE(rc, 0UL);
+ sp<ErrorCallback> cb = new ErrorCallback(true, FingerprintError::ERROR_CANCELED);
+ Return<uint64_t> rc = mService->setNotify(cb);
+ ASSERT_NE(0UL, static_cast<uint64_t>(rc));
- Return<RequestStatus> res = mService->cancel();
- // make sure callback was invoked within kThresholdInSeconds
- EXPECT_EQ(true, waitForCallback());
- // check that we were able to make an IPC request successfully
- EXPECT_EQ(RequestStatus::SYS_OK, res);
- // check error should be ERROR_CANCELED
- EXPECT_EQ(FingerprintError::ERROR_CANCELED, mErr);
+ Return<RequestStatus> res = mService->cancel();
+ // check that we were able to make an IPC request successfully
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+
+ // make sure callback was invoked within kTimeoutInSeconds
+ ASSERT_TRUE(waitForCallback(cb->promise.get_future()));
+ // check error should be ERROR_CANCELED
+ ASSERT_EQ(FingerprintError::ERROR_CANCELED, cb->error);
}
-// A call to cancel should after any other method call should set the error
-// state to canceled.
-TEST_F(FingerprintHidlTest, AuthTest) {
- Return<uint64_t> rc = mService->setNotify(mCallback);
- EXPECT_NE(rc, 0UL);
+// A call to cancel should succeed during enroll.
+TEST_F(FingerprintHidlTest, CancelEnrollTest) {
+ Return<RequestStatus> res = mService->setActiveGroup(kGroupId, kTmpDir);
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
- Return<RequestStatus> res = mService->authenticate(0, 0);
- // check that we were able to make an IPC request successfully
- EXPECT_EQ(RequestStatus::SYS_OK, res);
+ sp<ErrorCallback> cb = new ErrorCallback(true, FingerprintError::ERROR_CANCELED);
+ Return<uint64_t> rc = mService->setNotify(cb);
+ ASSERT_NE(0U, static_cast<uint64_t>(rc));
- res = mService->cancel();
- // make sure callback was invoked within kThresholdInSeconds
- EXPECT_EQ(true, waitForCallback());
- // check that we were able to make an IPC request successfully
- EXPECT_EQ(RequestStatus::SYS_OK, res);
- // check error should be ERROR_CANCELED
- EXPECT_EQ(FingerprintError::ERROR_CANCELED, mErr);
+ uint8_t token[69];
+ res = mService->enroll(token, kGroupId, kTimeout);
+ // check that we were able to make an IPC request successfully
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+
+ res = mService->cancel();
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+
+ // make sure callback was invoked within kTimeoutInSeconds
+ ASSERT_TRUE(waitForCallback(cb->promise.get_future()));
+
+ // check error should be ERROR_CANCELED
+ ASSERT_EQ(FingerprintError::ERROR_CANCELED, cb->error);
}
+// A call to cancel should succeed during authentication.
+TEST_F(FingerprintHidlTest, CancelAuthTest) {
+ sp<ErrorCallback> cb = new ErrorCallback(true, FingerprintError::ERROR_CANCELED);
+ Return<uint64_t> rc = mService->setNotify(cb);
+ ASSERT_NE(0U, static_cast<uint64_t>(rc));
+
+ Return<RequestStatus> res = mService->authenticate(0, kGroupId);
+ // check that we were able to make an IPC request successfully
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+
+ res = mService->cancel();
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+
+ // make sure callback was invoked within kTimeoutInSeconds
+ ASSERT_TRUE(waitForCallback(cb->promise.get_future()));
+
+ // check error should be ERROR_CANCELED
+ ASSERT_EQ(FingerprintError::ERROR_CANCELED, cb->error);
+}
+
+// A call to cancel should succeed during authentication.
+TEST_F(FingerprintHidlTest, CancelRemoveTest) {
+ sp<ErrorCallback> cb = new ErrorCallback(true, FingerprintError::ERROR_CANCELED);
+ Return<uint64_t> rc = mService->setNotify(cb);
+ ASSERT_NE(0U, static_cast<uint64_t>(rc));
+
+ // Remove a fingerprint
+ Return<RequestStatus> res = mService->remove(kGroupId, 1);
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+
+ res = mService->cancel();
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+
+ // make sure callback was invoked within kTimeoutInSeconds
+ ASSERT_TRUE(waitForCallback(cb->promise.get_future()));
+
+ // check error should be ERROR_CANCELED
+ ASSERT_EQ(FingerprintError::ERROR_CANCELED, cb->error);
+}
+
+// A call to cancel should succeed during authentication.
+TEST_F(FingerprintHidlTest, CancelRemoveAllTest) {
+ sp<ErrorCallback> cb = new ErrorCallback(true, FingerprintError::ERROR_CANCELED);
+ Return<uint64_t> rc = mService->setNotify(cb);
+ ASSERT_NE(0U, static_cast<uint64_t>(rc));
+
+ // Remove a fingerprint
+ Return<RequestStatus> res = mService->remove(kGroupId, 0);
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+
+ res = mService->cancel();
+ ASSERT_EQ(RequestStatus::SYS_OK, static_cast<RequestStatus>(res));
+
+ // make sure callback was invoked within kTimeoutInSeconds
+ ASSERT_TRUE(waitForCallback(cb->promise.get_future()));
+
+ // check error should be ERROR_CANCELED
+ ASSERT_EQ(FingerprintError::ERROR_CANCELED, cb->error);
+}
+} // anonymous namespace
+
int main(int argc, char **argv) {
- ::testing::AddGlobalTestEnvironment(new FingerprintHidlEnvironment);
- ::testing::InitGoogleTest(&argc, argv);
- int status = RUN_ALL_TESTS();
- LOG(INFO) << "Test result = " << status;
- return status;
+ ::testing::InitGoogleTest(&argc, argv);
+ int status = RUN_ALL_TESTS();
+ LOG(INFO) << "Test result = " << status;
+ return status;
}
+
diff --git a/bluetooth/1.0/Android.bp b/bluetooth/1.0/Android.bp
index 2373ceb..75cdcfc 100644
--- a/bluetooth/1.0/Android.bp
+++ b/bluetooth/1.0/Android.bp
@@ -32,6 +32,7 @@
],
out: [
"android/hardware/bluetooth/1.0/types.h",
+ "android/hardware/bluetooth/1.0/hwtypes.h",
"android/hardware/bluetooth/1.0/IBluetoothHci.h",
"android/hardware/bluetooth/1.0/IHwBluetoothHci.h",
"android/hardware/bluetooth/1.0/BnHwBluetoothHci.h",
diff --git a/boot/1.0/Android.bp b/boot/1.0/Android.bp
index 7265cc2..498c940 100644
--- a/boot/1.0/Android.bp
+++ b/boot/1.0/Android.bp
@@ -30,6 +30,7 @@
],
out: [
"android/hardware/boot/1.0/types.h",
+ "android/hardware/boot/1.0/hwtypes.h",
"android/hardware/boot/1.0/IBootControl.h",
"android/hardware/boot/1.0/IHwBootControl.h",
"android/hardware/boot/1.0/BnHwBootControl.h",
diff --git a/broadcastradio/1.0/Android.bp b/broadcastradio/1.0/Android.bp
index 3c3a015..5f50748 100644
--- a/broadcastradio/1.0/Android.bp
+++ b/broadcastradio/1.0/Android.bp
@@ -36,6 +36,7 @@
],
out: [
"android/hardware/broadcastradio/1.0/types.h",
+ "android/hardware/broadcastradio/1.0/hwtypes.h",
"android/hardware/broadcastradio/1.0/IBroadcastRadio.h",
"android/hardware/broadcastradio/1.0/IHwBroadcastRadio.h",
"android/hardware/broadcastradio/1.0/BnHwBroadcastRadio.h",
diff --git a/broadcastradio/1.1/Android.bp b/broadcastradio/1.1/Android.bp
index 12611dd..cc0747a 100644
--- a/broadcastradio/1.1/Android.bp
+++ b/broadcastradio/1.1/Android.bp
@@ -36,6 +36,7 @@
],
out: [
"android/hardware/broadcastradio/1.1/types.h",
+ "android/hardware/broadcastradio/1.1/hwtypes.h",
"android/hardware/broadcastradio/1.1/IBroadcastRadio.h",
"android/hardware/broadcastradio/1.1/IHwBroadcastRadio.h",
"android/hardware/broadcastradio/1.1/BnHwBroadcastRadio.h",
diff --git a/camera/common/1.0/Android.bp b/camera/common/1.0/Android.bp
index aea6e76..80b5e54 100644
--- a/camera/common/1.0/Android.bp
+++ b/camera/common/1.0/Android.bp
@@ -28,6 +28,7 @@
],
out: [
"android/hardware/camera/common/1.0/types.h",
+ "android/hardware/camera/common/1.0/hwtypes.h",
],
}
diff --git a/camera/device/1.0/Android.bp b/camera/device/1.0/Android.bp
index b8560c7..44a108c 100644
--- a/camera/device/1.0/Android.bp
+++ b/camera/device/1.0/Android.bp
@@ -34,6 +34,7 @@
],
out: [
"android/hardware/camera/device/1.0/types.h",
+ "android/hardware/camera/device/1.0/hwtypes.h",
"android/hardware/camera/device/1.0/ICameraDevice.h",
"android/hardware/camera/device/1.0/IHwCameraDevice.h",
"android/hardware/camera/device/1.0/BnHwCameraDevice.h",
diff --git a/camera/device/3.2/Android.bp b/camera/device/3.2/Android.bp
index a3ac721..fd7276f 100644
--- a/camera/device/3.2/Android.bp
+++ b/camera/device/3.2/Android.bp
@@ -34,6 +34,7 @@
],
out: [
"android/hardware/camera/device/3.2/types.h",
+ "android/hardware/camera/device/3.2/hwtypes.h",
"android/hardware/camera/device/3.2/ICameraDevice.h",
"android/hardware/camera/device/3.2/IHwCameraDevice.h",
"android/hardware/camera/device/3.2/BnHwCameraDevice.h",
diff --git a/camera/metadata/3.2/Android.bp b/camera/metadata/3.2/Android.bp
index 1e464d6..d6bb9a3 100644
--- a/camera/metadata/3.2/Android.bp
+++ b/camera/metadata/3.2/Android.bp
@@ -28,6 +28,7 @@
],
out: [
"android/hardware/camera/metadata/3.2/types.h",
+ "android/hardware/camera/metadata/3.2/hwtypes.h",
],
}
diff --git a/configstore/1.0/Android.bp b/configstore/1.0/Android.bp
index c2cd54a..712e9a7 100644
--- a/configstore/1.0/Android.bp
+++ b/configstore/1.0/Android.bp
@@ -30,6 +30,7 @@
],
out: [
"android/hardware/configstore/1.0/types.h",
+ "android/hardware/configstore/1.0/hwtypes.h",
"android/hardware/configstore/1.0/ISurfaceFlingerConfigs.h",
"android/hardware/configstore/1.0/IHwSurfaceFlingerConfigs.h",
"android/hardware/configstore/1.0/BnHwSurfaceFlingerConfigs.h",
diff --git a/contexthub/1.0/Android.bp b/contexthub/1.0/Android.bp
index 8cd4acb..2bf951a 100644
--- a/contexthub/1.0/Android.bp
+++ b/contexthub/1.0/Android.bp
@@ -32,6 +32,7 @@
],
out: [
"android/hardware/contexthub/1.0/types.h",
+ "android/hardware/contexthub/1.0/hwtypes.h",
"android/hardware/contexthub/1.0/IContexthub.h",
"android/hardware/contexthub/1.0/IHwContexthub.h",
"android/hardware/contexthub/1.0/BnHwContexthub.h",
diff --git a/drm/1.0/Android.bp b/drm/1.0/Android.bp
index 0241984..9fddaa8 100644
--- a/drm/1.0/Android.bp
+++ b/drm/1.0/Android.bp
@@ -38,6 +38,7 @@
],
out: [
"android/hardware/drm/1.0/types.h",
+ "android/hardware/drm/1.0/hwtypes.h",
"android/hardware/drm/1.0/ICryptoFactory.h",
"android/hardware/drm/1.0/IHwCryptoFactory.h",
"android/hardware/drm/1.0/BnHwCryptoFactory.h",
diff --git a/gatekeeper/1.0/Android.bp b/gatekeeper/1.0/Android.bp
index 2697e4c..56e19db 100644
--- a/gatekeeper/1.0/Android.bp
+++ b/gatekeeper/1.0/Android.bp
@@ -30,6 +30,7 @@
],
out: [
"android/hardware/gatekeeper/1.0/types.h",
+ "android/hardware/gatekeeper/1.0/hwtypes.h",
"android/hardware/gatekeeper/1.0/IGatekeeper.h",
"android/hardware/gatekeeper/1.0/IHwGatekeeper.h",
"android/hardware/gatekeeper/1.0/BnHwGatekeeper.h",
diff --git a/gnss/1.0/Android.bp b/gnss/1.0/Android.bp
index 16895b6..ed6659d 100644
--- a/gnss/1.0/Android.bp
+++ b/gnss/1.0/Android.bp
@@ -68,6 +68,7 @@
],
out: [
"android/hardware/gnss/1.0/types.h",
+ "android/hardware/gnss/1.0/hwtypes.h",
"android/hardware/gnss/1.0/IAGnss.h",
"android/hardware/gnss/1.0/IHwAGnss.h",
"android/hardware/gnss/1.0/BnHwAGnss.h",
diff --git a/graphics/allocator/2.0/Android.bp b/graphics/allocator/2.0/Android.bp
index 69ddd9b..271f2ce 100644
--- a/graphics/allocator/2.0/Android.bp
+++ b/graphics/allocator/2.0/Android.bp
@@ -32,6 +32,7 @@
],
out: [
"android/hardware/graphics/allocator/2.0/types.h",
+ "android/hardware/graphics/allocator/2.0/hwtypes.h",
"android/hardware/graphics/allocator/2.0/IAllocator.h",
"android/hardware/graphics/allocator/2.0/IHwAllocator.h",
"android/hardware/graphics/allocator/2.0/BnHwAllocator.h",
diff --git a/graphics/common/1.0/Android.bp b/graphics/common/1.0/Android.bp
index 99370e8..25995cd 100644
--- a/graphics/common/1.0/Android.bp
+++ b/graphics/common/1.0/Android.bp
@@ -28,6 +28,7 @@
],
out: [
"android/hardware/graphics/common/1.0/types.h",
+ "android/hardware/graphics/common/1.0/hwtypes.h",
],
}
diff --git a/graphics/common/1.0/types.hal b/graphics/common/1.0/types.hal
index dfecec1..70cb8ec 100644
--- a/graphics/common/1.0/types.hal
+++ b/graphics/common/1.0/types.hal
@@ -181,9 +181,17 @@
* - GRALLOC_USAGE_SW_*
* - GRALLOC_USAGE_RENDERSCRIPT
*
- * When used with ANativeWindow, the dataSpace should be
- * HAL_DATASPACE_ARBITRARY, as raw image sensor buffers require substantial
- * extra metadata to define.
+ * When used with ANativeWindow, the mapping of the dataSpace field to
+ * buffer contents for RAW16 is as follows:
+ *
+ * dataSpace value | Buffer contents
+ * -------------------------------+-----------------------------------------
+ * HAL_DATASPACE_ARBITRARY | Raw image sensor data, layout is as
+ * | defined above.
+ * HAL_DATASPACE_DEPTH | Unprocessed implementation-dependent raw
+ * | depth measurements, opaque with 16 bit
+ * | samples.
+ * Other | Unsupported
*/
RAW16 = 0x20,
diff --git a/graphics/composer/2.1/Android.bp b/graphics/composer/2.1/Android.bp
index f309439..f5ab965 100644
--- a/graphics/composer/2.1/Android.bp
+++ b/graphics/composer/2.1/Android.bp
@@ -34,6 +34,7 @@
],
out: [
"android/hardware/graphics/composer/2.1/types.h",
+ "android/hardware/graphics/composer/2.1/hwtypes.h",
"android/hardware/graphics/composer/2.1/IComposer.h",
"android/hardware/graphics/composer/2.1/IHwComposer.h",
"android/hardware/graphics/composer/2.1/BnHwComposer.h",
diff --git a/graphics/mapper/2.0/Android.bp b/graphics/mapper/2.0/Android.bp
index b835b4a..98a509b 100644
--- a/graphics/mapper/2.0/Android.bp
+++ b/graphics/mapper/2.0/Android.bp
@@ -30,6 +30,7 @@
],
out: [
"android/hardware/graphics/mapper/2.0/types.h",
+ "android/hardware/graphics/mapper/2.0/hwtypes.h",
"android/hardware/graphics/mapper/2.0/IMapper.h",
"android/hardware/graphics/mapper/2.0/IHwMapper.h",
"android/hardware/graphics/mapper/2.0/BnHwMapper.h",
diff --git a/health/1.0/Android.bp b/health/1.0/Android.bp
index a428c7d..61f464d 100644
--- a/health/1.0/Android.bp
+++ b/health/1.0/Android.bp
@@ -30,6 +30,7 @@
],
out: [
"android/hardware/health/1.0/types.h",
+ "android/hardware/health/1.0/hwtypes.h",
"android/hardware/health/1.0/IHealth.h",
"android/hardware/health/1.0/IHwHealth.h",
"android/hardware/health/1.0/BnHwHealth.h",
diff --git a/ir/1.0/Android.bp b/ir/1.0/Android.bp
index da49579..5bff1d3 100644
--- a/ir/1.0/Android.bp
+++ b/ir/1.0/Android.bp
@@ -30,6 +30,7 @@
],
out: [
"android/hardware/ir/1.0/types.h",
+ "android/hardware/ir/1.0/hwtypes.h",
"android/hardware/ir/1.0/IConsumerIr.h",
"android/hardware/ir/1.0/IHwConsumerIr.h",
"android/hardware/ir/1.0/BnHwConsumerIr.h",
diff --git a/keymaster/3.0/Android.bp b/keymaster/3.0/Android.bp
index 074bb68..2b0899d 100644
--- a/keymaster/3.0/Android.bp
+++ b/keymaster/3.0/Android.bp
@@ -30,6 +30,7 @@
],
out: [
"android/hardware/keymaster/3.0/types.h",
+ "android/hardware/keymaster/3.0/hwtypes.h",
"android/hardware/keymaster/3.0/IKeymasterDevice.h",
"android/hardware/keymaster/3.0/IHwKeymasterDevice.h",
"android/hardware/keymaster/3.0/BnHwKeymasterDevice.h",
diff --git a/keymaster/3.0/IKeymasterDevice.hal b/keymaster/3.0/IKeymasterDevice.hal
index 0c59e6c..2664765 100644
--- a/keymaster/3.0/IKeymasterDevice.hal
+++ b/keymaster/3.0/IKeymasterDevice.hal
@@ -59,22 +59,6 @@
string keymasterAuthorName);
/**
- * Parses a hardware authentication token blob to extract the details needed to determine if the
- * token is applicable to a given keymaster operation. This method is intended to be
- * implemented by the HAL, without requiring a call into the trusted hardware. It is not
- * necessary for this method to verify that the values in the blob are correct.
- *
- * @param token The token blob provided by the authentication app.
- *
- * @return error ErrorCode::OK or, if the blob is invalid, ErrorCode::INVALD_ARGUMENT if the
- * blob is the wrong size, the wrong version, or incorrectly structured.
- *
- * @return tokenInfo Information extracted from the auth token.
- */
- parseHardwareAuthToken(vec<uint8_t> token)
- generates(ErrorCode error, HardwareAuthTokenInfo tokenInfo);
-
- /**
* Adds entropy to the RNG used by keymaster. Entropy added through this method is guaranteed
* not to be the only source of entropy used, and the mixing function is required to be secure,
* in the sense that if the RNG is seeded (from any source) with any data the attacker cannot
diff --git a/keymaster/3.0/default/KeymasterDevice.cpp b/keymaster/3.0/default/KeymasterDevice.cpp
index b2baa2b..720b946 100644
--- a/keymaster/3.0/default/KeymasterDevice.cpp
+++ b/keymaster/3.0/default/KeymasterDevice.cpp
@@ -33,8 +33,6 @@
using ::keymaster::SoftKeymasterDevice;
-namespace {
-
class SoftwareOnlyHidlKeymasterEnforcement : public ::keymaster::KeymasterEnforcement {
public:
SoftwareOnlyHidlKeymasterEnforcement() : KeymasterEnforcement(64, 64) {}
@@ -62,7 +60,7 @@
std::unique_ptr<::keymaster::KeymasterEnforcement> enforcement_;
};
-int keymaster0_device_initialize(const hw_module_t* mod, keymaster2_device_t** dev) {
+static int keymaster0_device_initialize(const hw_module_t* mod, keymaster2_device_t** dev) {
assert(mod->module_api_version < KEYMASTER_MODULE_API_VERSION_1_0);
ALOGI("Found keymaster0 module %s, version %x", mod->name, mod->module_api_version);
@@ -139,7 +137,7 @@
return rc;
}
-int keymaster2_device_initialize(const hw_module_t* mod, keymaster2_device_t** dev) {
+static int keymaster2_device_initialize(const hw_module_t* mod, keymaster2_device_t** dev) {
assert(mod->module_api_version >= KEYMASTER_MODULE_API_VERSION_2_0);
ALOGI("Found keymaster2 module %s, version %x", mod->name, mod->module_api_version);
@@ -193,30 +191,6 @@
}
}
-template <typename IntType, uint32_t byteOrder> struct choose_ntoh;
-
-template <typename IntType> struct choose_ntoh<IntType, __ORDER_LITTLE_ENDIAN__> {
- inline static IntType ntoh(const IntType& value) {
- IntType result = 0;
- const unsigned char* inbytes = reinterpret_cast<const unsigned char*>(&value);
- unsigned char* outbytes = reinterpret_cast<unsigned char*>(&result);
- for (int i = sizeof(IntType) - 1; i >= 0; --i) {
- *(outbytes++) = inbytes[i];
- }
- return result;
- }
-};
-
-template <typename IntType> struct choose_ntoh<IntType, __ORDER_BIG_ENDIAN__> {
- inline static IntType hton(const IntType& value) { return value; }
-};
-
-template <typename IntType> inline IntType ntoh(const IntType& value) {
- return choose_ntoh<IntType, __BYTE_ORDER__>::ntoh(value);
-}
-
-} // anonymous namespace
-
KeymasterDevice::~KeymasterDevice() {
if (keymaster_device_) keymaster_device_->common.close(&keymaster_device_->common);
}
@@ -402,34 +376,6 @@
return Void();
}
-Return<void> KeymasterDevice::parseHardwareAuthToken(const hidl_vec<uint8_t>& token,
- parseHardwareAuthToken_cb _hidl_cb) {
- HardwareAuthTokenInfo parsedToken;
- if (token.size() != sizeof(hw_auth_token_t)) {
- ALOGE("Received auth token of length %zu, expected %zu", token.size(),
- sizeof(hw_auth_token_t));
- _hidl_cb(ErrorCode::INVALID_ARGUMENT, parsedToken);
- return Void();
- }
-
- const hw_auth_token_t* authToken = reinterpret_cast<const hw_auth_token_t*>(token.data());
- if (authToken->version != 0) {
- ALOGE("Auth token version %u, expected version ", authToken->version);
- _hidl_cb(ErrorCode::INVALID_ARGUMENT, parsedToken);
- return Void();
- }
-
- parsedToken.challenge = authToken->challenge;
- parsedToken.userId = authToken->user_id;
- parsedToken.authenticatorId = authToken->authenticator_id;
- parsedToken.authenticatorType =
- static_cast<HardwareAuthenticatorType>(ntoh(authToken->authenticator_type));
- parsedToken.timestamp = ntoh(authToken->timestamp);
-
- _hidl_cb(ErrorCode::OK, parsedToken);
- return Void();
-}
-
Return<ErrorCode> KeymasterDevice::addRngEntropy(const hidl_vec<uint8_t>& data) {
if (!data.size()) return ErrorCode::OK;
return legacy_enum_conversion(
diff --git a/keymaster/3.0/default/KeymasterDevice.h b/keymaster/3.0/default/KeymasterDevice.h
index 8198eca..e048d5b 100644
--- a/keymaster/3.0/default/KeymasterDevice.h
+++ b/keymaster/3.0/default/KeymasterDevice.h
@@ -53,8 +53,6 @@
// Methods from ::android::hardware::keymaster::V3_0::IKeymasterDevice follow.
Return<void> getHardwareFeatures(getHardwareFeatures_cb _hidl_cb);
- Return<void> parseHardwareAuthToken(const hidl_vec<uint8_t>& token,
- parseHardwareAuthToken_cb _hidl_cb);
Return<ErrorCode> addRngEntropy(const hidl_vec<uint8_t>& data) override;
Return<void> generateKey(const hidl_vec<KeyParameter>& keyParams,
generateKey_cb _hidl_cb) override;
diff --git a/keymaster/3.0/types.hal b/keymaster/3.0/types.hal
index 3ff4145..1f4a0cc 100644
--- a/keymaster/3.0/types.hal
+++ b/keymaster/3.0/types.hal
@@ -400,15 +400,19 @@
};
/**
- * Data used to describe an authentication. This data is retrieved from an authentication token by
- * calling the parseHardwareAuthToken method of the HAL.
+ * Data used to prove successful authentication.
*/
-struct HardwareAuthTokenInfo {
+struct HardwareAuthToken {
uint64_t challenge;
- uint64_t userId; // Secure User ID, not Android user ID.
- uint64_t authenticatorId; // Secure authenticator ID.
- HardwareAuthenticatorType authenticatorType;
- uint64_t timestamp;
+ uint64_t userId; // Secure User ID, not Android user ID.
+ uint64_t authenticatorId; // Secure authenticator ID.
+ uint32_t authenticatorType; // HardwareAuthenticatorType, in network order.
+ uint64_t timestamp; // In network order.
+ uint8_t[32] hmac; // HMAC is computed over 0 || challenge || user_id ||
+ // authenticator_id || authenticator_type || timestamp, with a
+ // prefixed 0 byte (which was a version field in Keymaster1 and
+ // Keymaster2) and the fields packed (no padding; so you probably
+ // can't just compute over the bytes of the struct).
};
enum SecurityLevel : uint32_t {
diff --git a/light/2.0/Android.bp b/light/2.0/Android.bp
index 093a9f3..b43b7b3 100644
--- a/light/2.0/Android.bp
+++ b/light/2.0/Android.bp
@@ -30,6 +30,7 @@
],
out: [
"android/hardware/light/2.0/types.h",
+ "android/hardware/light/2.0/hwtypes.h",
"android/hardware/light/2.0/ILight.h",
"android/hardware/light/2.0/IHwLight.h",
"android/hardware/light/2.0/BnHwLight.h",
diff --git a/media/1.0/Android.bp b/media/1.0/Android.bp
index 7518eb3..21185db 100644
--- a/media/1.0/Android.bp
+++ b/media/1.0/Android.bp
@@ -28,6 +28,7 @@
],
out: [
"android/hardware/media/1.0/types.h",
+ "android/hardware/media/1.0/hwtypes.h",
],
}
diff --git a/media/omx/1.0/Android.bp b/media/omx/1.0/Android.bp
index 81dd617..c6e0389 100644
--- a/media/omx/1.0/Android.bp
+++ b/media/omx/1.0/Android.bp
@@ -38,6 +38,7 @@
],
out: [
"android/hardware/media/omx/1.0/types.h",
+ "android/hardware/media/omx/1.0/hwtypes.h",
"android/hardware/media/omx/1.0/IGraphicBufferSource.h",
"android/hardware/media/omx/1.0/IHwGraphicBufferSource.h",
"android/hardware/media/omx/1.0/BnHwGraphicBufferSource.h",
diff --git a/memtrack/1.0/Android.bp b/memtrack/1.0/Android.bp
index 9f4c7f6..4f13463 100644
--- a/memtrack/1.0/Android.bp
+++ b/memtrack/1.0/Android.bp
@@ -30,6 +30,7 @@
],
out: [
"android/hardware/memtrack/1.0/types.h",
+ "android/hardware/memtrack/1.0/hwtypes.h",
"android/hardware/memtrack/1.0/IMemtrack.h",
"android/hardware/memtrack/1.0/IHwMemtrack.h",
"android/hardware/memtrack/1.0/BnHwMemtrack.h",
diff --git a/nfc/1.0/Android.bp b/nfc/1.0/Android.bp
index e7305b4..7ee3a9e 100644
--- a/nfc/1.0/Android.bp
+++ b/nfc/1.0/Android.bp
@@ -32,6 +32,7 @@
],
out: [
"android/hardware/nfc/1.0/types.h",
+ "android/hardware/nfc/1.0/hwtypes.h",
"android/hardware/nfc/1.0/INfc.h",
"android/hardware/nfc/1.0/IHwNfc.h",
"android/hardware/nfc/1.0/BnHwNfc.h",
diff --git a/power/1.0/Android.bp b/power/1.0/Android.bp
index 453d525..f9d18c8 100644
--- a/power/1.0/Android.bp
+++ b/power/1.0/Android.bp
@@ -30,6 +30,7 @@
],
out: [
"android/hardware/power/1.0/types.h",
+ "android/hardware/power/1.0/hwtypes.h",
"android/hardware/power/1.0/IPower.h",
"android/hardware/power/1.0/IHwPower.h",
"android/hardware/power/1.0/BnHwPower.h",
diff --git a/radio/1.0/Android.bp b/radio/1.0/Android.bp
index f59cf66..e457795 100644
--- a/radio/1.0/Android.bp
+++ b/radio/1.0/Android.bp
@@ -38,6 +38,7 @@
],
out: [
"android/hardware/radio/1.0/types.h",
+ "android/hardware/radio/1.0/hwtypes.h",
"android/hardware/radio/1.0/IRadio.h",
"android/hardware/radio/1.0/IHwRadio.h",
"android/hardware/radio/1.0/BnHwRadio.h",
diff --git a/renderscript/1.0/Android.bp b/renderscript/1.0/Android.bp
index cce34e7..9f2a589 100644
--- a/renderscript/1.0/Android.bp
+++ b/renderscript/1.0/Android.bp
@@ -32,6 +32,7 @@
],
out: [
"android/hardware/renderscript/1.0/types.h",
+ "android/hardware/renderscript/1.0/hwtypes.h",
"android/hardware/renderscript/1.0/IContext.h",
"android/hardware/renderscript/1.0/IHwContext.h",
"android/hardware/renderscript/1.0/BnHwContext.h",
diff --git a/sensors/1.0/Android.bp b/sensors/1.0/Android.bp
index 8357dbe..9f7895d 100644
--- a/sensors/1.0/Android.bp
+++ b/sensors/1.0/Android.bp
@@ -30,6 +30,7 @@
],
out: [
"android/hardware/sensors/1.0/types.h",
+ "android/hardware/sensors/1.0/hwtypes.h",
"android/hardware/sensors/1.0/ISensors.h",
"android/hardware/sensors/1.0/IHwSensors.h",
"android/hardware/sensors/1.0/BnHwSensors.h",
diff --git a/sensors/1.0/default/convert.cpp b/sensors/1.0/default/convert.cpp
index 306d3a3..3d859ec 100644
--- a/sensors/1.0/default/convert.cpp
+++ b/sensors/1.0/default/convert.cpp
@@ -137,6 +137,7 @@
case SensorType::STATIONARY_DETECT:
case SensorType::MOTION_DETECT:
case SensorType::HEART_BEAT:
+ case SensorType::LOW_LATENCY_OFFBODY_DETECT:
{
dst->u.scalar = src.data[0];
break;
@@ -280,6 +281,7 @@
case SensorType::STATIONARY_DETECT:
case SensorType::MOTION_DETECT:
case SensorType::HEART_BEAT:
+ case SensorType::LOW_LATENCY_OFFBODY_DETECT:
{
dst->data[0] = src.u.scalar;
break;
diff --git a/sensors/1.0/types.hal b/sensors/1.0/types.hal
index c0d8c5d..efb18c6 100644
--- a/sensors/1.0/types.hal
+++ b/sensors/1.0/types.hal
@@ -1148,7 +1148,8 @@
* SensorType::TILT_DETECTOR, SensorType::WAKE_GESTURE,
* SensorType::GLANCE_GESTURE, SensorType::PICK_UP_GESTURE,
* SensorType::WRIST_TILT_GESTURE, SensorType::STATIONARY_DETECT,
- * SensorType::MOTION_DETECT, SensorType::HEART_BEAT
+ * SensorType::MOTION_DETECT, SensorType::HEART_BEAT,
+ * SensorType::LOW_LATENCY_OFFBODY_DETECT
*/
float scalar;
diff --git a/sensors/1.0/vts/functional/VtsHalSensorsV1_0TargetTest.cpp b/sensors/1.0/vts/functional/VtsHalSensorsV1_0TargetTest.cpp
index d21b512..a65c7b8 100644
--- a/sensors/1.0/vts/functional/VtsHalSensorsV1_0TargetTest.cpp
+++ b/sensors/1.0/vts/functional/VtsHalSensorsV1_0TargetTest.cpp
@@ -722,6 +722,7 @@
case SensorType::DEVICE_ORIENTATION:
case SensorType::MOTION_DETECT:
case SensorType::STEP_COUNTER:
+ case SensorType::LOW_LATENCY_OFFBODY_DETECT:
return SensorFlagBits::ON_CHANGE_MODE;
case SensorType::SIGNIFICANT_MOTION:
diff --git a/soundtrigger/2.0/Android.bp b/soundtrigger/2.0/Android.bp
index 4d2bb1a..d2a04be 100644
--- a/soundtrigger/2.0/Android.bp
+++ b/soundtrigger/2.0/Android.bp
@@ -32,6 +32,7 @@
],
out: [
"android/hardware/soundtrigger/2.0/types.h",
+ "android/hardware/soundtrigger/2.0/hwtypes.h",
"android/hardware/soundtrigger/2.0/ISoundTriggerHw.h",
"android/hardware/soundtrigger/2.0/IHwSoundTriggerHw.h",
"android/hardware/soundtrigger/2.0/BnHwSoundTriggerHw.h",
diff --git a/tests/bar/1.0/Android.bp b/tests/bar/1.0/Android.bp
index 694804c..2edde20 100644
--- a/tests/bar/1.0/Android.bp
+++ b/tests/bar/1.0/Android.bp
@@ -38,6 +38,7 @@
],
out: [
"android/hardware/tests/bar/1.0/types.h",
+ "android/hardware/tests/bar/1.0/hwtypes.h",
"android/hardware/tests/bar/1.0/IBar.h",
"android/hardware/tests/bar/1.0/IHwBar.h",
"android/hardware/tests/bar/1.0/BnHwBar.h",
diff --git a/tests/baz/1.0/Android.bp b/tests/baz/1.0/Android.bp
index 7939444..8f327e3 100644
--- a/tests/baz/1.0/Android.bp
+++ b/tests/baz/1.0/Android.bp
@@ -34,6 +34,7 @@
],
out: [
"android/hardware/tests/baz/1.0/types.h",
+ "android/hardware/tests/baz/1.0/hwtypes.h",
"android/hardware/tests/baz/1.0/IBase.h",
"android/hardware/tests/baz/1.0/IHwBase.h",
"android/hardware/tests/baz/1.0/BnHwBase.h",
diff --git a/tests/extension/light/2.0/Android.bp b/tests/extension/light/2.0/Android.bp
index 123bea1..93f9da1 100644
--- a/tests/extension/light/2.0/Android.bp
+++ b/tests/extension/light/2.0/Android.bp
@@ -30,6 +30,7 @@
],
out: [
"android/hardware/tests/extension/light/2.0/types.h",
+ "android/hardware/tests/extension/light/2.0/hwtypes.h",
"android/hardware/tests/extension/light/2.0/IExtLight.h",
"android/hardware/tests/extension/light/2.0/IHwExtLight.h",
"android/hardware/tests/extension/light/2.0/BnHwExtLight.h",
diff --git a/tests/foo/1.0/Android.bp b/tests/foo/1.0/Android.bp
index 9572855..b221201 100644
--- a/tests/foo/1.0/Android.bp
+++ b/tests/foo/1.0/Android.bp
@@ -38,6 +38,7 @@
],
out: [
"android/hardware/tests/foo/1.0/types.h",
+ "android/hardware/tests/foo/1.0/hwtypes.h",
"android/hardware/tests/foo/1.0/IFoo.h",
"android/hardware/tests/foo/1.0/IHwFoo.h",
"android/hardware/tests/foo/1.0/BnHwFoo.h",
diff --git a/thermal/1.0/Android.bp b/thermal/1.0/Android.bp
index fab5533..d7d5184 100644
--- a/thermal/1.0/Android.bp
+++ b/thermal/1.0/Android.bp
@@ -30,6 +30,7 @@
],
out: [
"android/hardware/thermal/1.0/types.h",
+ "android/hardware/thermal/1.0/hwtypes.h",
"android/hardware/thermal/1.0/IThermal.h",
"android/hardware/thermal/1.0/IHwThermal.h",
"android/hardware/thermal/1.0/BnHwThermal.h",
diff --git a/tv/cec/1.0/Android.bp b/tv/cec/1.0/Android.bp
index 5c6919d..a5d7b86 100644
--- a/tv/cec/1.0/Android.bp
+++ b/tv/cec/1.0/Android.bp
@@ -32,6 +32,7 @@
],
out: [
"android/hardware/tv/cec/1.0/types.h",
+ "android/hardware/tv/cec/1.0/hwtypes.h",
"android/hardware/tv/cec/1.0/IHdmiCec.h",
"android/hardware/tv/cec/1.0/IHwHdmiCec.h",
"android/hardware/tv/cec/1.0/BnHwHdmiCec.h",
diff --git a/tv/input/1.0/Android.bp b/tv/input/1.0/Android.bp
index ae5e3de..e9c2d63 100644
--- a/tv/input/1.0/Android.bp
+++ b/tv/input/1.0/Android.bp
@@ -32,6 +32,7 @@
],
out: [
"android/hardware/tv/input/1.0/types.h",
+ "android/hardware/tv/input/1.0/hwtypes.h",
"android/hardware/tv/input/1.0/ITvInput.h",
"android/hardware/tv/input/1.0/IHwTvInput.h",
"android/hardware/tv/input/1.0/BnHwTvInput.h",
diff --git a/tv/input/1.0/Android.mk b/tv/input/1.0/Android.mk
index f9e3276..87654da 100644
--- a/tv/input/1.0/Android.mk
+++ b/tv/input/1.0/Android.mk
@@ -1,19 +1,41 @@
-#
-# Copyright (C) 2016 The Android Open Source Project
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
+# This file is autogenerated by hidl-gen. Do not edit manually.
LOCAL_PATH := $(call my-dir)
-include $(call all-subdir-makefiles)
+################################################################################
+
+include $(CLEAR_VARS)
+LOCAL_MODULE := android.hardware.tv.input@1.0-java-constants
+LOCAL_MODULE_CLASS := JAVA_LIBRARIES
+
+intermediates := $(call local-generated-sources-dir, COMMON)
+
+HIDL := $(HOST_OUT_EXECUTABLES)/hidl-gen$(HOST_EXECUTABLE_SUFFIX)
+#
+GEN := $(intermediates)/android/hardware/tv/input/V1_0/Constants.java
+$(GEN): $(HIDL)
+$(GEN): $(LOCAL_PATH)/types.hal
+$(GEN): $(LOCAL_PATH)/ITvInput.hal
+$(GEN): $(LOCAL_PATH)/ITvInputCallback.hal
+
+$(GEN): PRIVATE_HIDL := $(HIDL)
+$(GEN): PRIVATE_OUTPUT_DIR := $(intermediates)
+$(GEN): PRIVATE_CUSTOM_TOOL = \
+ $(PRIVATE_HIDL) -o $(PRIVATE_OUTPUT_DIR) \
+ -Ljava-constants \
+ -randroid.hardware:hardware/interfaces \
+ -randroid.hidl:system/libhidl/transport \
+ android.hardware.tv.input@1.0
+
+$(GEN):
+ $(transform-generated-source)
+LOCAL_GENERATED_SOURCES += $(GEN)
+# Avoid dependency cycle of framework.jar -> this-library -> framework.jar
+LOCAL_NO_STANDARD_LIBRARIES := true
+LOCAL_JAVA_LIBRARIES := core-oj
+
+include $(BUILD_STATIC_JAVA_LIBRARY)
+
+
+
+include $(call all-makefiles-under,$(LOCAL_PATH))
diff --git a/tv/input/1.0/default/TvInput.cpp b/tv/input/1.0/default/TvInput.cpp
index 0bc6401..4ea1dec 100644
--- a/tv/input/1.0/default/TvInput.cpp
+++ b/tv/input/1.0/default/TvInput.cpp
@@ -19,8 +19,6 @@
#include "TvInput.h"
-const native_handle_t kNullNativeHandle{sizeof(native_handle_t), 0, 0, {}};
-
namespace android {
namespace hardware {
namespace tv {
@@ -117,8 +115,6 @@
sidebandStream = stream.sideband_stream_source_handle;
}
} else {
- // TODO(b/30814137)
- sidebandStream = const_cast<native_handle_t*>(&kNullNativeHandle);
if (ret == -EBUSY) {
res = Result::NO_RESOURCE;
} else if (ret == -EEXIST) {
diff --git a/tv/input/1.0/types.hal b/tv/input/1.0/types.hal
index 55eb6ad..60a3b7b 100644
--- a/tv/input/1.0/types.hal
+++ b/tv/input/1.0/types.hal
@@ -27,6 +27,7 @@
};
/* Type of physical TV input. */
+@export(name="", value_prefix="TV_INPUT_TYPE_")
enum TvInputType : int32_t {
OTHER = 1, // Generic hardware.
TUNER = 2, // Tuner. e.g. built-in terrestrial tuner
@@ -46,6 +47,7 @@
* regardless of whether the connected external device is electrically on or not.
* If the device does not have such capability, you must use UNKNOWN.
*/
+@export(name="", value_prefix="CABLE_CONNECTION_STATUS_")
enum CableConnectionStatus : int32_t {
UNKNOWN = 0,
CONNECTED = 1,
@@ -63,6 +65,7 @@
// must be filled with 0s.
};
+@export(name="", value_prefix="EVENT_")
enum TvInputEventType : int32_t {
/*
* Hardware notifies the framework that a device is available.
diff --git a/usb/1.0/Android.bp b/usb/1.0/Android.bp
index 0b641f1..f939c8b 100644
--- a/usb/1.0/Android.bp
+++ b/usb/1.0/Android.bp
@@ -32,6 +32,7 @@
],
out: [
"android/hardware/usb/1.0/types.h",
+ "android/hardware/usb/1.0/hwtypes.h",
"android/hardware/usb/1.0/IUsb.h",
"android/hardware/usb/1.0/IHwUsb.h",
"android/hardware/usb/1.0/BnHwUsb.h",
diff --git a/vibrator/1.0/Android.bp b/vibrator/1.0/Android.bp
index d6813ea..11ae996 100644
--- a/vibrator/1.0/Android.bp
+++ b/vibrator/1.0/Android.bp
@@ -30,6 +30,7 @@
],
out: [
"android/hardware/vibrator/1.0/types.h",
+ "android/hardware/vibrator/1.0/hwtypes.h",
"android/hardware/vibrator/1.0/IVibrator.h",
"android/hardware/vibrator/1.0/IHwVibrator.h",
"android/hardware/vibrator/1.0/BnHwVibrator.h",
diff --git a/wifi/1.0/Android.bp b/wifi/1.0/Android.bp
index 2319999..df5c9d2 100644
--- a/wifi/1.0/Android.bp
+++ b/wifi/1.0/Android.bp
@@ -54,6 +54,7 @@
],
out: [
"android/hardware/wifi/1.0/types.h",
+ "android/hardware/wifi/1.0/hwtypes.h",
"android/hardware/wifi/1.0/IWifi.h",
"android/hardware/wifi/1.0/IHwWifi.h",
"android/hardware/wifi/1.0/BnHwWifi.h",
diff --git a/wifi/1.0/default/Android.mk b/wifi/1.0/default/Android.mk
index cc5e1c6..13f6cc1 100644
--- a/wifi/1.0/default/Android.mk
+++ b/wifi/1.0/default/Android.mk
@@ -48,6 +48,5 @@
libwifi-hal \
libwifi-system \
libcld80211
-LOCAL_WHOLE_STATIC_LIBRARIES := $(LIB_WIFI_HAL)
LOCAL_INIT_RC := android.hardware.wifi@1.0-service.rc
include $(BUILD_EXECUTABLE)
diff --git a/wifi/supplicant/1.0/Android.bp b/wifi/supplicant/1.0/Android.bp
index a6c2758..a0adb8d 100644
--- a/wifi/supplicant/1.0/Android.bp
+++ b/wifi/supplicant/1.0/Android.bp
@@ -52,6 +52,7 @@
],
out: [
"android/hardware/wifi/supplicant/1.0/types.h",
+ "android/hardware/wifi/supplicant/1.0/hwtypes.h",
"android/hardware/wifi/supplicant/1.0/ISupplicant.h",
"android/hardware/wifi/supplicant/1.0/IHwSupplicant.h",
"android/hardware/wifi/supplicant/1.0/BnHwSupplicant.h",