apexd: Activates apexes in parallel

Activates apexes in parallel on multi-core devices to reduce the boot
time.

- add a mutex for mounted_apexes_
- add a mutex for getting free loopback device
- seperate activatePackageImpl() from ActivateApexPackages()
- run activatePackageImpl() asynchronously

Test: build pass
Test: boot on device and cuttlefish
Test: atest ApexTestCases passed on Cuttlefish
Signed-off-by: Suchang Woo <suchang.woo@samsung.com>
Change-Id: I80ccdd5f13c160b996132761e947bf62fdf64e44
4 files changed