Move __system_properties_reload to LIBC from LIBC_PLATFORM
The zygote cannot have visiblity to LIBC_PLATFORM methods. Therefore,
move __system_properties_reload to LIBC, and rename it
__system_properties_zygote_reload, and indicate in comments that it
should not be used by non-zygote apps
Bug: 291814949
Test: atest CtsBionicRootTestCases
Change-Id: Iee8fa0c76b740543c05a433393f2f4bef36d6d3d
diff --git a/libc/include/sys/_system_properties.h b/libc/include/sys/_system_properties.h
index 098f355..30dea89 100644
--- a/libc/include/sys/_system_properties.h
+++ b/libc/include/sys/_system_properties.h
@@ -131,13 +131,15 @@
/*
* Reloads the system properties from disk.
+ * Not intended for use by any apps except the Zygote. Should only be called from the main thread.
*
* NOTE: Any pointers received from methods such as __system_property_find should be assumed to be
* invalid after this method is called.
*
- * Returns 0 on success, -1 otherwise
+ * Returns 0 on success, -1 if the system properties failed to re-initialize (same conditions as
+ * __system properties_init)
*/
-int __system_properties_reload();
+int __system_properties_zygote_reload(void); __INTRODUCED_IN(__ANDROID_API_V__)
/* Deprecated: use __system_property_wait instead. */
uint32_t __system_property_wait_any(uint32_t __old_serial);