Loading compatibility_matrices/compatibility_matrix.current.xml +1 −1 Original line number Diff line number Diff line Loading @@ -693,7 +693,7 @@ </hal> <hal format="aidl" optional="true"> <name>android.hardware.weaver</name> <version>1</version> <version>2</version> <interface> <name>IWeaver</name> <instance>default</instance> Loading weaver/aidl/default/Android.bp +1 −1 Original line number Diff line number Diff line Loading @@ -34,7 +34,7 @@ cc_binary { "Weaver.cpp", ], shared_libs: [ "android.hardware.weaver-V1-ndk", "android.hardware.weaver-V2-ndk", "libbase", "libbinder_ndk", ], Loading weaver/aidl/default/Weaver.cpp +6 −5 Original line number Diff line number Diff line Loading @@ -37,18 +37,19 @@ std::array<struct Slotinfo, 16> slot_array; } ::ndk::ScopedAStatus Weaver::read(int32_t in_slotId, const std::vector<uint8_t>& in_key, WeaverReadResponse* out_response) { using ::aidl::android::hardware::weaver::WeaverReadStatus; if (in_slotId > 15 || in_key.size() > 16) { *out_response = {0, {}}; return ndk::ScopedAStatus(AStatus_fromServiceSpecificError(Weaver::STATUS_FAILED)); *out_response = {0, {}, WeaverReadStatus::FAILED}; return ndk::ScopedAStatus::ok(); } if (slot_array[in_slotId].key != in_key) { *out_response = {0, {}}; return ndk::ScopedAStatus(AStatus_fromServiceSpecificError(Weaver::STATUS_INCORRECT_KEY)); *out_response = {0, {}, WeaverReadStatus::INCORRECT_KEY}; return ndk::ScopedAStatus::ok(); } *out_response = {0, slot_array[in_slotId].value}; *out_response = {0, slot_array[in_slotId].value, WeaverReadStatus::OK}; return ::ndk::ScopedAStatus::ok(); } Loading weaver/aidl/default/android.hardware.weaver-service.example.xml +1 −1 Original line number Diff line number Diff line <manifest version="1.0" type="device"> <hal format="aidl"> <name>android.hardware.weaver</name> <version>1</version> <version>2</version> <interface> <name>IWeaver</name> <instance>default</instance> Loading Loading
compatibility_matrices/compatibility_matrix.current.xml +1 −1 Original line number Diff line number Diff line Loading @@ -693,7 +693,7 @@ </hal> <hal format="aidl" optional="true"> <name>android.hardware.weaver</name> <version>1</version> <version>2</version> <interface> <name>IWeaver</name> <instance>default</instance> Loading
weaver/aidl/default/Android.bp +1 −1 Original line number Diff line number Diff line Loading @@ -34,7 +34,7 @@ cc_binary { "Weaver.cpp", ], shared_libs: [ "android.hardware.weaver-V1-ndk", "android.hardware.weaver-V2-ndk", "libbase", "libbinder_ndk", ], Loading
weaver/aidl/default/Weaver.cpp +6 −5 Original line number Diff line number Diff line Loading @@ -37,18 +37,19 @@ std::array<struct Slotinfo, 16> slot_array; } ::ndk::ScopedAStatus Weaver::read(int32_t in_slotId, const std::vector<uint8_t>& in_key, WeaverReadResponse* out_response) { using ::aidl::android::hardware::weaver::WeaverReadStatus; if (in_slotId > 15 || in_key.size() > 16) { *out_response = {0, {}}; return ndk::ScopedAStatus(AStatus_fromServiceSpecificError(Weaver::STATUS_FAILED)); *out_response = {0, {}, WeaverReadStatus::FAILED}; return ndk::ScopedAStatus::ok(); } if (slot_array[in_slotId].key != in_key) { *out_response = {0, {}}; return ndk::ScopedAStatus(AStatus_fromServiceSpecificError(Weaver::STATUS_INCORRECT_KEY)); *out_response = {0, {}, WeaverReadStatus::INCORRECT_KEY}; return ndk::ScopedAStatus::ok(); } *out_response = {0, slot_array[in_slotId].value}; *out_response = {0, slot_array[in_slotId].value, WeaverReadStatus::OK}; return ::ndk::ScopedAStatus::ok(); } Loading
weaver/aidl/default/android.hardware.weaver-service.example.xml +1 −1 Original line number Diff line number Diff line <manifest version="1.0" type="device"> <hal format="aidl"> <name>android.hardware.weaver</name> <version>1</version> <version>2</version> <interface> <name>IWeaver</name> <instance>default</instance> Loading