fs_mgr: pass sehandle to ext4 format routine
When fs_mgr_do_format() is executed, fs_mgr creates a new
blank data file system. However, that filesystem is not
labeled and causes some unlabeled denials on early boot.
Example Denial:
avc: denied { search } for pid=2535 comm="logd" name="/" dev="mmcblk0p9" ino=2 scontext=u:r:logd:s0 tcontext=u:object_r:unlabeled:s0 tclass=dir permissive=1
To correct this, pass sehandle to the internal ext4 routine.
This way the ext4 filesystem will be labeled at creation and
the root inode will have a label.
Change-Id: Ieeecaa8bbc258e6d743d281dd956bdaca98b365f
Signed-off-by: William Roberts <william.c.roberts@intel.com>
diff --git a/fs_mgr/Android.mk b/fs_mgr/Android.mk
index d0d5630..7da3ca4 100644
--- a/fs_mgr/Android.mk
+++ b/fs_mgr/Android.mk
@@ -10,7 +10,8 @@
libcrypto_utils_static \
libcrypto_static \
libext4_utils_static \
- libsquashfs_utils
+ libsquashfs_utils \
+ libselinux
include $(CLEAR_VARS)
LOCAL_CLANG := true