Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b900f5e7 authored by Steven Moreland's avatar Steven Moreland Committed by Automerger Merge Worker
Browse files

Merge "camera 2.4: conditionally disable memory init" am: 6c6fd401 am:...

Merge "camera 2.4: conditionally disable memory init" am: 6c6fd401 am: 8e69ad68 am: b9172fcc am: b088e608

Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/1449141

Change-Id: Id2fefe8f9fae524b62e7b119528fa7cb96e3992c
parents c052fff5 b088e608
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -76,7 +76,7 @@ cc_library_shared {
    header_libs: [
        "camera.device@3.4-external-impl_headers",
        "camera.device@3.5-external-impl_headers",
        "camera.device@3.6-external-impl_headers"
        "camera.device@3.6-external-impl_headers",
    ],
    export_include_dirs: ["."],
}
@@ -150,6 +150,7 @@ cc_defaults {
        "android.hidl.memory@1.0",
        "libbinder",
        "libcamera_metadata",
        "libcutils",
        "libhardware",
        "libhidlbase",
        "liblog",
+8 −0
Original line number Diff line number Diff line
@@ -22,6 +22,8 @@

#include <android/hardware/camera/provider/2.4/ICameraProvider.h>
#include <binder/ProcessState.h>
#include <cutils/memory.h>
#include <cutils/properties.h>
#include <hidl/LegacySupport.h>

using android::status_t;
@@ -41,6 +43,12 @@ int main()
    // The camera HAL may communicate to other vendor components via
    // /dev/vndbinder
    android::ProcessState::initWithDriver("/dev/vndbinder");

    // b/166675194
    if (property_get_bool("ro.vendor.camera.provider24.disable_mem_init", false)) {
        process_disable_memory_mitigations();
    }

    status_t status;
    if (kLazyService) {
        status = defaultLazyPassthroughServiceImplementation<ICameraProvider>("legacy/0",