Commit graph

10083 commits

Author SHA1 Message Date
Hans Boehm
b14f65cb50 Do not typedef char16_t if it is a keyword.
Don't define char16_t on platforms where char16_t is a keyword, as
C11 and C++11 define it to be.

(cherry picked from commit dfdbe61d28)
Change-Id: I6717bc2133c1363ecd85861f3869e1eabd2ce96a
2014-07-18 17:53:02 -07:00
Elliott Hughes
c11146efdf Fix implicit declaration of function 'prctl' in logd.
(cherry picked from commit e5a0f2064b)

Change-Id: Iee202daf3c637271a30ba0271abe68e939b5a887
2014-07-18 17:40:52 -07:00
Elliott Hughes
cbbb83b0eb Fix implicit declaration of function 'prctl' in adb.
(cherry picked from commit b4dd6ef223)

Change-Id: Ia64bec746ae8d2c45663f61afb46702838b1e5bf
2014-07-18 16:46:39 -07:00
Daniel Rosenberg
7677e04ef6 Merge "newfs_msdos: Added option to cluster-align the start of the root directory" into lmp-dev 2014-07-17 21:15:46 +00:00
Elliott Hughes
400c381835 Move sched_policy.c off bionic's PR_SET_TIMERSLACK_PID.
Change-Id: I3a27803d46b5b88a10aa8043a114d780ed685e56
2014-07-17 17:15:14 -07:00
Patrick Tjin
4415e2a269 Scan all descriptors when checking for fastboot [DO NOT MERGE]
For Linux, the USB code was only looking at the first
descriptor when searching for the fastboot interface
which caused some devices to not be found.

Also clarify some code by using the actual USB structures
instead of void or char pointers.

(Cherry Picked from aac89db8a5)
Change-Id: I9e4871c4d477ac10ba75bb17a955f176809af289
Signed-off-by: Patrick Tjin <pattjin@google.com>
2014-07-17 10:07:19 -07:00
Nick Kralevich
04f9b2a809 debuggerd: use O_NOFOLLOW|O_CLOEXEC for tombstones
Change-Id: I71bdfba30346a9fad3129b404f39eda8190698e3
2014-07-16 20:08:41 -07:00
Daniel Rosenberg
052f275621 newfs_msdos: Added option to cluster-align the start of the root directory
This follows the recommendations of the SD-card association.

Change-Id: Ie89a5972d086b3df9d92e631c394a521f807b016
Signed-off-by: Daniel Rosenberg <drosen@google.com>
2014-07-16 16:56:00 -07:00
Jungshik Jang
cadd5bb70e Add force usage and config type for HDMI-CEC system audio mode.
New Usage Type: AUDIO_POLICY_FORCE_FOR_HDMI_SYSTEM_AUDIO
New Config Type: AUDIO_POLICY_FORCE_HDMI_SYSTEM_AUDIO_ENFORCED
When HDMI-CEC system audio mode is enabled, AudioService will
call
 setForceUse(AUDIO_POLICY_FORCE_FOR_HDMI_SYSTEM_AUDIO,
          AUDIO_POLICY_FORCE_HDMI_SYSTEM_AUDIO_ENFORCED);
in order to notify enabled system audio mode, so that
audio policy manager chooses proper output.
When it turns into off, AudioService will call
 setForceUse(AUDIO_POLICY_FORCE_FOR_HDMI_SYSTEM_AUDIO,
          AUDIO_POLICY_FORCE_NONE);

Along with it, add new audio output devic type,
AUDIO_DEVICE_OUT_AUX_LINE, in order to distinguish
line out for headphone and aux output of av device.

Bug: 16305986
Bug: 16002150
Change-Id: Idecdf626737f6635ea3cda638c343260b1661c77
2014-07-16 09:21:04 +09:00
Elliott Hughes
e9f7361ea9 Add SIGFPE to crasher.
Bug: 3399996

(cherry picked from commit 3ecc42106e)

