Revert "Make init re-exec itself for its SELinux domain transition."
shamu isn't booting.
This reverts commit adf0d1bbfa4bc560c2106f14afa8258a11c48bf6.
Change-Id: I89d568838cebbe14cc4a8ae3843f0f1ac54987af
diff --git a/rootdir/init.rc b/rootdir/init.rc
index 4d9c4f3..a5ea60a 100644
--- a/rootdir/init.rc
+++ b/rootdir/init.rc
@@ -14,6 +14,13 @@
# Set init and its forked children's oom_adj.
write /proc/1/oom_score_adj -1000
+ # Apply strict SELinux checking of PROT_EXEC on mmap/mprotect calls.
+ write /sys/fs/selinux/checkreqprot 0
+
+ # Set the security context for the init process.
+ # This should occur before anything else (e.g. ueventd) is started.
+ setcon u:r:init:s0
+
# Set the security context of /adb_keys if present.
restorecon /adb_keys