{% include "_versions.html" %}
A VINTF object aggregates data from device manifest and framework manifest files (XML) and from the device itself at runtime. Both manifests share a format, although not all elements apply to both (for details on the schema, see Manifest file schema).
The Device manifest (provided by the device) consists of the vendor manifest and the ODM manifest.
device/VENDOR/DEVICE/manifest.xml
, but multiple fragment
files can be used. For details, see
Generate
DM from fragments.
SKU
is defined (where SKU
is the value of
the property ro.boot.product.hardware.sku
),
/odm/etc/vintf/manifest_SKU.xml
/odm/etc/vintf/manifest.xml
SKU
is defined,
/odm/etc/manifest_SKU.xml
/odm/etc/manifest.xml
/vendor/etc/vintf/manifest.xml
exists, combine the following:
/vendor/etc/vintf/manifest.xml
/vendor/manfiest.xml
(legacy, no fragments)override="true"
. For example, ODM manifest may override
some <hal>
tags from vendor manifest. See documentation for attribute
override
below.This setup enables multiple products with the same board to share the same vendor image (which provides common HALs) yet have different ODM images (which specify product-specific HALs).
Example vendor manifest:
<?xml version="1.0" encoding="UTF-8"?> <!-- Comments, Legal notices, etc. here --> <manifest version="1.0" type="device" target-level="1"> <hal> <name>android.hardware.camera</name> <transport>hwbinder</transport> <version>3.4</version> <interface> <name>ICameraProvider</name> <instance>legacy/0</instance> <instance>proprietary/0</instance> </interface> </hal> <hal> <name>android.hardware.nfc</name> <transport>hwbinder</transport> <version>1.0</version> <version>2.0</version> <interface> <name>INfc</name> <instance>nfc_nci</instance> </interface> </hal> <hal> <name>android.hardware.nfc</name> <transport>hwbinder</transport> <version>2.0</version> <interface> <name>INfc</name> <instance>default</instance> </interface> </hal> <hal> <name>android.hardware.drm</name> <transport>hwbinder</transport> <version>1.0</version> <interface> <name>ICryptoFactory</name> <instance>default</instance> </interface> <interface> <name>IDrmFactory</name> <instance>default</instance> </interface> <fqname>@1.1::ICryptoFactory/clearkey</fqname> <fqname>@1.1::IDrmFactory/clearkey</fqname> </hal> <hal format="native"> <name>EGL</name> <version>1.1</version> </hal> <hal format="native"> <name>GLES</name> <version>1.1</version> <version>2.0</version> <version>3.0</version> </hal> <sepolicy> <version>25.0</version> </sepolicy> </manifest>
Example ODM manifest:
<?xml version="1.0" encoding="UTF-8"?> <!-- Comments, Legal notices, etc. here --> <manifest version="1.0" type="device"> <!-- camera 3.4 in vendor manifest is ignored --> <hal override="true"> <name>android.hardware.camera</name> <transport>hwbinder</transport> <version>3.5</version> <interface> <name>ICameraProvider</name> <instance>legacy/0</instance> </interface> </hal> <!-- NFC is disabled --> <hal override="true"> <name>android.hardware.nfc</name> <transport>hwbinder</transport> </hal> <hal> <name>android.hardware.power</name> <transport>hwbinder</transport> <version>1.1</version> <interface> <name>IPower</name> <instance>default</instance> </interface> </hal> </manifest>For more details, see DM Development.
The Framework manifest file (provided by Google) is manually generated and
lives in the Android source tree at
/system/libhidl/manifest.xml
.
Example Framework manifest:
<?xml version="1.0" encoding="UTF-8"?> <!-- Comments, Legal notices, etc. here --> <manifest version="1.0" type="framework"> <hal> <name>android.hidl.allocator</name> <transport>hwbinder</transport> <version>1.0</version> <interface> <name>IAllocator</name> <instance>ashmem</instance> </interface> </hal> <hal> <name>android.hidl.memory</name> <transport arch="32+64">passthrough</transport> <version>1.0</version> <interface> <name>IMapper</name> <instance>ashmem</instance> </interface> </hal> <hal> <name>android.hidl.manager</name> <transport>hwbinder</transport> <version>1.0</version> <interface> <name>IServiceManager</name> <instance>default</instance> </interface> </hal> <hal> <name>android.frameworks.sensorservice</name> <transport>hwbinder</transport> <version>1.0</version> <interface> <name>ISensorManager</name> <instance>default</instance> </interface> </hal> <vendor-ndk> <version>27</version> </vendor-ndk> <system-sdk> <version>27</version> </system-sdk> </manifest>
This section describes the meaning of these XML tags. Some "required" tags
can be missing from the source file in Android source tree and written by
assemble_vintf
at build time. "Required" tags must be present in the corresponding files on the
device.
?xml
manifest.version
manifest.type
device
for
device manifest file and framework
for framework manifest
file.manifest.target-level
manifest.hal
format
attribute.manifest.hal.format
hidl
: HIDL HALs. This is the default.
native
: native HALs.manifest.hal.override
true
: override other <hal>
elements with
the same <name>
and major version. If no
<version>
or <fqname>
are in this
<hal>
element, then this HAL is disabled.false
: do not override other <hal>
elements
with the same <name>
and major version.manifest.hal.name
android.hardware.camera
(HIDL HAL)GLES
(native HAL, requires name only)manifest.hal.transport
manifest.hal.format == "hidl"
. Must NOT be
present otherwise. States what transport will be used when an interface from
this package is queried from service manager. Value can be one of:
hwbinder
: binderized modepassthrough
: passthrough modemanifest.hal.transport.arch
passthrough
and must not be present for
hwbinder
. Describes the bitness of the passthrough service being
provided. Value can be one of:
32
: 32-bit mode64
: 64-bit mode32+64
: bothmanifest.hal.version
hal
tags in a
manifest. Format is MAJOR.MINOR
. For
examples, refer to hardware/interfaces
,
vendor/${VENDOR}/interfaces
,
framework/hardware/interfaces
, or
system/hardware/interfaces
.
hal
elements with the same name, unless
override="true"
.manifest.hal.interface
<interface>
elements in a <hal>
; names
must be distinct.manifest.hal.interface.name
manifest.hal.interface.instance
<instance>
elements.manifest.hal.fqname
manifest.hal.name
. Format is
@MAJOR.MINOR::INTERFACE/INSTANCE
.
For devices upgrading from Android 8.0, this cannot be used to declare
instances required by the compatibility matrix.manifest.sepolicy
manifest.sepolicy.version
SDK_INT.PLAT_INT
.manifest.vendor-ndk
<vendor-ndk>
entries must have
different <version>
’s. Describes a set of VNDK snapshots
provided by the framework.manifest.vendor-ndk.version
manifest.vendor-ndk.library
libjpeg.so
, including the prefix
lib
and the suffix .so
. No path components are
allowed.manifest.system-sdk.version