diff options
-rw-r--r-- | fingerprintd/FingerprintDaemonProxy.cpp | 4 | ||||
-rw-r--r-- | fingerprintd/FingerprintDaemonProxy.h | 1 | ||||
-rw-r--r-- | fingerprintd/IFingerprintDaemon.cpp | 10 | ||||
-rw-r--r-- | fingerprintd/IFingerprintDaemon.h | 2 |
4 files changed, 17 insertions, 0 deletions
diff --git a/fingerprintd/FingerprintDaemonProxy.cpp b/fingerprintd/FingerprintDaemonProxy.cpp index 4c8e47850..c310160af 100644 --- a/fingerprintd/FingerprintDaemonProxy.cpp +++ b/fingerprintd/FingerprintDaemonProxy.cpp @@ -134,6 +134,10 @@ uint64_t FingerprintDaemonProxy::preEnroll() { return mDevice->pre_enroll(mDevice); } +int32_t FingerprintDaemonProxy::postEnroll() { + return mDevice->post_enroll(mDevice); +} + int32_t FingerprintDaemonProxy::stopEnrollment() { ALOG(LOG_VERBOSE, LOG_TAG, "stopEnrollment()\n"); return mDevice->cancel(mDevice); diff --git a/fingerprintd/FingerprintDaemonProxy.h b/fingerprintd/FingerprintDaemonProxy.h index 50d30efd1..871c0e62a 100644 --- a/fingerprintd/FingerprintDaemonProxy.h +++ b/fingerprintd/FingerprintDaemonProxy.h @@ -35,6 +35,7 @@ class FingerprintDaemonProxy : public BnFingerprintDaemon { virtual void init(const sp<IFingerprintDaemonCallback>& callback); virtual int32_t enroll(const uint8_t* token, ssize_t tokenLength, int32_t groupId, int32_t timeout); virtual uint64_t preEnroll(); + virtual int32_t postEnroll(); virtual int32_t stopEnrollment(); virtual int32_t authenticate(uint64_t sessionId, uint32_t groupId); virtual int32_t stopAuthentication(); diff --git a/fingerprintd/IFingerprintDaemon.cpp b/fingerprintd/IFingerprintDaemon.cpp index 5f9d30c14..71317932c 100644 --- a/fingerprintd/IFingerprintDaemon.cpp +++ b/fingerprintd/IFingerprintDaemon.cpp @@ -103,6 +103,16 @@ status_t BnFingerprintDaemon::onTransact(uint32_t code, const Parcel& data, Parc reply->writeInt64(ret); return NO_ERROR; } + case POST_ENROLL: { + CHECK_INTERFACE(IFingerprintDaemon, data, reply); + if (!checkPermission(HAL_FINGERPRINT_PERMISSION)) { + return PERMISSION_DENIED; + } + const int32_t ret = postEnroll(); + reply->writeNoException(); + reply->writeInt32(ret); + return NO_ERROR; + } case REMOVE: { CHECK_INTERFACE(IFingerprintDaemon, data, reply); if (!checkPermission(HAL_FINGERPRINT_PERMISSION)) { diff --git a/fingerprintd/IFingerprintDaemon.h b/fingerprintd/IFingerprintDaemon.h index 08cb00857..1eb4ac179 100644 --- a/fingerprintd/IFingerprintDaemon.h +++ b/fingerprintd/IFingerprintDaemon.h @@ -43,6 +43,7 @@ class IFingerprintDaemon : public IInterface, public IBinder::DeathRecipient { OPEN_HAL = IBinder::FIRST_CALL_TRANSACTION + 8, CLOSE_HAL = IBinder::FIRST_CALL_TRANSACTION + 9, INIT = IBinder::FIRST_CALL_TRANSACTION + 10, + POST_ENROLL = IBinder::FIRST_CALL_TRANSACTION + 11, }; IFingerprintDaemon() { } @@ -54,6 +55,7 @@ class IFingerprintDaemon : public IInterface, public IBinder::DeathRecipient { virtual int32_t enroll(const uint8_t* token, ssize_t tokenLength, int32_t groupId, int32_t timeout) = 0; virtual uint64_t preEnroll() = 0; + virtual int32_t postEnroll() = 0; virtual int32_t stopEnrollment() = 0; virtual int32_t authenticate(uint64_t sessionId, uint32_t groupId) = 0; virtual int32_t stopAuthentication() = 0; |