summaryrefslogtreecommitdiffstats
path: root/camera
diff options
context:
space:
mode:
authorIliyan Malchev <malchev@google.com>2017-04-05 13:26:30 -0700
committerIliyan Malchev <malchev@google.com>2017-04-13 00:24:39 +0000
commitb4488af17c8f9a25f0c6309669a4bedd547851e7 (patch)
tree9a4c47296d472be59742617f06647408234e756e /camera
parent17f0c0dde7b319cc4bc7bb0ccbe6636792693801 (diff)
downloadplatform_hardware_interfaces-b4488af17c8f9a25f0c6309669a4bedd547851e7.tar.gz
platform_hardware_interfaces-b4488af17c8f9a25f0c6309669a4bedd547851e7.tar.bz2
platform_hardware_interfaces-b4488af17c8f9a25f0c6309669a4bedd547851e7.zip
android.hardware.camera.provider@2.4: set up /dev/vndbinder
The camera-HAL implementation may need to communicate with other vendor components over /dev/vndbinder. Route all libbinder traffic to that node. b/36651814 b/36651237 b/35870313 b/36683636 Test: sailfish Change-Id: I9b80fefbcdf5ce18a2d788e8582ea8791a604435 Signed-off-by: Iliyan Malchev <malchev@google.com>
Diffstat (limited to 'camera')
-rw-r--r--camera/provider/2.4/default/Android.bp1
-rw-r--r--camera/provider/2.4/default/service.cpp5
2 files changed, 6 insertions, 0 deletions
diff --git a/camera/provider/2.4/default/Android.bp b/camera/provider/2.4/default/Android.bp
index 950682700c..8e8df62695 100644
--- a/camera/provider/2.4/default/Android.bp
+++ b/camera/provider/2.4/default/Android.bp
@@ -37,6 +37,7 @@ cc_binary {
shared_libs: [
"libhidlbase",
"libhidltransport",
+ "libbinder",
"liblog",
"libutils",
"android.hardware.camera.device@1.0",
diff --git a/camera/provider/2.4/default/service.cpp b/camera/provider/2.4/default/service.cpp
index df2602efe5..7eeb6379c9 100644
--- a/camera/provider/2.4/default/service.cpp
+++ b/camera/provider/2.4/default/service.cpp
@@ -19,11 +19,16 @@
#include <android/hardware/camera/provider/2.4/ICameraProvider.h>
#include <hidl/LegacySupport.h>
+#include <binder/ProcessState.h>
+
using android::hardware::camera::provider::V2_4::ICameraProvider;
using android::hardware::defaultPassthroughServiceImplementation;
int main()
{
ALOGI("Camera provider Service is starting.");
+ // The camera HAL may communicate to other vendor components via
+ // /dev/vndbinder
+ android::ProcessState::initWithDriver("/dev/vndbinder");
return defaultPassthroughServiceImplementation<ICameraProvider>("legacy/0", /*maxThreads*/ 6);
}