When developing and releasing new devices, vendors can define and declare the Target FCM Version in the device manifest (DM). When upgrading the vendor image for old devices, vendors can choose to implement new HAL versions and increment the Target FCM Version.
Developing new devices
When defining the device Target FCM Version for new devices:
- Implement HALs for the Target FCM Version.
- Write the correct device manifest file.
- Write the Target FCM Version to device manifest file.
Releasing new devices
When a new device is released, its initial Target FCM Version needs to be
determined and declared in the device manifest as the
target-level" attribute in the top-level
For example, devices launching with Android 9 must have Target FCM Version equal to 3 (the higher version available at this time). To declare this in the device manifest:
<manifest version="1.0" type="device" target-level="3"> <!-- ... --> </manifest>
Upgrading vendor image
When upgrading the vendor image for an old device, vendors can choose to implement new HAL versions and increment the Target FCM Version.
During a vendor image upgrade, vendors can implement new HAL versions provided that HAL name, interface name, and instance name are the same. For example:
- Google Pixel 2 and Pixel 2 XL devices released with Target FCM Version
2, which implemented the required audio 2.0 HAL
- For the audio 4.0 HAL that released with Android
9, Google Pixel 2 and Pixel 2 XL devices can use a
full OTA to upgrade to the 4.0 HAL, which implements
- Even though the
compatibility_matrix.2.xmlspecifies audio 2.0 only, the requirement on a vendor image with Target FCM Version 2 has been loosened because the Android 9 framework (FCM Version 3) considers audio 4.0 a replacement of audio 2.0 HAL in terms of functionality.
To summarize, given that
audio 2.0 and
compatibility_matrix.3.xml requires audio 4.0, the
requirements are as follows:
|FCM Version (System)||Target FCM Version (Vendor)||Requirements|
|2 (8.1)||2 (8.1)||Audio 2.0|
|3 (9)||2 (8.1)||Audio 2.0 or 4.0|
|3 (9)||3 (9)||Audio 4.0|
Upgrading Target FCM Version
During a vendor image upgrade, vendors can also increment the Target FCM Version to specify the targeted FCM Version the upgraded vendor image can work with. To bump the Target FCM Version of a device, vendors need to:
- Implement all new required HAL Versions for the Target FCM Version.
- Modify HAL Versions in the device manifest file.
- Modify the Target FCM Version in the device manifest file.
- Remove deprecated HAL versions.
- For devices launched with Android 9 or lower, cherry-pick these CLs before generating OTA update packages:
For example, Google Pixel and Pixel XL devices launched with Android 7.0
so their Target FCM Version must be at least legacy. However, the device
manifest declares the Target FCM Version 2 because the vendor image has
been updated to conform with
<manifest version="1.0" type="device" target-level="2">
If vendors do not implement all required new HAL versions or do not remove deprecated HAL versions, the Target FCM Version cannot be upgraded.
For example, Google Pixel 2 and Pixel 2 XL devices have Target FCM Version 2.
While they do implement some HALs required by
compatibility_matrix.3.xml (such as audio 4.0, health 2.0, etc.),
they do not remove
firstname.lastname@example.org, which is
deprecated at FCM Version 3 (Android 9). Hence, these
devices cannot upgrade the Target FCM Version to 3.