Iliyan Malchev
670d1eb23b
Merge "init: account for "init.svc." prefix in IsValidName" am: 8cf0bd75f7 am: 6b03c273b1 am: 68a9f5a14f
...
am: 5115f1c77a
Change-Id: Idfd3bb1f56023a5a8e061b93554f3e855c09584b
2016-10-24 17:48:57 +00:00
Iliyan Malchev
6b03c273b1
Merge "init: account for "init.svc." prefix in IsValidName"
...
am: 8cf0bd75f7
Change-Id: I41c9d2472412a4b4cafb23a39598ea0e31619629
2016-10-24 17:38:21 +00:00
Iliyan Malchev
00860da2f0
init: account for "init.svc." prefix in IsValidName
...
For each service ${service} described in a .rc file, init creates the
property init.svc.${service}. This implies that service-name lengths
are bound by the maximum size of a property. This patch accounts for
the "init.svc." prefix and the maximum property-name length when
validating a service name.
Test: pass
Change-Id: I32dffa37363b41a8211f7644600b81973d30a3b2
Signed-off-by: Iliyan Malchev <malchev@google.com>
2016-10-24 08:46:06 -07:00
Yabin Cui
1051e107f2
init: use libbootloader_message.
...
Bug: 29582118
Change-Id: I6285b29774a11d6dda8496c7c73e4c1d17a672bd
(cherry picked from commit 0b1252cca0 )
2016-10-18 11:37:52 -07:00
Elliott Hughes
71f74a8aba
resolve merge conflicts of a4398c1 to stage-aosp-master am: 195669febc am: b2ab1c43cb
...
am: 7948a33f2c
Change-Id: Ifeeac2d6aa9e1c36477599db0edf0e5158473555
2016-10-14 03:07:24 +00:00
Elliott Hughes
7948a33f2c
resolve merge conflicts of a4398c1 to stage-aosp-master am: 195669febc
...
am: b2ab1c43cb
Change-Id: I412943235ad6cd908aca04c56aa19a3d2bbb5413
2016-10-14 02:55:55 +00:00
Elliott Hughes
da46b392f1
Move off std::sto* function which abort on failure.
...
Bug: http://b/31403370
Test: builds, boots, libbase tests pass
Change-Id: I89cd7ca3d8f1c8a1bad0ddf3043439449d19a293
2016-10-13 15:34:05 -07:00
Tao Bao
6efc7a787b
Merge "Update the header path for ext4_utils." am: 5bc3ce85cf am: 148b85b050
...
am: 2815ac5584
Change-Id: I966296de6eb4ff7518b9cfcd5853fe919765b826
2016-10-10 22:14:48 +00:00
Tao Bao
0cc93194eb
Merge "Update the header path for ext4_utils."
2016-10-10 16:44:40 +00:00
Glenn Kasten
a3d98bc62e
Merge "Traverse /etc/init in a well-defined order" am: db7715c7dd am: 31dcb81e63 am: 010624bd2c
...
am: af97f66b59
Change-Id: Ib13e0e5a02db8719fa8fc3edea7db6fcd5f95ed3
2016-10-09 18:12:41 +00:00
Tao Bao
27663171e0
Update the header path for ext4_utils.
...
Test: `mmma system/core`
Change-Id: I6291d10d6c8d4972aeca55596baa83f555496193
(cherry picked from commit 6d881d6db4 )
2016-10-09 10:51:49 -07:00
Glenn Kasten
af97f66b59
Merge "Traverse /etc/init in a well-defined order" am: db7715c7dd am: 31dcb81e63
...
am: 010624bd2c
Change-Id: Ie8c3467d5bb286bbdacb8479c62d2f52fef246df
2016-10-09 17:26:37 +00:00
Tao Bao
6d881d6db4
Update the header path for ext4_utils.
...
Test: `mmma system/core`
Change-Id: I6291d10d6c8d4972aeca55596baa83f555496193
2016-10-09 10:23:36 -07:00
Glenn Kasten
2de796491a
Traverse /etc/init in a well-defined order
...
Bug: 31996208
Test: will need a CTS, not yet done
Change-Id: I5ecc7f0519d42a83065b7b97a31cdb5b33549cda
2016-10-07 13:56:37 -07:00
Wei Wang
46a59f8e07
Merge "Modify log level for service and ueventd" am: 891d0ba904 am: 42335b04b4
...
am: 06515d3231
Change-Id: Ie15a869062ef43f1c4ef2fb1540836971fa23363
2016-10-05 04:42:16 +00:00
Wei Wang
a285dac9c0
Modify log level for service and ueventd
...
Bug: 31938558
Test: flash and take a boot log
Change-Id: I5c6823614e1df760128519dfb294f3a44efa6bac
2016-10-04 14:50:48 -07:00
Wei Wang
dc9946f17c
Modify log level for service and ueventd
...
Bug: 31938558
Test: flash and take a boot log
Change-Id: I5c6823614e1df760128519dfb294f3a44efa6bac
2016-10-04 14:33:23 -07:00
Elliott Hughes
082b4efc41
Merge "Log failed load_properties_from_file calls." am: 57513bd5a3 am: 9abb85ebe0 am: 6d60731271
...
am: 5c54bb548a
Change-Id: Ie392c70cd6117fcdb7f36dd0bd77f59f56e846bc
2016-10-01 01:25:48 +00:00
Elliott Hughes
5c54bb548a
Merge "Log failed load_properties_from_file calls." am: 57513bd5a3 am: 9abb85ebe0
...
am: 6d60731271
Change-Id: I603025e42824e11817042d98ad7a7387b83fe99c
2016-10-01 01:23:18 +00:00
Elliott Hughes
5a7ad84ede
Log failed load_properties_from_file calls.
...
These events are _somewhat_ normal, in that not all devices have all
partitions, but not logging anything makes it unnecessarily hard for
folks to debug simple failures.
Bug: http://b/31186390
Test: booted, checked dmesg
Change-Id: I403377c585ea35cfe73b0bed9443b75e3a84dc8d
2016-09-30 16:30:00 -07:00
Wei Wang
d61a7e2da4
Split fstab mount into 2 phases
...
This will make it possible to start some key services before mounting
data partition
Bug: 30118894
Change-Id: Ia9f8cc035de6cc0df9a61605864915efa0266d7f
(cherry picked from commit abfbec342f )
2016-09-06 21:04:26 +00:00
Wei Wang
254f44363b
Split fstab mount into 2 phases
...
This will make it possible to start some key services before mounting
data partition
(cherry picked from commit abfbec342f )
Bug: 30118894
Change-Id: Ia9f8cc035de6cc0df9a61605864915efa0266d7f
2016-09-06 11:39:05 -07:00
Wei Wang
dee31eced5
Merge "Split fstab mount into 2 phases"
2016-09-06 18:23:55 +00:00
Wei Wang
abfbec342f
Split fstab mount into 2 phases
...
This will make it possible to start some key services before mounting
data partition
Bug: 30118894
Change-Id: Ia9f8cc035de6cc0df9a61605864915efa0266d7f
2016-09-02 18:11:06 -07:00
Elliott Hughes
b24ddfc8c5
Merge "Use android::base::Readlink in init." am: 31ea86327e am: 72887a3ff4 am: 0a2148e34d
...
am: 87e43e1627
Change-Id: I358ab23cc6fc164d4d362e9fd54626fd01206a2e
2016-09-02 19:54:09 +00:00
Elliott Hughes
87e43e1627
Merge "Use android::base::Readlink in init." am: 31ea86327e am: 72887a3ff4
...
am: 0a2148e34d
Change-Id: Ifcd35961c8bf6e5a34f70dbf1717190a519f0b3b
2016-09-02 19:46:38 +00:00
Treehugger Robot
31ea86327e
Merge "Use android::base::Readlink in init."
2016-09-02 19:37:02 +00:00
Marco Nelissen
f73b1ac0fd
Merge "Allow setting oom_score_adj for services spawned from init" am: b7aef300c4 am: 5969a3f780 am: 25e26708f6
...
am: 558217ed43
Change-Id: I6c99e6fd7fa69745363644e91147556c6b903f13
2016-09-02 15:02:55 +00:00
Marco Nelissen
558217ed43
Merge "Allow setting oom_score_adj for services spawned from init" am: b7aef300c4 am: 5969a3f780
...
am: 25e26708f6
Change-Id: I55c46391eb357a84fb9f1afc66227ef90a82d30b
2016-09-02 14:59:25 +00:00
Josh Gao
c1b793b721
Merge "Revert "init: create /dev/urandom, /dev/random in first stage."" am: 37686d446d am: 8196f4cdd9 am: 1181a4a54c
...
am: fe64538014
Change-Id: I275c47b25bfc83d60eb617f2156789233da7f0f8
2016-09-02 08:55:36 +00:00
Josh Gao
fe64538014
Merge "Revert "init: create /dev/urandom, /dev/random in first stage."" am: 37686d446d am: 8196f4cdd9
...
am: 1181a4a54c
Change-Id: Ib1080f9749ebca0aa7eb73380b1903d170b918bd
2016-09-02 08:52:05 +00:00
Josh Gao
4c8a76e250
Revert "init: create /dev/urandom, /dev/random in first stage."
...
This reverts commit ab4fbe1b4f .
Bug: http://b/31251721
Change-Id: I43e68d1bd819d0f9f7d107865a33ec892975d956
2016-09-02 08:39:39 +00:00
Josh Gao
3c206b460e
Merge "init: create /dev/urandom, /dev/random in first stage." am: 9baf4e94fa am: 344e2b307b am: b9cd3c2213
...
am: b093053868
Change-Id: Ib723f29bc4bf939ab0798e05ebf57e841233f4e6
2016-09-01 23:12:10 +00:00
Josh Gao
b093053868
Merge "init: create /dev/urandom, /dev/random in first stage." am: 9baf4e94fa am: 344e2b307b
...
am: b9cd3c2213
Change-Id: Ief1121d9e0c8161dd975b9a9f4ce33fb0313cecf
2016-09-01 23:08:30 +00:00
Marco Nelissen
310f6704d0
Allow setting oom_score_adj for services spawned from init
...
(cherry picked from commit f7adf8e4739812a2a4f194b17f84f4b9df42d04b)
Bug: 29831602
Change-Id: I4d24264bb6e879935a0b2adbb2e49ddf458980cf
2016-09-01 08:23:28 -07:00
Jorge Lucangeli Obes
83033153a4
Merge "Add description of 'namespace' option." am: 4588ed7b5f am: 52807711fe am: ce44aa8487
...
am: 6ccc8323b2
Change-Id: Idf1a83dcff90425d20c4f1dd1a7dff10795bce42
2016-09-01 01:56:06 +00:00
Josh Gao
ab4fbe1b4f
init: create /dev/urandom, /dev/random in first stage.
...
Create /dev/random and /dev/urandom in the first stage, so that when we
reexec, arc4random is available for libc initialization.
Bug: http://b/29622562
Change-Id: I5b2071539a17eec609faac91dc28b08eba5ff89b
2016-08-31 15:36:37 -07:00
Elliott Hughes
f39f7f1428
Use android::base::Readlink in init.
...
Bug: http://b/30988271
Change-Id: Ia0000e9dd7883c31ccbd54fc01bf585c3f8b3fa7
2016-08-31 14:44:41 -07:00
Jorge Lucangeli Obes
6ccc8323b2
Merge "Add description of 'namespace' option." am: 4588ed7b5f am: 52807711fe
...
am: ce44aa8487
Change-Id: Ib2ef76efd778706992057d8ecbc868e1a1bf65c5
2016-08-31 21:11:18 +00:00
Jorge Lucangeli Obes
cd2518c19c
Add description of 'namespace' option.
...
Bug: None
Change-Id: Ib71005eb9823c7511b07d4060d08411ce3d0a8f0
2016-08-31 15:23:44 -04:00
Elliott Hughes
5367fcf1c2
Merge "Most accept/accept4 calls in system/core don't actually want the remote address." am: 299d64144b am: 8615d79d85 am: 66e5e2432a
...
am: 0426ecaf82
Change-Id: I46d13d9b9c647511566611b58d7862c0daefc8c6
2016-08-23 23:17:50 +00:00
Elliott Hughes
0426ecaf82
Merge "Most accept/accept4 calls in system/core don't actually want the remote address." am: 299d64144b am: 8615d79d85
...
am: 66e5e2432a
Change-Id: I5d7b98fa3e9c2d8c16a1aa73e3d5a197dc150c2b
2016-08-23 23:14:44 +00:00
Elliott Hughes
8615d79d85
Merge "Most accept/accept4 calls in system/core don't actually want the remote address."
...
am: 299d64144b
Change-Id: I3fb9678dfed08f0b1d6e90e547ecae6cdcabc9a1
2016-08-23 23:03:20 +00:00
Elliott Hughes
3dcfa3fb1c
Most accept/accept4 calls in system/core don't actually want the remote address.
...
So don't write the extra code for it or waste the kernel's time
copying it around.
Change-Id: I93de64064c2d4fe58ba5b5322cfa69bf31a76dad
2016-08-23 12:50:00 -07:00
Hung-ying Tyan
dd827f6f35
Merge "Mount /vendor and /odm early" am: 35569e9d68 am: 46bfc918d0 am: d1f49a43fd
...
am: 1263097328
Change-Id: Ib4288d3f927b0c893e79b5eb4b4a5b282148c5d8
2016-08-18 05:13:40 +00:00
Hung-ying Tyan
1263097328
Merge "Mount /vendor and /odm early" am: 35569e9d68 am: 46bfc918d0
...
am: d1f49a43fd
Change-Id: I6dc53f60771ad0e660e248efdc1b13734fba3061
2016-08-18 05:10:41 +00:00
Hung-ying Tyan
46bfc918d0
Merge "Mount /vendor and /odm early"
...
am: 35569e9d68
Change-Id: I9b5360bf3036fa88e770d686ab06b8f4cff80d7c
2016-08-18 05:04:43 +00:00
Hung-ying Tyan
99c4a8a6b3
Mount /vendor and /odm early
...
Right now these two partitions are mounted in the fs stage of the init
process. As a result, many vendor/ODM files needed earlier in the boot
process (e.g., init.<hardware>.rc, fstab.<hardware>.rc,
uevent.<hardware>.rc, SELinux policy files etc) can only live on the root
partition.
To prevent vendors/ODMs from polluting the root partition, this patch makes
it possible to mount the vendor and ODM partitions in the first stage of the
init process. The fstab info of both partitions to be mounted early is
composed from new kernel cmdline arguments android.early.prefix and
android.early.fstab.
For example, with:
android.early.prefix=/sys/devices/1010000.msdc0/mmc_host/mmc0/mmc0:0001/block/mmcblk0/
android.early.fstab=mmcblk0p10+/odm+ext4+ro+verify\nmmcblk0p09+/vendor+ext4+ro+verify
the final fstab string will be:
/sys/devices/1010000.msdc0/mmc_host/mmc0/mmc0:0001/block/mmcblk0/mmcblk0p10 /odm ext4 ro verify
/sys/devices/1010000.msdc0/mmc_host/mmc0/mmc0:0001/block/mmcblk0/mmcblk0p09 /vendor ext4 ro verify
The android.early.prefix is optional. When it is missing, the final fstab
string will be directly converted from android.early.fstab.
This patch also makes sure that the early mounted partitions are dm-verity
enabled so that they are trust worthy to store system files.
BUG=27805372
Change-Id: I3cf32482a5ec65445ba3aedab2164c7ba8f12694
2016-08-17 17:21:35 +08:00
Josh Gao
18bbf6b815
Merge "libcrypto_utils: convert to Soong." am: c1a9a21ffe am: 87ef590bc1 am: a1da027a3c
...
am: 7480771909
Change-Id: Id916c7750665df53bea0c77e3628d9fbff6562a5
2016-08-08 18:41:51 +00:00
Josh Gao
7480771909
Merge "libcrypto_utils: convert to Soong." am: c1a9a21ffe am: 87ef590bc1
...
am: a1da027a3c
Change-Id: Ie693d3de13b0df24ea83e70af3fa385a77ed8b33
2016-08-08 18:39:23 +00:00