diff options
author | Android Partner Docs <noreply@android.com> | 2017-06-21 01:32:24 +0000 |
---|---|---|
committer | android-build-merger <android-build-merger@google.com> | 2017-06-21 01:32:24 +0000 |
commit | d9c0a94dd500fc616309192152fa737a83c185d8 (patch) | |
tree | 9d32c0a36693b9ce3d89bd10152cd3a2564f486e /en/devices/tech/ota/ab_updates.html | |
parent | 0d061a7f4d62ccb9174916e0abbe96d84646df45 (diff) | |
parent | bb57032f17abb0cfb5ebe780451d58a97779c5b6 (diff) | |
download | source.android.com-d9c0a94dd500fc616309192152fa737a83c185d8.tar.gz |
Merge "Docs: Changes to source.android.com" am: 14605d77b5 am: 833d7d4b81 am: f51ce41011
am: bb57032f17
Change-Id: I7c8bcc0487be283a76b1703188455ef18b255661
Diffstat (limited to 'en/devices/tech/ota/ab_updates.html')
-rw-r--r-- | en/devices/tech/ota/ab_updates.html | 39 |
1 files changed, 25 insertions, 14 deletions
diff --git a/en/devices/tech/ota/ab_updates.html b/en/devices/tech/ota/ab_updates.html index 0c538085..282ea5a0 100644 --- a/en/devices/tech/ota/ab_updates.html +++ b/en/devices/tech/ota/ab_updates.html @@ -375,7 +375,7 @@ <li>Implement the state machine as shown in Figure 1:</li> </ul> -<img src="images/ab-updates-state-machine.png"> +<img src="/devices/tech/ota/images/ab-updates-state-machine.png"> <p class="img-caption"><strong>Figure 1.</strong> Bootloader state machine</p> @@ -423,8 +423,9 @@ extra arguments: </p> -<pre>skip_initramfs rootwait ro init=/init root="/dev/dm-0 dm=system none ro,0 1 \ - android-verity <public-key-id> <path-to-system-partition>" +<pre class="devsite-click-to-copy"> +<code class="devsite-terminal">skip_initramfs rootwait ro init=/init root="/dev/dm-0 dm=system none ro,0 1 \ + android-verity <public-key-id> <path-to-system-partition>"</code> </pre> <p> @@ -444,19 +445,23 @@ <code>openssl</code> command to convert from <code>.pem</code> to <code>.der</code> format (if the .X509 certificate is formatted in <code>.pem</code> format): - <pre>openssl x509 -in <x509-pem-certificate> -outform der -out <x509-der-certificate></pre> +<pre class="devsite-terminal devsite-click-to-copy"> +openssl x509 -in <x509-pem-certificate> -outform der -out <x509-der-certificate> +</pre> </li> <li> Once copied to the kernel build root, build the <code>zImage</code> to include the certificate as part of the system keyring. This can be verified from the following <code>procfs</code> entry (requires <code>KEYS_CONFIG_DEBUG_PROC_KEYS</code> to be enabled): - <pre>angler:/# cat /proc/keys +<pre class="devsite-click-to-copy"> +angler:/# cat /proc/keys 1c8a217e I------ 1 perm 1f010000 0 0 asymmetri Android: 7e4333f9bba00adfe0ede979e28ed1920492b40f: X509.RSA 0492b40f [] 2d454e3e I------ 1 perm 1f030000 0 0 keyring -.system_keyring: 1/4</pre> +.system_keyring: 1/4 +</pre> </li> </ol> @@ -550,8 +555,10 @@ Android: 7e4333f9bba00adfe0ede979e28ed1920492b40f: X509.RSA 0492b40f [] the A/B-ed partitions. For example: </p> -<pre><path-to-block-device>/vendor /vendor ext4 ro -wait,verify=<path-to-block-device>/metadata,slotselect</pre> +<pre class="devsite-click-to-copy"> +<path-to-block-device>/vendor /vendor ext4 ro +wait,verify=<path-to-block-device>/metadata,slotselect +</pre> <p> Please note that there should be no partition named <code>vendor</code> but @@ -628,7 +635,8 @@ wait,verify=<path-to-block-device>/metadata,slotselect</pre> For example, use the following to generate a full OTA: </p> -<pre>./build/tools/releasetools/ota_from_target_files \ +<pre class="devsite-terminal devsite-click-to-copy"> +./build/tools/releasetools/ota_from_target_files \ dist_output/tardis-target_files.zip ota_update.zip </pre> @@ -636,7 +644,8 @@ wait,verify=<path-to-block-device>/metadata,slotselect</pre> Or, generate an incremental OTA: </p> -<pre>./build/tools/releasetools/ota_from_target_files \ +<pre class="devsite-terminal devsite-click-to-copy"> +./build/tools/releasetools/ota_from_target_files \ -i PREVIOUS-tardis-target_files.zip \ dist_output/tardis-target_files.zip incremental_ota_update.zip </pre> @@ -661,7 +670,8 @@ wait,verify=<path-to-block-device>/metadata,slotselect</pre> configuration: </p> -<pre>AB_OTA_PARTITIONS := \ +<pre class="devsite-click-to-copy"> +AB_OTA_PARTITIONS := \ boot \ system \ bootloader @@ -692,7 +702,8 @@ wait,verify=<path-to-block-device>/metadata,slotselect</pre> applicable): </p> -<pre>AB_OTA_POSTINSTALL_CONFIG += \ +<pre class="devsite-click-to-copy"> +AB_OTA_POSTINSTALL_CONFIG += \ RUN_POSTINSTALL_system=true \ POSTINSTALL_PATH_system=usr/bin/postinst \ FILESYSTEM_TYPE_system=ext4 @@ -706,14 +717,14 @@ additions to the product's device configuration (in the product's device.mk):</p <ol> <li>Include the native components in the build. This ensures the compilation script and binaries are compiled and included in the system image. - <pre> +<pre class="devsite-click-to-copy"> # A/B OTA dexopt package PRODUCT_PACKAGES += otapreopt_script </pre> </li> <li>Connect the compilation script to <code>update_engine</code> such that it is run as a post-install step. - <pre> +<pre class="devsite-click-to-copy"> # A/B OTA dexopt update_engine hookup AB_OTA_POSTINSTALL_CONFIG += \ RUN_POSTINSTALL_system=true \ |