summaryrefslogtreecommitdiffstats
path: root/init/host_init_stubs.cpp
Commit message (Collapse)AuthorAgeFilesLines
* init: Use sepolicy version insteadLogan Chien2018-05-041-0/+4
| | | | | | | | | | | | | | | | | | | | This commit uses vendor sepolicy file version (defined in `/vendor/etc/selinux/plat_sepolicy_vers.txt`) to determine whether the source context should be set as `u:r:vendor_init:s0`. Before this commit, the criterion was `ro.vndk.version` >= 28. However, the check in `property_service.cpp` will always be true because `ro.vndk.version` hasn't been loaded from `/vendor/default.prop`. Furthermore, under some circumstances, `ro.vndk.version` may be different from `plat_sepolicy_vers.txt` (e.g. O-MR1 vendor does not define `ro.vndk.version`). Bug: 78605339 # high-level bug to combine O-MR1 and P GSI Bug: 79135481 # the usage of `ro.vndk.version` in init Test: vts-tradefed run vts -m VtsTrebleVintfTest # tetheroffload Change-Id: Ied46e9346b4ca7931aa4dcf1c9dbc11de0e12d93 Merged-In: Ied46e9346b4ca7931aa4dcf1c9dbc11de0e12d93
* Clean up property set error handlingTom Cherry2018-03-011-2/+2
| | | | | | | | | | | | | | | Currently we only report why a property set call has failed but drop the context of what was trying to set the property. This change adds information about why a property was trying to be set when it fails. It also unifies property_set() within init to go through the same HandlePropertySet() function as normal processes do, removing unneeded special cases. Test: boot bullhead Test: attempt to set invalid properties and see better error messages Change-Id: I5cd3a40086fd3b226e9c8a5e3a84cb3b31399c0d
* init: add host side parser for initTom Cherry2018-02-281-0/+59
Create a host side parser for init such that init rc files can be verified for syntax correctness before being used on the device. Bug: 36970783 Test: run the parser on init files on host Change-Id: I7e8772e278ebaff727057308596ebacf28b6fdda