Add more headroom for ext4 app package containers.

Code in the volume daemon that creates the filesystem image to contain
an installed application package currently adds about 1.6% to the
size estimate that is passed down to it to account for filesystem
overhead. That figure is based upon an assumption that the filesystem
is of type FAT, but is insufficient for some big application packages
when the filesystem is of type ext4.

This change checks the filesystem type, and in the case where it's
ext4, adds about 6% to the input estimate to account for journaling,
etc.

Change-Id: I261fa7ee2bc7e8ea37c3d0bfd3be00c9917a6f9f
Signed-off-by: Tom Keel <thomas.keel@intel.com>
Fix Vold to properly handle full-disk file systems

(full-disk: no partitions)

In Android, Vold recognizes a USB drive having a full-disk file system
and mounts it properly, but when the drive is removed from system Vold
won't unmount the device. This is because Vold only unmounts partitions.
For a FAT32 USB drive (with partitions), kernel will create two devices:
sda (disk device) and sda1 (partition device). When the drive is removed,
Vold will receive two netlink events: one for partition remove (sda1)
and one for disk remove (sda). The unmount occurs only when partition
remove event is received.
For a full-disk FS USB drive, kernel will only create one device: sda
(disk device). When the drive is removed, Vold will only receive one
netlink event for disk remove (sda) and it won't unmount the device.

This patch will verify if there is a currently mounted device when disk
remove event is received and will perform unmount, to properly unmount
the device.

Change-Id: I4866ab2482fddfb40a8fc73083f31df846bbb24f
Signed-off-by: Robert Chiras <robert.chiras@intel.com>
f2fs: disable fsck check

fsck.f2fs does not fix any inconsistencies "yet".

Disable fsck routine as this is just wasting time consumed to mount f2fs volumes.

The kernel can determine if a f2fs volume is too damaged that it shouldn't get mounted.

We should wait for f2fs-tools version higher than v1.3.0.
(fsck.f2fs for fixing inconsistencies is a work-in-progress)

References:
https://github.com/torvalds/linux/blob/master/Documentation/filesystems/f2fs.txt#L261
https://git.kernel.org/cgit/linux/kernel/git/jaegeuk/f2fs-tools.git

Change-Id: I7e0a4662ac70860fe139bb9331b7aee1ad76220f
Signed-off-by: Park Ju Hyung <qkrwngud825@gmail.com>