Merge "libstatssocket_lazy: add isAvailable()" into main
diff --git a/init/property_service.cpp b/init/property_service.cpp
index d3cdd43..cd5933d 100644
--- a/init/property_service.cpp
+++ b/init/property_service.cpp
@@ -974,6 +974,17 @@
std::string build_fingerprint = GetProperty("ro.product.brand", UNKNOWN);
build_fingerprint += '/';
build_fingerprint += GetProperty("ro.product.name", UNKNOWN);
+
+ // should be set in /product/etc/build.prop
+ // when we have a dev option device, and we've switched the kernel to 16kb mode
+ // we use the same system image, but we've switched out the kernel, so make it
+ // visible at a high level
+ bool has16KbDevOption =
+ android::base::GetBoolProperty("ro.product.build.16k_page.enabled", false);
+ if (has16KbDevOption && getpagesize() == 16384) {
+ build_fingerprint += "_16kb";
+ }
+
build_fingerprint += '/';
build_fingerprint += GetProperty("ro.product.device", UNKNOWN);
build_fingerprint += ':';
diff --git a/init/test_upgrade_mte/AndroidTest.xml b/init/test_upgrade_mte/AndroidTest.xml
index b89cde8..e08afc0 100644
--- a/init/test_upgrade_mte/AndroidTest.xml
+++ b/init/test_upgrade_mte/AndroidTest.xml
@@ -20,11 +20,13 @@
<target_preparer class="com.android.tradefed.targetprep.PushFilePreparer">
<option name="cleanup" value="true" />
<option name="remount-system" value="true" />
- <option name="push" value="mte_upgrade_test.rc->/system/etc/init/mte_upgrade_test.rc" />
- <option name="push" value="mte_upgrade_test_helper->/system/bin/mte_upgrade_test_helper" />
- <option name="push" value="mte_upgrade_test_helper->/data/local/tmp/app_process64" />
+
+ <option name="push-file" key="mte_upgrade_test.rc" value="/system/etc/init/mte_upgrade_test.rc" />
+ <option name="push-file" key="mte_upgrade_test_helper" value="/system/bin/mte_upgrade_test_helper" />
+ <option name="push-file" key="mte_upgrade_test_helper" value="/data/local/tmp/app_process64" />
+ <option name="post-push" value="chmod 644 /system/etc/init/mte_upgrade_test.rc" />
</target_preparer>
<test class="com.android.tradefed.testtype.HostTest" >
<option name="jar" value="mte_upgrade_test.jar" />
</test>
-</configuration>
\ No newline at end of file
+</configuration>
diff --git a/init/test_upgrade_mte/OWNERS b/init/test_upgrade_mte/OWNERS
new file mode 100644
index 0000000..79625df
--- /dev/null
+++ b/init/test_upgrade_mte/OWNERS
@@ -0,0 +1,5 @@
+fmayer@google.com
+
+eugenis@google.com
+mitchp@google.com
+pcc@google.com
diff --git a/init/test_upgrade_mte/mte_upgrade_test_helper.cpp b/init/test_upgrade_mte/mte_upgrade_test_helper.cpp
index 6728cc6..c4b175a 100644
--- a/init/test_upgrade_mte/mte_upgrade_test_helper.cpp
+++ b/init/test_upgrade_mte/mte_upgrade_test_helper.cpp
@@ -22,6 +22,7 @@
#include <sys/prctl.h>
#include <time.h>
#include <unistd.h>
+
#include <memory>
int MaybeDowngrade() {
@@ -65,7 +66,5 @@
// This binary gets run by src/com/android/tests/init/MteUpgradeTest.java, which
// asserts that it crashes as expected.
f[17] = 'x';
- char buf[1];
- read(1, buf, 1);
return 0;
}
diff --git a/mkbootfs/mkbootfs.c b/mkbootfs/mkbootfs.c
index d3922bf..84a0a4e 100644
--- a/mkbootfs/mkbootfs.c
+++ b/mkbootfs/mkbootfs.c
@@ -402,7 +402,7 @@
static void usage(void)
{
fprintf(stderr,
- "Usage: mkbootfs [-n FILE] [-d DIR|-F FILE] DIR...\n"
+ "Usage: mkbootfs [-n FILE] [-d DIR|-f FILE] DIR...\n"
"\n"
"\t-d, --dirname=DIR: fs-config directory\n"
"\t-f, --file=FILE: Canned configuration file\n"
@@ -410,11 +410,11 @@
"\t-n, --nodes=FILE: Dev nodes description file\n"
"\n"
"Dev nodes description:\n"
- "\t[dir|nod] [perms] [uid] [gid] [c|b] [minor] [major]\n"
+ "\t[dir|nod] [perms] [uid] [gid] [c|b] [major] [minor]\n"
"\tExample:\n"
"\t\t# My device nodes\n"
"\t\tdir dev 0755 0 0\n"
- "\t\tnod dev/null 0600 0 0 c 1 5\n"
+ "\t\tnod dev/null 0600 0 0 c 1 3\n"
);
}
@@ -445,11 +445,6 @@
int num_dirs = argc - optind;
argv += optind;
- if (num_dirs <= 0) {
- usage();
- errx(1, "no directories to process?!");
- }
-
while(num_dirs-- > 0){
char *x = strchr(*argv, '=');
if(x != 0) {