OSDN Git Service

libbinder: Choose the binder driver at runtime based on system/vendor process.
authorJayant Chowdhary <jchowdhary@google.com>
Fri, 8 Mar 2019 18:08:20 +0000 (10:08 -0800)
committerJayant Chowdhary <jchowdhary@google.com>
Tue, 12 Mar 2019 20:11:47 +0000 (13:11 -0700)
commit46f95536bec334f8472ea92a7697c37602337398
tree00594a48238495be58d3e4ef10d360183fb6f22b
parenta5d85affa9d1c869a8d2178b9daa284240e1c904
libbinder: Choose the binder driver at runtime based on system/vendor process.

This is needed since llndk libraries may cause the system variant of libbinder (and therefore
compile time checks are not enough) to be loaded in a vendor process. In that case, it should not be
initing the driver with /dev/binder. It should use /dev/vndbinder instead.

Bug: 124128212

Test: Device boots
Test: play YouTube videos, use camera to take pictures / record video (sanity) on devices supporting
      legacy vndk(sailfish) and also devices supporting current vndk.

Change-Id: Ia5581efa04c8d4adc6af39668b0aa98e84324a27
Signed-off-by: Jayant Chowdhary <jchowdhary@google.com>
libs/binder/Android.bp
libs/binder/ProcessState.cpp