Extend the process_madvise() docs.
In particular, explain why we don't have process_mremove(), and why
adding this was probably a mistake (lest it be used as precedent for
similar bad decisions in future).
Also add the missing __INTRODUCED_IN().
Test: treehugger
Change-Id: Ic2d7ef32f6e288353b5be2bffd000ad2f501bf39
diff --git a/libc/include/sys/mman.h b/libc/include/sys/mman.h
index 6ef0c12..9e865a3 100644
--- a/libc/include/sys/mman.h
+++ b/libc/include/sys/mman.h
@@ -168,8 +168,13 @@
* PID file descriptor.
*
* Returns the number of bytes advised on success, and returns -1 and sets `errno` on failure.
+ *
+ * Available since API level 31. Its sibling process_mrelease() does not have a
+ * libc wrapper and should be called using syscall() instead. Given the lack of
+ * widespread applicability of this system call and the absence of wrappers in
+ * other libcs, it was probably a mistake to have added this wrapper to bionic.
*/
-ssize_t process_madvise(int __pid_fd, const struct iovec* __iov, size_t __count, int __advice, unsigned __flags);
+ssize_t process_madvise(int __pid_fd, const struct iovec* __iov, size_t __count, int __advice, unsigned __flags) __INTRODUCED_IN(31);
#if defined(__USE_GNU)