Revert "sm6150-common: fingerprint: Allow to build without fingerprintextension"
This reverts commit a8c1391091
.
Change-Id: I78244b2491b8ba824907cf1cb056c2f26bffbc72
This commit is contained in:
parent
62f89dcba7
commit
565809d0b5
@ -417,4 +417,14 @@
|
||||
<instance>imsrtpservice</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>vendor.xiaomi.hardware.fingerprintextension</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.0</version>
|
||||
<interface>
|
||||
<name>IXiaomiFingerprint</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@1.0::IXiaomiFingerprint/default</fqname>
|
||||
</hal>
|
||||
</manifest>
|
||||
|
@ -1,6 +1,8 @@
|
||||
cc_defaults {
|
||||
name: "xiaomi_sm6150_fingerprint_defaults",
|
||||
cc_binary {
|
||||
name: "android.hardware.biometrics.fingerprint@2.1-service.xiaomi_sm6150",
|
||||
defaults: ["hidl_defaults"],
|
||||
init_rc: ["android.hardware.biometrics.fingerprint@2.1-service.xiaomi_sm6150.rc"],
|
||||
vintf_fragments: ["android.hardware.biometrics.fingerprint@2.1-service.xiaomi_sm6150.xml"],
|
||||
vendor: true,
|
||||
relative_install_path: "hw",
|
||||
srcs: [
|
||||
@ -15,24 +17,7 @@ cc_defaults {
|
||||
"libhardware",
|
||||
"libutils",
|
||||
"android.hardware.biometrics.fingerprint@2.1",
|
||||
"vendor.xiaomi.hardware.fingerprintextension@1.0",
|
||||
],
|
||||
}
|
||||
|
||||
cc_binary {
|
||||
name: "android.hardware.biometrics.fingerprint@2.1-service.xiaomi_sm6150",
|
||||
defaults: ["xiaomi_sm6150_fingerprint_defaults"],
|
||||
init_rc: ["android.hardware.biometrics.fingerprint@2.1-service.xiaomi_sm6150.rc"],
|
||||
vintf_fragments: ["android.hardware.biometrics.fingerprint@2.1-service.xiaomi_sm6150.xml"],
|
||||
}
|
||||
|
||||
cc_binary {
|
||||
name: "android.hardware.biometrics.fingerprint@2.1-service.xiaomi_sm6150-ext",
|
||||
defaults: ["xiaomi_sm6150_fingerprint_defaults"],
|
||||
init_rc: ["android.hardware.biometrics.fingerprint@2.1-service.xiaomi_sm6150-ext.rc"],
|
||||
vintf_fragments: [
|
||||
"android.hardware.biometrics.fingerprint@2.1-service.xiaomi_sm6150.xml",
|
||||
"vendor.xiaomi.hardware.fingerprintextension@1.0.xml",
|
||||
],
|
||||
shared_libs: ["vendor.xiaomi.hardware.fingerprintextension@1.0"],
|
||||
cflags: ["-DXIAOMI_FINGERPRINTEXTENSION"],
|
||||
}
|
||||
|
@ -378,11 +378,9 @@ void BiometricsFingerprint::notify(const fingerprint_msg_t *msg) {
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef XIAOMI_FINGERPRINTEXTENSION
|
||||
Return<int32_t> BiometricsFingerprint::extCmd(int32_t cmd, int32_t param) {
|
||||
return mDevice->extCmd(mDevice, cmd, param);
|
||||
}
|
||||
#endif /* XIAOMI_FINGERPRINTEXTENSION */
|
||||
|
||||
} // namespace implementation
|
||||
} // namespace V2_1
|
||||
|
@ -24,13 +24,9 @@
|
||||
#include <hidl/MQDescriptor.h>
|
||||
#include <hidl/Status.h>
|
||||
#include <android/hardware/biometrics/fingerprint/2.1/IBiometricsFingerprint.h>
|
||||
|
||||
#ifdef XIAOMI_FINGERPRINTEXTENSION
|
||||
#include <vendor/xiaomi/hardware/fingerprintextension/1.0/IXiaomiFingerprint.h>
|
||||
|
||||
#include "fingerprint.h"
|
||||
#else
|
||||
#include <hardware/fingerprint.h>
|
||||
#endif
|
||||
|
||||
namespace android {
|
||||
namespace hardware {
|
||||
@ -48,12 +44,9 @@ using ::android::hardware::hidl_vec;
|
||||
using ::android::hardware::hidl_string;
|
||||
using ::android::sp;
|
||||
|
||||
#ifdef XIAOMI_FINGERPRINTEXTENSION
|
||||
using ::vendor::xiaomi::hardware::fingerprintextension::V1_0::IXiaomiFingerprint;
|
||||
|
||||
struct BiometricsFingerprint : public IBiometricsFingerprint, public IXiaomiFingerprint {
|
||||
#else
|
||||
struct BiometricsFingerprint : public IBiometricsFingerprint {
|
||||
#endif
|
||||
public:
|
||||
BiometricsFingerprint();
|
||||
~BiometricsFingerprint();
|
||||
@ -74,9 +67,7 @@ public:
|
||||
Return<RequestStatus> remove(uint32_t gid, uint32_t fid) override;
|
||||
Return<RequestStatus> setActiveGroup(uint32_t gid, const hidl_string& storePath) override;
|
||||
Return<RequestStatus> authenticate(uint64_t operationId, uint32_t gid) override;
|
||||
#ifdef XIAOMI_FINGERPRINTEXTENSION
|
||||
Return<int32_t> extCmd(int32_t cmd, int32_t param) override;
|
||||
#endif /*XIAOMI_FINGERPRINTEXTENSION */
|
||||
|
||||
private:
|
||||
static fingerprint_device_t* openHal();
|
||||
|
@ -1,7 +0,0 @@
|
||||
service vendor.fps_hal /vendor/bin/hw/android.hardware.biometrics.fingerprint@2.1-service.xiaomi_sm6150-ext
|
||||
# "class hal" causes a race condition on some devices due to files created
|
||||
# in /data. As a workaround, postpone startup until later in boot once
|
||||
# /data is mounted.
|
||||
class late_start
|
||||
user system
|
||||
group system input uhid
|
@ -43,7 +43,6 @@ status_t BiometricsFingerprint::registerAsSystemService() {
|
||||
ALOGI("Successfully registered IBiometricsFingerprint");
|
||||
}
|
||||
|
||||
#ifdef XIAOMI_FINGERPRINTEXTENSION
|
||||
ret = IXiaomiFingerprint::registerAsService();
|
||||
if (ret != 0) {
|
||||
ALOGE("Failed to register IXiaomiFingerprint (%d)", ret);
|
||||
@ -51,7 +50,6 @@ status_t BiometricsFingerprint::registerAsSystemService() {
|
||||
} else {
|
||||
ALOGI("Successfully registered IXiaomiFingerprint");
|
||||
}
|
||||
#endif /* XIAOMI_FINGERPRINTEXTENSION */
|
||||
|
||||
fail:
|
||||
return ret;
|
||||
|
@ -1,11 +0,0 @@
|
||||
<manifest version="1.0" type="device">
|
||||
<hal format="hidl">
|
||||
<name>vendor.xiaomi.hardware.fingerprintextension</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.0</version>
|
||||
<interface>
|
||||
<name>IXiaomiFingerprint</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
</manifest>
|
1
sepolicy/vendor/file_contexts
vendored
1
sepolicy/vendor/file_contexts
vendored
@ -23,7 +23,6 @@
|
||||
|
||||
# HALs
|
||||
/(vendor|system/vendor)/bin/hw/android\.hardware\.biometrics\.fingerprint@2\.1-service\.xiaomi_sm6150 u:object_r:hal_fingerprint_default_exec:s0
|
||||
/(vendor|system/vendor)/bin/hw/android\.hardware\.biometrics\.fingerprint@2\.1-service\.xiaomi_sm6150-ext u:object_r:hal_fingerprint_default_exec:s0
|
||||
/vendor/bin/hw/android\.hardware\.light@2\.0-service\.xiaomi_sm6150 u:object_r:hal_light_default_exec:s0
|
||||
/vendor/bin/hw/android\.hardware\.power-service\.xiaomi-libperfmgr u:object_r:hal_power_default_exec:s0
|
||||
/vendor/bin/hw/vendor\.lineage\.livedisplay@2\.1-service\.xiaomi_sm6150 u:object_r:hal_lineage_livedisplay_qti_exec:s0
|
||||
|
@ -140,6 +140,9 @@ PRODUCT_PACKAGES += \
|
||||
android.hardware.drm@1.4-service.clearkey
|
||||
|
||||
# Fingerprint
|
||||
PRODUCT_PACKAGES += \
|
||||
android.hardware.biometrics.fingerprint@2.1-service.xiaomi_sm6150
|
||||
|
||||
PRODUCT_COPY_FILES += \
|
||||
frameworks/native/data/etc/android.hardware.fingerprint.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.fingerprint.xml
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user