Change-Id: I075613ca3c022ce8d38a06a5ba236ceff32d181c
2014-07-15 13:18:32 -07:00
Colin Cross
7e55d8899c Merge topic 'lmkd' into lmp-dev
* changes:
  lmkd: kill a process if zoneinfo can't be read
  lmkd: kill multiple tasks
  lmkd: use open instead of fopen
  lmkd: make lmkd SCHED_FIFO
  lmkd: mlock all memory
  lmkd: remove libcutils from LOCAL_SHARED_LIBRARIES
2014-07-15 16:06:25 +00:00
Elliott Hughes
aae5d43755 Add missing arm64 registers.
Also fix dumping of arm64's vector registers, which are actually 128 bits wide.

Also move the arm/arm64 FP registers to the tombstone. (We've never dumped
them at all for the other architectures.)

(cherry picked from commit b40c50351e)

Change-Id: Ic646fb9ea01e9beb42e1757feb8742c1d4efafa7
2014-07-14 18:56:53 -07:00
Colin Cross
f8857cc24a lmkd: kill a process if zoneinfo can't be read
Opening /proc/zoneinfo may return -ENOMEM under memory pressure,
assume something needs to be killed if that happens.

Bug: 16236289
Change-Id: I25aab09f4c3f2b9e176eaaeca94fd6bd790dad4e
2014-07-14 17:41:17 -07:00
Colin Cross
16b0946da1 lmkd: kill multiple tasks
The task selected to die may be small, add its approximate size
to other_free and other_file and keep killing until all thresholds
are met.

Bug: 16236289
Change-Id: Iceeca4c63fec98cae2bf53e258f7707cea408b07
2014-07-14 17:41:17 -07:00
Colin Cross
ce85d955a3 lmkd: use open instead of fopen
fopen and fgets require allocations, switch to open/read with
stack allocated buffers.

Bug: 16236289
Change-Id: I10586883fe78caf59d309eff7f7989b3e45beb7d
2014-07-14 17:41:17 -07:00
Colin Cross
1a0d9be53e lmkd: make lmkd SCHED_FIFO
If kswapd runs more than lmkd it may throw away all page cache pages
before lmkd gets a chance to kill a process.  Make lmkd SCHED_FIFO
so it can react quickly to kernel low memory notifications.

Bug: 16236289
Change-Id: I46767b4ec81ef8638d0c9e47d168a68b62e3cac5
2014-07-14 17:41:17 -07:00
Christopher Tate
71bbc6789f Fix the build in clang
"fprintf(stderr, buf)" is a warning in some compilers, and we're
building with all warnings promoted to error.

Change-Id: Ie3c6ddcd74cf4dda40cf7b742df955dde1d1a5ff
2014-07-14 16:53:57 -07:00
Colin Cross
b28ff91313 lmkd: mlock all memory
Use mlockall(MCL_FUTURE) to lock all lmkd pages in memory.  This
avoids lmkd thrashing when the system is low on memory.

As a side effect, it will also keep the .text sections of liblog, libm,
libc, and libprocessgroup in memory at all times.

Bug: 16236289
Change-Id: Idd70557efa4b1e14bc86f14220672a30f6c956e3
2014-07-14 16:39:56 -07:00
Colin Cross
9d9e62cf37 lmkd: remove libcutils from LOCAL_SHARED_LIBRARIES
While lmkd does technically use libcutils' socket.h, it only
uses a static inline.  Remove libcutils from LOCAL_SHARED_LIBRARIES
so it doesn't end up mlock'd in memory in the next patch.

Bug: 16236289
Change-Id: I744d69bfff06cb904836f64e1d5f6e530604bff4
2014-07-14 16:39:56 -07:00
Ruben Brunk
a5e65d86a2 Allow sticky transform to be set in ANativeWindow.
Bug: 15116722

- Adds methods to set the sticky transform field.

Change-Id: Idaa4311dfd027b2d2b8ea5e2c6cba2da5779d753
2014-07-14 22:14:49 +00:00
Jeff Sharkey
1404e65472 Merge "Fix 64-bit builds." into lmp-dev 2014-07-14 18:38:02 +00:00
Jeff Sharkey
c03064ea71 Fix 64-bit builds.
Change-Id: I1ff5c9c3dc8d870aef2885f8a1989c6c913ccb3d
2014-07-14 13:57:54 -07:00
Riley Andrews
fd0f390869 Merge "Move unlink("/dev/.booting") until after filesystems are mounted." into lmp-dev 2014-07-14 18:37:56 +00:00
Riley Andrews
80c7a5e8a8 Move unlink("/dev/.booting") until after filesystems are mounted.
Move the unlink out of init.c and into init.rc, so that the file
will be removed after all the filesystems with firmware are up.

