summaryrefslogtreecommitdiffstats
path: root/init
Commit message (Collapse)AuthorAgeFilesLines
* Close the client socket early for ctl.* properties.Brad Fitzpatrick2011-04-011-5/+9
| | | | | Bug: 4199411 Change-Id: I3bf335e16e0df8405c538989a8f4f6db7795fa36
* Close the property socket *after* updating properties.Brad Fitzpatrick2011-03-301-10/+6
| | | | | | | | | Also remove some dead code. Bionic update is in change I3e80cecf Bug: 4185486 Change-Id: I28e06197ff7a452c70b89b9fc5e2bcf0d9d54bbe
* Load the persistent properties after decrypting the /data partitionKen Sumrall2011-03-105-1/+26
| | | | | | | | | | | | Fix for bug 3415286. The persistent properties are normally read early in the boot process after /data is mounted. However, for an encrypted system, at that point /data is a tmpfs ramdisk. This change adds a new command to init (load_persist_props) to read the persistent properties, and adds an action to init.rc to load the persistent properties. This action is triggered by setting a property in vold, but that's in a different CL. Change-Id: I74b3057974ee6029c29d956b76fef5566700d471
* Try to unmount writable filesystems when rebootingKen Sumrall2011-03-101-4/+2
| | | | | | | | | | | | | | | Ext4 filesystems like to be unmounted before rebooting. The Android system doesn't have a traditional Linux init setup, and shutting down the system was not much more than calling sync(2) and reboot(2). This adds a new function to libcutils called android_reboot(). By default, it calls sync() and then remounts all writable filesystems as read-only and marks them clean. There is a flag parameter in which the caller can ask for sync() not to be called, or to not remount the filesystems as read-only. Then it will call reboot(2) as directed by the other parameters. This change also updates adb, init and toolbox to call the new android_reboot() function. Fixes bugs 3350709 and 3495575. Change-Id: I16d71ffce3134310d7a260f61ec6f4dd204124a7
* property_service: Give radio permission to set net.qmi*Amol Bhatkar2011-03-021-0/+1
| | | | Change-Id: I771ef22859799b863ab79de9d3248ef610af4dd8
* Fix for bug 3379244, non-eMMC devices don't start all services.Ken Sumrall2011-02-171-9/+21
| | | | | | | Fix for non-eMMC based devices to properly start the "on nonencrypted" action. Change-Id: I5d2966db352b02f1a1724fb105e1cefc46037e42
* Add the commands rm and rmdir to init.Ken Sumrall2011-01-183-0/+16
| | | | | | | rm only removes a single non-directory directory entry (no -r support) rmdir removes a single empty directory Change-Id: I49702b02ba98a177027b126268c2c2846f968195
* Set a read-only property to indicate if the device is running encrypted.Ken Sumrall2011-01-141-0/+2
| | | | | | | The UI needs to know if the device is running with an encrypted filesystem or now. So set a read-only property at boot to let it know. Change-Id: I753de2d606c975bcbe9946d10fd47558cf357dac
* init: Fix parser line numberingBruce Beare2011-01-072-5/+9
| | | | Change-Id: I1ac481a2cef749b26c73bc9e6a212e6ace7a0ae2
* am bf10797e: am f7ca6040: Fix infinite loop in init when debugging is turned offColin Cross2011-01-041-6/+6
|\ | | | | | | | | * commit 'bf10797e538f9fa252d72710bd5ecf0ef1f6f3e0': Fix infinite loop in init when debugging is turned off
| * am f7ca6040: Fix infinite loop in init when debugging is turned offColin Cross2011-01-041-6/+6
| |\ | | | | | | | | | | | | * commit 'f7ca6040616f672a6f0039d55e39c610b7c1cf91': Fix infinite loop in init when debugging is turned off
| | * Fix infinite loop in init when debugging is turned offColin Cross2011-01-041-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If a keychord is pressed when debugging is turned off, the main event poll in init will return an event on the keychord fd, but handle_keychord never reads the data. Once this happens, the poll will always return immediately, and init enters an infinite loop. Fix it by always reading from the keychord fd, but only handling the returned keychord if debugging is enabled. Change-Id: Ie4efa98247d3cc978d275dc8a4516b32aa710278
* | | Changes to init to support encrypted filesystems.Ken Sumrall2010-12-186-8/+80
| | | | | | | | | | | | | | | | | | | | | | | | | | | These are the changes to init and init.rc necessary to support booting with and encrypted /data filesystem. A corresponding change to init.<device>.rc goes along with this change. Change-Id: I0c7e2cc39568358014a82e317735c0eae14dd683
* | | init: Allow non-root adbd to switch between TCP and USB modesMike Lockwood2010-12-101-0/+1
| | | | | | | | | | | | | | | Change-Id: I9e93ceefadfaa2a4f8ec25cfa05fa4821fd98093 Signed-off-by: Mike Lockwood <lockwood@android.com>
* | | Revert "Add "slow_start" keyword to init"Iliyan Malchev2010-12-084-10/+0
| | | | | | | | | | | | This reverts commit 50b3afd9f39619f69dc6f4efc29be88933eb3614.
* | | Add "slow_start" keyword to initPaul Eastham2010-12-044-0/+10
| | | | | | | | | | | | | | | | | | | | | This keyword will cause init to wait a few seconds before exec'ing the target binary. Maybe only useful for hacks and debugging. Change-Id: I85caa0bcbc0be7e48bd21eb9e31e039c0740c8d5
* | | Merge "Add missing headers for compilation on x86 targets"Olivier Bailly2010-11-293-0/+5
|\ \ \
| * | | Add missing headers for compilation on x86 targetsOlivier Bailly2010-11-173-0/+5
| | | | | | | | | | | | | | | | Change-Id: I5f4dc797b353a0f01fa00d38375ec303bf863254
* | | | check the return value of setuid and friendsNick Kralevich2010-11-171-3/+12
|/ / / | | | | | | | | | | | | | | | | | | | | | | | | Under some circumstances, setuid() and family can fail, returning a non-zero value. (see "man setuid" for details). If this happens, we want to ensure that init doesn't spawn a process which has root privileges when it's not suppose to. Change-Id: Idd03f2c8f82a7eaf6e696b5bcfe308e51ea58b52
* | | init: Abort firmware transfer if firmware is missingBenoit Goby2010-11-091-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | If firmware is not found, write -1 /sys/$DEVPATH/loading to cancel the firmware load. Otherwise the driver has to wait for the 60s timeout. Change-Id: Id2787cda9b2be45b9adea41f6f161cd54cda212e Signed-off-by: Benoit Goby <benoit@android.com>
* | | am 439b4dfb: am bc57d4ce: init: support owner/permission setting for sysfs ↵Brian Swetland2010-10-264-33/+62
|\ \ \ | |/ / | | | | | | attributes of devices
| * | am bc57d4ce: init: support owner/permission setting for sysfs attributes of ↵Brian Swetland2010-10-264-33/+62
| |\ \ | | |/ | | | | | | devices
| | * init: support owner/permission setting for sysfs attributes of devicesBrian Swetland2010-10-264-33/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | This should be much nicer than peppering init.rc with chown/chmod directives. Also, remove some dead code and obsolete comments. Change-Id: I10895f10a9cf2f1226c8d12976cd3db3743da9ec
* | | Allow AID_RADIO to restart the ril-daemon.Wink Saville2010-10-032-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This enhances robustness by allowing the Telephony Framework to restart ril-daemon if it notices some catastrophic failure. Added setprop ctl.restart. Added ril-daemon to setprop control_perms and allow users/groups with the AID_RADIO ID to control it. Change-Id: I195abdd754a731ce0b77e8f71ab47fde8c3e7977
* | | am 78ea2374: am 912ff85b: init: Add support for SOCK_SEQPACKET socket typeMike Lockwood2010-10-013-6/+8
|\ \ \ | |/ / | | | | | | | | | | | | | | | Merge commit '78ea2374c5c87d7bb58747b1a6173c598f386600' * commit '78ea2374c5c87d7bb58747b1a6173c598f386600': init: Add support for SOCK_SEQPACKET socket type
| * | am 912ff85b: init: Add support for SOCK_SEQPACKET socket typeMike Lockwood2010-10-013-6/+8
| |\ \ | | |/ | | | | | | | | | | | | | | | Merge commit '912ff85b035e0e6bc109812c1ea5661ea4df5967' into gingerbread-plus-aosp * commit '912ff85b035e0e6bc109812c1ea5661ea4df5967': init: Add support for SOCK_SEQPACKET socket type
| | * init: Add support for SOCK_SEQPACKET socket typeMike Lockwood2010-10-013-6/+8
| | | | | | | | | | | | | | | Change-Id: Ib264ecf9beb2685b070436d2bdec9655c7a31b47 Signed-off-by: Mike Lockwood <lockwood@android.com>
* | | resolved conflicts for merge of 3b5214a6 to masterBrian Swetland2010-09-191-9/+18
|\ \ \ | |/ / | | | | | | Change-Id: Id73c53c6c2e9c21eb9b1d1e624aaeb25097ea7a4
| * | am 02863b95: add /vendor supportBrian Swetland2010-09-191-9/+18
| |\ \ | | |/ | | | | | | | | | | | | | | | Merge commit '02863b957cfbfc302d3136ed78c0cba86accacd8' into gingerbread-plus-aosp * commit '02863b957cfbfc302d3136ed78c0cba86accacd8': add /vendor support
| | * add /vendor supportBrian Swetland2010-09-191-9/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - look in /vendor/firmware/... in addition to /system/etc/firmware/... for firmware loading - add /vendor/bin to path before /system/bin - add /vendor/lib to ldpath before /system/lib - configure appropriate permissions for /system/vendor/bin - symlink /vendor -> /system/vendor Change-Id: I0c06ca1e38a44f0c7024cee6cea8907aa93a4532
* | | am 49b8124a: am 17dcc5c5: Use makedev helper for device major and minor numbersColin Cross2010-09-031-4/+1
|\ \ \ | |/ / | | | | | | | | | | | | | | | Merge commit '49b8124a1759cb8b27e0c21a1a5a54b8a81bdb19' * commit '49b8124a1759cb8b27e0c21a1a5a54b8a81bdb19': Use makedev helper for device major and minor numbers
| * | am 17dcc5c5: Use makedev helper for device major and minor numbersColin Cross2010-09-031-4/+1
| |\ \ | | |/ | | | | | | | | | | | | | | | Merge commit '17dcc5c57dcffb919f3de65ff7a0134ffa3bd874' into gingerbread-plus-aosp * commit '17dcc5c57dcffb919f3de65ff7a0134ffa3bd874': Use makedev helper for device major and minor numbers
| | * Use makedev helper for device major and minor numbersColin Cross2010-09-031-4/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | Major and minor numbers can be greater than 255. Major numbers are 12 bits, and minor numbers are 20 bits. Supporting major and minor numbers > 255 allows the use of the extended block device for extra mmc partitions. Change-Id: I4c42bfe0781069e8e4cb13ebe26e860cdc03f866
* | | init: Add symlinks to USB character devicesBenoit Goby2010-08-101-0/+52
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since we now support USB host mode, devices might get a different device file depending if other devices are connected on the host port. This patch creates symlinks to USB character devices that depend on the port devices are connected to, but not on the order they have been probed. (e.g. /dev/usb/tty2-1:1.0 -> /dev/ttyUSB0) Change-Id: I285bcc2d59446fbff8a7abbe39c21781f3bb4bd3
* | | am 3fc108ac: am fad7204e: resolved conflicts for merge of 5f5d5c8c to ↵Nick Kralevich2010-07-201-5/+31
|\ \ \ | |/ / | | | | | | | | | | | | | | | | | | | | | gingerbread Merge commit '3fc108acf2b05153489730178c85b8db94f603af' * commit '3fc108acf2b05153489730178c85b8db94f603af': validate the source of uevent messages
| * | am fad7204e: resolved conflicts for merge of 5f5d5c8c to gingerbreadNick Kralevich2010-07-201-5/+31
| |\ \ | | |/ | | | | | | | | | | | | | | | Merge commit 'fad7204e9eac20a87afacd7547ed8202a39319f8' into gingerbread-plus-aosp * commit 'fad7204e9eac20a87afacd7547ed8202a39319f8': validate the source of uevent messages
| | * resolved conflicts for merge of 5f5d5c8c to gingerbreadNick Kralevich2010-07-191-5/+31
| | |\ | | | | | | | | | | | | Change-Id: Ieee2cd67d33f3e774fcfd96f8a5f67a0374aa873
| | | * validate the source of uevent messagesNick Kralevich2010-07-191-5/+31
| | | | | | | | | | | | | | | | | | | | Bug: 2844206 Change-Id: If2eee54181abfc6c7fda0232f98fa6bb5d12c60c
* | | | am 742150c0: merge from open-source masterThe Android Open Source Project2010-07-161-2/+3
|\ \ \ \ | |/ / / | | | | | | | | | | | | | | | | | | | | Merge commit '742150c031756da1393bf4223b2468b17cb79326' * commit '742150c031756da1393bf4223b2468b17cb79326': Use complete hardware name without spaces.
| * | | merge from open-source masterThe Android Open Source Project2010-07-161-2/+3
| |\ \ \ | | |/ / | |/| | | | | | Change-Id: I29602fecafc2b6d93b849ada89696a67cfd23353
| | * | Use complete hardware name without spaces.Sean McNeil2010-07-131-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | Many targets use generic first portions like 'OMAP' Change-Id: I00ba4e64cffc48353c29e409c3c19238024fbd8c
* | | | am 62a54f3b: am 25b15be9: init: use tmpfs/ftruncate for properties backing ↵Brian Swetland2010-07-131-6/+15
|\ \ \ \ | |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | store instead of ashmem Merge commit '62a54f3b1343043528b7e93c1a4311a5e9d5f358' * commit '62a54f3b1343043528b7e93c1a4311a5e9d5f358': init: use tmpfs/ftruncate for properties backing store instead of ashmem
| * | | init: use tmpfs/ftruncate for properties backing store instead of ashmemBrian Swetland2010-07-131-6/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This removes the need for ashmem for early bringup and avoids an issue with permissions enforcement. Change-Id: I405b080660934d73048c79d614b6b2ebc43ab182 Signed-off-by: Brian Swetland <swetland@google.com>
* | | | Mount /dev with nosuidNick Kralevich2010-06-221-1/+1
| | | | | | | | | | | | | | | | Change-Id: I66c7fcf9b65405dfc12d344ef3ed225d0ad2db84
* | | | Revert "Mount /dev with noexec and nosuid"Nick Kralevich2010-06-151-1/+1
| | | | | | | | | | | | | | | | This reverts commit 4ec97f2b257f5c9ed7cf6f0245212f4e3eb60c1b.
* | | | Mount /dev with noexec and nosuidNick Kralevich2010-06-081-1/+1
| | | | | | | | | | | | | | | | Change-Id: Iea182c1e6a72c281abd17bf83ff765bb9cb59270
* | | | am 982a815c: Reap firmware child processes to prevent zombiesColin Cross2010-06-031-0/+7
|\ \ \ \ | |/ / /
| * | | Reap firmware child processes to prevent zombiesColin Cross2010-06-031-0/+7
| | | | | | | | | | | | | | | | Change-Id: Ic6c50b929a025f05450cd309238e60a857690d9b
| * | | DO NOT MERGE resolved conflicts for merge of e95aad61 to krakenMike Lockwood2010-05-172-2/+24
| |\ \ \ | | |/ / | | | | | | | | | | | | | | | | | | | | this change is already in master Change-Id: Ica43eae28b50d89d50217851aff7e62978abfa27 Signed-off-by: Mike Lockwood <lockwood@android.com>
| | * | merge from open-source masterThe Android Open Source Project2010-05-172-2/+25
| | |\ \ | | | |/ | | |/| | | | | Change-Id: I414c9479f4f913c777ef18b7ff27e410f49d35b9