HAL info structure can not have pointers
Ideally this would become variable sized array,
but JNI is expecting fixed-size array here,
so, define reasonable size (2), which fits all the
known cases.
Change-Id: I1752d5bef9db60570b03a8dc8e54da2277aca95a
Signed-off-by: Alexey Polyudov <apolyudov@google.com>
also define some helper macros to simpify app id definitions
Bug: 28086503
Change-Id: Ib04069889b24d057db5fcd3a408c845951cafeea
Signed-off-by: Alexey Polyudov <apolyudov@google.com>
We're defining the version of a hardware module (hw_module_t), not
a hardware device (hw_device_t). Thus, we only have 16 bits for
our version number, instead of 32, and need to use the
HARDWARE_DEVICE_API_VERSION macro.
Additionally, for the CONTEXT_HUB_DEVICE_API_VERSION_1_0 define,
which has 1 and 0 hard-coded in the name itself, we hard code 1 and 0
within its definition.
We create CONTEXT_HUB_DEVICE_API_VERSION which will change as we update
the major and minor version numbers in this header.
Bug: 27798362
Change-Id: I58b9751dfb1989fd6bb7fbfc01329494cd88130c
Adding a new HAL to support Context hubs on devices.
A context hubs is a low power compute domain with access
to sensors and the potential to download code on the device.
Change-Id: Id2f8d6a0ac9bbfe18a64432c867a8869c0db91fe