avbtool: Use root=/dev/dm-0 instead of root=0xfd00.
am: fd9c18d298
Change-Id: Ic7f19aad1a1b8b59be26964cad07ea442165c18a
diff --git a/avbtool b/avbtool
index bb23db2..2dfb259 100755
--- a/avbtool
+++ b/avbtool
@@ -1907,7 +1907,7 @@
c += ' 2' # number of optional args
c += ' restart_on_corruption'
c += ' ignore_zero_blocks'
- c += '" root=0xfd00'
+ c += '" root=/dev/dm-0'
# Now that we have the command-line, generate the descriptor.
desc = AvbKernelCmdlineDescriptor()
diff --git a/test/avb_slot_verify_unittest.cc b/test/avb_slot_verify_unittest.cc
index 1553173..8d6b9cb 100644
--- a/test/avb_slot_verify_unittest.cc
+++ b/test/avb_slot_verify_unittest.cc
@@ -1211,7 +1211,7 @@
"Minimum libavb version: 1.0\n"
"Header Block: 256 bytes\n"
"Authentication Block: 320 bytes\n"
- "Auxiliary Block: 896 bytes\n"
+ "Auxiliary Block: 960 bytes\n"
"Algorithm: SHA256_RSA2048\n"
"Rollback Index: 4\n"
"Flags: %d\n"
@@ -1223,7 +1223,7 @@
"1 PARTUUID=$(ANDROID_SYSTEM_PARTUUID) "
"PARTUUID=$(ANDROID_SYSTEM_PARTUUID) 4096 4096 257 257 sha1 "
"e811611467dcd6e8dc4324e45f706c2bdd51db67 d00df00d 2 "
- "restart_on_corruption ignore_zero_blocks\" root=0xfd00'\n"
+ "restart_on_corruption ignore_zero_blocks\" root=/dev/dm-0'\n"
" Kernel Cmdline descriptor:\n"
" Flags: 2\n"
" Kernel Cmdline: "
@@ -1255,14 +1255,14 @@
"PARTUUID=1234-fake-guid-for:system_a "
"PARTUUID=1234-fake-guid-for:system_a 4096 4096 257 257 sha1 "
"e811611467dcd6e8dc4324e45f706c2bdd51db67 d00df00d 2 "
- "restart_on_corruption ignore_zero_blocks\" root=0xfd00 "
+ "restart_on_corruption ignore_zero_blocks\" root=/dev/dm-0 "
"should_be_in_both=1 "
"androidboot.vbmeta.device=PARTUUID=1234-fake-guid-for:vbmeta_a "
"androidboot.vbmeta.avb_version=1.0 "
"androidboot.vbmeta.device_state=locked "
- "androidboot.vbmeta.hash_alg=sha256 androidboot.vbmeta.size=1472 "
+ "androidboot.vbmeta.hash_alg=sha256 androidboot.vbmeta.size=1536 "
"androidboot.vbmeta.digest="
- "32572f7a89fb44cc76e9e3adbc0cb5272d0604578b2179729aa52d2bba4061c3",
+ "51ea1638d8cc19a7a15b2bade22d155fb5150a6e376171ea1a89b7d6c89d6f17",
std::string(slot_data->cmdline));
} else {
EXPECT_EQ(
@@ -1270,9 +1270,9 @@
"androidboot.vbmeta.device=PARTUUID=1234-fake-guid-for:vbmeta_a "
"androidboot.vbmeta.avb_version=1.0 "
"androidboot.vbmeta.device_state=locked "
- "androidboot.vbmeta.hash_alg=sha256 androidboot.vbmeta.size=1472 "
+ "androidboot.vbmeta.hash_alg=sha256 androidboot.vbmeta.size=1536 "
"androidboot.vbmeta.digest="
- "bb630c27d09e10117092d4444ea57a99bf44101c46cf5424cfb86928a0873249",
+ "877daa21c04df1d9e1776bc6169c98de947ce44b1b34b545021bb3f34e287da6",
std::string(slot_data->cmdline));
}
avb_slot_verify_data_free(slot_data);
@@ -1393,7 +1393,7 @@
" Kernel Cmdline: 'dm=\"1 vroot none ro 1,0 32768 verity 1 "
"PARTUUID=$(ANDROID_SYSTEM_PARTUUID) PARTUUID=$(ANDROID_SYSTEM_PARTUUID) "
"4096 4096 4096 4096 sha1 c9ffc3bfae5000269a55a56621547fd1fcf819df "
- "d00df00d 2 restart_on_corruption ignore_zero_blocks\" root=0xfd00'\n"
+ "d00df00d 2 restart_on_corruption ignore_zero_blocks\" root=/dev/dm-0'\n"
" Kernel Cmdline descriptor:\n"
" Flags: 2\n"
" Kernel Cmdline: "
@@ -1450,13 +1450,13 @@
"dm=\"1 vroot none ro 1,0 32768 verity 1 "
"PARTUUID=1234-fake-guid-for:system PARTUUID=1234-fake-guid-for:system "
"4096 4096 4096 4096 sha1 c9ffc3bfae5000269a55a56621547fd1fcf819df "
- "d00df00d 2 restart_on_corruption ignore_zero_blocks\" root=0xfd00 "
+ "d00df00d 2 restart_on_corruption ignore_zero_blocks\" root=/dev/dm-0 "
"androidboot.vbmeta.device=PARTUUID=1234-fake-guid-for:boot "
"androidboot.vbmeta.avb_version=1.0 "
"androidboot.vbmeta.device_state=locked "
"androidboot.vbmeta.hash_alg=sha256 androidboot.vbmeta.size=5312 "
"androidboot.vbmeta.digest="
- "403b4071873ca54187ca2c33e314edf3049ccb6cfadf518d7f6a509fce3d18b3",
+ "87bf39949a560f93d54aa0a5e9d158439110141246e40fb103f131633a3ca456",
std::string(slot_data->cmdline));
avb_slot_verify_data_free(slot_data);
}
diff --git a/test/avbtool_unittest.cc b/test/avbtool_unittest.cc
index f060862..8df5f26 100644
--- a/test/avbtool_unittest.cc
+++ b/test/avbtool_unittest.cc
@@ -858,7 +858,7 @@
" Kernel Cmdline: 'dm=\"1 vroot none ro 1,0 2056 verity 1 "
"PARTUUID=$(ANDROID_SYSTEM_PARTUUID) PARTUUID=$(ANDROID_SYSTEM_PARTUUID) "
"4096 4096 257 257 sha1 e811611467dcd6e8dc4324e45f706c2bdd51db67 "
- "d00df00d 2 restart_on_corruption ignore_zero_blocks\" root=0xfd00'\n"
+ "d00df00d 2 restart_on_corruption ignore_zero_blocks\" root=/dev/dm-0'\n"
" Kernel Cmdline descriptor:\n"
" Flags: 2\n"
" Kernel Cmdline: "
@@ -1089,7 +1089,7 @@
"d00df00d 10 restart_on_corruption ignore_zero_blocks "
"use_fec_from_device "
"PARTUUID=$(ANDROID_SYSTEM_PARTUUID) fec_roots 2 fec_blocks 261 "
- "fec_start 261\" root=0xfd00'\n"
+ "fec_start 261\" root=/dev/dm-0'\n"
" Kernel Cmdline descriptor:\n"
" Flags: 2\n"
" Kernel Cmdline: "