Change-Id: Ifdd5dd1e95d7e064dde5c80b70198882d949a710
2014-07-14 13:17:43 -07:00
Todd Poynor
2eb3d3b55c am 7b29cc8c: Merge branch \'lmp-dev-plus-aosp\' of https://googleplex-android.googlesource.com/_direct/platform/system/core into lmp-dev-plus-aosp
* commit '7b29cc8c026548306e661f22573dc80c8e7fba0f':
2014-07-14 18:52:38 +00:00
Todd Poynor
7b29cc8c02 Merge branch 'lmp-dev-plus-aosp' of https://googleplex-android.googlesource.com/_direct/platform/system/core into lmp-dev-plus-aosp 2014-07-14 18:17:22 +00:00
aarti jadhav-gaikwad
c6cca01756 am 24ca56e1: am 923e7408: audio: add definitions for aac sub formats
* commit '24ca56e1e0f04061d5ea0d5750ea2d487bcd5322':
2014-07-14 18:00:26 +00:00
Sreeram Ramachandran
2cb1c3c23b am 9ec4cb80: am f813da2d: am e26ca55b: am b12e40da: am 0a7b44d5: am ab98d2e6: Merge "Create a data directory for netd and other network-related files."
* commit '9ec4cb80658b67e6fe95917cb9a1f697546beb13':
2014-07-14 18:00:25 +00:00
Elliott Hughes
c43a3e875a am 9f8fa8f2: am 99adb755: am b5dfe272: am f761709a: am 1829b14c: am 18e754ee: Merge "Fix LP64 tombstone.cpp build failure."
* commit '9f8fa8f2786c0156b43be7e83e70b8a267c4527a':
2014-07-14 18:00:24 +00:00
Elliott Hughes
4d5d830bc4 am b5e36713: am afacbefb: am 7ca8bae8: am 4f27968f: am 494bd36d: am dda63545: Merge "Improving maps output."
* commit 'b5e367131568573f9b9da7c130a1a73c85261958':
2014-07-14 18:00:23 +00:00
dcashman
342681c2a2 am 80e236a1: am 9ae2b5e1: am 8c7e0520: am cddb15b8: am b4e74db7: am 3fa71b8e: Merge "Remove sshd."
* commit '80e236a11cd2d1d327ccfae47421a5c35188216b':
2014-07-14 18:00:22 +00:00
Jungshik Jang
b61ae5d9a0 am d7fedf9a: am 6fe31610: Merge "Fix size of "values" fields of audio_gain_config."
* commit 'd7fedf9abd5ad0b6ba1ea93ed0d6f53f73d2a891':
2014-07-14 18:00:21 +00:00
Jungshik Jang
37ad4cc965 am 6a6f1166: am 2c7cfc10: Remove forced usage types for HDMI-CEC system audio mode.
* commit '6a6f116621d549554679523be35db7033a710445':
2014-07-14 18:00:20 +00:00
Ruchi Kandoi
c543235814 am d48e5fb4: am a78fc234: healthd: Reports arbitrary numbers for capacity and temperature when connected to fake battery.
* commit 'd48e5fb4378b6e29d8d33194ece7e5f02d210d76':
2014-07-14 18:00:19 +00:00
Colin Cross
4d96be15b6 am 59a954a8: am 212e9798: add cleanspec for lmkd
* commit '59a954a80cc6669dadd9444ddb6b2fb39ef778dd':
2014-07-14 18:00:18 +00:00
Colin Cross
01dc8b19ab am 8cb357ea: am 420f0a25: Merge "lmkd: use libprocessgroup to kill forked processes"
* commit '8cb357ea50f993c3a61a2aaf511c37a1d69b26a1':
2014-07-14 18:00:17 +00:00
Colin Cross
67fcd844af am 350a68bf: am fb27d34d: Merge "Add libprocessgroup"
* commit '350a68bf24ade269acc4ee69b0af01b9533f8187':
2014-07-14 18:00:16 +00:00
Badhri Jagan Sridharan
2cdaf1c38b am 8f6c821b: am bf9ef519: am cb7be1e8: am 87c7a0d7: am 77a2c22d: Merge "adbd: adb root should terminate adbd only if it\'s debuggable"
* commit '8f6c821bb5d1e410935cf6cf17c560e27b4c964c':
2014-07-14 18:00:15 +00:00
Elliott Hughes
b28f4c0b1f am 5dda36bd: am c89c0c65: am 75b3d8c0: am d0fa7342: am 660ba372: Merge "Fix arm emulator "D register out of range for selected VFP version" build failure."
* commit '5dda36bd7cb56a0dcfe8ea55ddf955cc5622923c':
2014-07-14 18:00:15 +00:00
Elliott Hughes
67f549b651 am 3a03e61c: am 0dd3fe22: am b237f5fb: am 5acbb9bc: am b5186598: Merge "Integrate vfp-crasher with crasher."
* commit '3a03e61ccfe97c76d09c2d8588ef18477af9de73':
2014-07-14 18:00:14 +00:00
Elliott Hughes
920fca2a31 am a06bbdf5: am 67db9d5f: am b2ac4243: am f76c8fe6: am 328c3ef6: Merge "Fix typo in fs.h"
* commit 'a06bbdf54334870c233ff4206c78dd2b7fc265eb':
2014-07-14 18:00:13 +00:00
Colin Cross
b91775ba3f am 1d6279ee: am 038975a5: Merge "lmkd: pass uid from ActivityManager to lmkd"
* commit '1d6279ee3d0771687a56a22e70dc1e7aa5ac3078':
2014-07-14 18:00:12 +00:00
Nick Kralevich
cc20ac8bf0 am a352c8c8: am ee0388e7: am f89ddf76: am d05245a4: am c87237f5: Merge "restorecon_recursive /cache"
* commit 'a352c8c8569a2d020fd9030bd841ef5f4c4f7755':
2014-07-14 18:00:11 +00:00
Daniel Rosenberg
37b8600f96 am 9d09b12d: am 33e7b131: Made formatting for newfs_msdos.c more uniform
* commit '9d09b12d4da492d5bc22c8b71264720a9bdac816':
2014-07-14 18:00:10 +00:00
Elliott Hughes
72629c94bc am e360bb45: am 6ebab06d: am f043f061: am 060b6ecb: am 6e141aea: Merge "Fix sdcard\'s FUSE_FSYNCDIR handling."
* commit 'e360bb459e983521d09586971a5a3a94339af60c':
2014-07-14 18:00:09 +00:00
Elliott Hughes
076c480f61 am 63917b10: am 40372e5b: am 94645665: am f8acdcbe: am 75b7171f: Merge "Make sdcard log to the log rather than stderr."
* commit '63917b10273451878d509d908f040d04e8bcccdb':
2014-07-14 18:00:08 +00:00
Terry Heo
554006b7ce am ac53a4af: am a916e260: Merge "audio: add definition for new audio loopback input device"
* commit 'ac53a4af6afd1f4747f527dc28f9fec3c53f3901':
2014-07-14 18:00:07 +00:00
Nick Kralevich
d9d01d0e10 am 09ef42ab: am 14253c1a: Merge "init.rc: add seclabel to flash_recovery"
* commit '09ef42ab63dc36d1097390bda6bf08d1cf5332e1':
2014-07-14 18:00:06 +00:00
Eric Laurent
de8566330c am 0c9dc552: am aecb7f84: Merge "Revert "Revert "sound trigger: several data structure updates"""
* commit '0c9dc552921bf50d62c8b81084a703ac07e48cd6':
2014-07-14 18:00:04 +00:00
Sreeram Ramachandran
e20825077c am 2f26cd9e: am 85449d36: am b12e40da: am 0a7b44d5: am ab98d2e6: Merge "Create a data directory for netd and other network-related files."
* commit '2f26cd9ea62f24123b0f82316cc0a00f4ed5689a':
2014-07-14 18:00:03 +00:00