Commit graph

8136 commits

Author SHA1 Message Date
Nick Kralevich
3b4c0bda07 ueventd fixup_sys_perms: fixup SELinux labels unconditionally
Currently, the fixup code in fixup_sys_perms() scans through all
entries in uevent*.rc. If it finds a match, then it performs a fixup.
If there's no match in that file, no fixup is performed.

SELinux file labels are independently stored in /file_contexts,
with no relationship to the files in /ueventd.rc. Even when no
entries exist in ueventd.rc, we still want to fixup the SELinux
file label in /sys when a uevent message occurs.

Change-Id: I0ccb5395ec0be9282095b844a5022e8c0d8903ac
2014-07-07 11:14:59 -07:00
Mark Salyzyn
f6ef1f53ac Merge "logcat: parse failure for -n <KBsize> and -r <rotate limit>" 2014-07-07 17:50:18 +00:00
Mark Salyzyn
0b2dac4f3f logcat: parse failure for -n <KBsize> and -r <rotate limit>
Bug: https://code.google.com/p/android/issues/detail?id=72867
Change-Id: Id0c988543ecfccc5054d15d4195ef578468d50af
2014-07-07 18:04:32 +00:00
Elliott Hughes
6e141aea18 Merge "Fix sdcard's FUSE_FSYNCDIR handling." 2014-07-05 03:01:43 +00:00
Elliott Hughes
f6d6737529 Fix sdcard's FUSE_FSYNCDIR handling.
For a file the FUSE fh is a struct handle containing an int fd;
for a directory it's a struct dirhandle containing a DIR*. Fix
handle_fsync to extract the file descriptor appropriately in
both cases.

Bug: 14613980
Change-Id: I45515cff6638e27a99b849e6fc639d355dbb4d27
2014-07-08 14:38:26 -07:00
Elliott Hughes
75b7171fcb Merge "Make sdcard log to the log rather than stderr." 2014-07-08 18:09:01 +00:00
Elliott Hughes
300d564980 Make sdcard log to the log rather than stderr.
Change-Id: I9c78941184c5e364055bfac766e1e542d3c23c87
2014-07-08 13:53:26 -07:00
Elliott Hughes
dda635455f Merge "Improving maps output." 2014-07-07 18:07:41 +00:00
Brigid Smith
8606eaa770 Improving maps output.
Maps output now displays fault address location more intelligently.  If
the fault is not in a mapped region, it now shows where that address is
with respect to the other maps.

In addition, the size of the map is now printed as part of the output.

Also, crasher now supports an "mmap" option which mmaps/munmaps a region
of memory and then attempts to access it, causing a fault address in
between mapped regions that can be used to test that new part of the
maps output.

Change-Id: Ia5e1926802bdfcbbdb7857e3631ddf395ae0c5b8
2014-07-08 10:53:49 -07:00
dcashman
3fa71b8e83 Merge "Remove sshd." 2014-07-07 18:07:41 +00:00
dcashman
b4cbff47ad Remove sshd.
This may require changes to other code, such as fastbootd, which relies on this
service.  sshd is not currently, used, however, so this change will force any
such code to be changed.

Bug: 11594902
Change-Id: I07e52008290dab5825be2ad062cbe730fa7dff71
2014-07-07 23:42:15 +00:00
Nick Kralevich
5529de0fa3 Merge "logd_write: set SOCK_CLOEXEC on socket" 2014-07-03 01:32:01 +00:00
Nick Kralevich
118d1b3930 logd_write: set SOCK_CLOEXEC on socket
Socket file descriptors remain open across exec unless
SOCK_CLOEXEC is set. Enable this option, to avoid leaking
file descriptors.

See https://android-review.googlesource.com/53736 for a similar
problem with the old logging code.

Change-Id: I9e045d2291ae6680044ab86604f3ff2c55b5eaed
2014-07-02 22:30:39 -07:00
Colin Cross
09117c70f1 Merge "ueventd: allow matching symlink names when setting permissions" 2014-07-02 20:52:43 +00:00
Colin Cross
43d537e0de ueventd: allow matching symlink names when setting permissions
Change-Id: I5f6cc2a25f1236fbe2c7193b65363b7883b9ba2e
2014-07-02 13:56:55 -07:00
Sreeram Ramachandran
ab98d2e6a9 Merge "Create a data directory for netd and other network-related files." 2014-07-02 20:49:53 +00:00
Elliott Hughes
18e754eebd Merge "Fix LP64 tombstone.cpp build failure." 2014-07-08 17:33:52 +00:00
Elliott Hughes
7e775952e1 Fix LP64 tombstone.cpp build failure.
Change-Id: Id071417f56dd883e9d2e38a6f3296cb23a0352fb
2014-07-08 11:35:58 -07:00
Sreeram Ramachandran
b46efdb08e Create a data directory for netd and other network-related files.
Allows the 'shell' group (which is what dumpstate uses) to read the files in
this directory.

Change-Id: I69deb1a64d5d6647470823405bf0cc55b24b22de
2014-07-08 08:44:47 -07:00
Nick Kralevich
1aad06ddde Merge "implement LOG_EVENT_STRING" 2014-07-01 23:33:34 +00:00
Nick Kralevich
2a4d05a4e3 implement LOG_EVENT_STRING
Implement LOG_EVENT_STRING, so that native code can create new
event log entries. This is needed to support logging SELinux denials
to the event log.

Change-Id: I6a269a832bc2f5e5da6c9dbd169ed2f901b49166
2014-07-01 12:22:04 -07:00
Elliott Hughes
5a53ee0502 Merge "Remove an unused #include of <sys/_properties.h>." 2014-06-27 16:59:53 +00:00
Todd Poynor
d4d1b5045c Merge "Charger: Avoid animation while not charging DO NOT MERGE" 2014-06-30 17:43:31 +00:00
Jenny TC
9cc4ea329f Charger: Avoid animation while not charging DO NOT MERGE
At present, charging animation runs irrespective of whether charger
is connected or not. When the charger is disconnected, device not shutdown
for 10secs. Charging animation during this period should be avoided.

Change-Id: Idf8e6a11261aec2812f1ebbbdec1bd1ad769565e
Signed-off-by: Pavan Kumar S <pavan.kumar.s@intel.com>
Signed-off-by: Jenny TC <jenny.tc@intel.com>
Signed-off-by: Yong Yao <yong.yao@intel.com>
2014-06-30 18:20:34 +00:00
Elliott Hughes
11d783f1e7 Remove an unused #include of <sys/_properties.h>.
Bug: 15704351
Change-Id: I7841da7176d0638ae6737fe719cd187892bc38e6
2014-06-30 10:11:55 -07:00
Narayan Kamath
6e074c68e2 Merge "Build pixelflinger tests as native tests, not executables." 2014-06-26 21:17:59 +00:00
Ian Rogers
63a61e561d Merge "Rename __unused to __UNUSED for glibc support." 2014-06-28 00:06:36 +00:00
Ian Rogers
de8b983357 Rename __unused to __UNUSED for glibc support.
Glibc declares unused fields as __unused and so a #define for __unused causes
issues when we built against glibc on the host. Rename __unused to __UNUSED as
a workaround.
This fixed checkbuild for 64-bit host builds. Bug: 13751317

Change-Id: Ic2cd52518c16661497cc819cb3fd7f1fa5c6f0fb
2014-06-27 17:40:32 -07:00
Mark Salyzyn
0a350f4f08 Merge "debuggerd: synchronize cosmetics to internal" 2014-06-27 16:59:53 +00:00
Mark Salyzyn
17e85c0671 debuggerd: synchronize cosmetics to internal
Change-Id: I66bc2b181cd75da188c046571492224d5ac3fc98
2014-06-27 15:55:19 -07:00
Elliott Hughes
e080be5754 Merge "Fixed tid/pid mixup in debuggerd gdbclient output." 2014-06-26 18:34:59 +00:00
Brigid Smith
75582957cf Fixed tid/pid mixup in debuggerd gdbclient output.
Now the debugging output shows the tid of the crashed thread instead of
the pid of the process that crashed.

Change-Id: I637f409ff02d73d458edc6d1a5c462c21d128211
2014-06-27 09:21:12 -07:00
Mark Salyzyn
c8a7e34dfc Merge "tombstone: log output header suppressed in crash" 2014-06-27 16:00:43 +00:00
Mark Salyzyn
e43290d7ed tombstone: log output header suppressed in crash
Bug: 15520846
Change-Id: I18934cc60af3dda98ab729fbabc4c7a66834512e
2014-06-27 10:32:22 -07:00
Riley Andrews
10f8cd1d87 Merge changes Ia15b2110,I5498c725
* changes:
  Add ability to adjust init log level at runtime.
  Improve init's debug printing.
2014-06-26 17:56:55 +00:00
Riley Andrews
1bbef88e80 Add ability to adjust init log level at runtime.
+ Add a new property, sys.init_log_level, which can be set after init
  bootstrap. This will control the level at which init does prints to klog.

Change-Id: Ia15b2110157b5e6b713785ece9b0fb94889be6c8
2014-06-26 15:05:20 -07:00
Riley Andrews
24a3b783d5 Improve init's debug printing.
+ Make prints of rc commands significantly more verbose. All commands
  will log all arguments, file/line number of the command, return value,
  and parent action which triggered the command.

init: command 'mount tmpfs tmpfs /mnt/obb mode=0755,gid=1000' action=init
      status=0 (/init.rc:89)
init: command 'setprop net.tcp.default_init_rwnd 60' action=boot status=0
      (/init.rc:403)

Change-Id: I5498c7258e4891706be4a12546df4231d14d86c4
2014-06-26 15:05:15 -07:00
Narayan Kamath
992031c876 Build pixelflinger tests as native tests, not executables.
This has the side effect of building tests for both 32
and 64 bit, where required.

Change-Id: I674800d34b4fa7cc5d34573c96b754ac85777970
2014-06-26 13:22:44 +01:00
Elliott Hughes
01ad77107b Merge "Fix %llx to PRIx64 in nandread.c." 2014-06-25 17:34:27 +00:00
Elliott Hughes
a5f28628b1 Fix %llx to PRIx64 in nandread.c.
Change-Id: I541d1f4efac3c91d1a26f60735c72e799490fcc9
2014-06-25 16:37:18 -07:00
Nick Kralevich
4ad20e55e5 Merge "Redirect libselinux logging to dmesg for ueventd." 2014-06-25 03:39:25 +00:00
Ian Rogers
e4022279e1 Merge "libbacktrace_libc++ needs to be multilib on the Mac too." 2014-06-25 03:39:25 +00:00
Ian Rogers
c132aaf0c3 libbacktrace_libc++ needs to be multilib on the Mac too.
Change-Id: I2053345253c1d57c3485b790163ba0b4b10cc326
2014-06-24 21:57:55 -07:00
Michael Wright
949bd4c208 Merge "Print ABI in backtraces." 2014-06-25 01:41:06 +00:00
Michael Wright
80f596984e Print ABI in backtraces.
This lets the stack tool figure out which toolchain to use
automatically.

Change-Id: Ia235d6904622423fe6fbc7b0315a1861e52a41ad
2014-06-24 17:14:26 -07:00
Stephen Smalley
439224e275 Redirect libselinux logging to dmesg for ueventd.
We already do this for init, but had failed to do it for ueventd
and could not capture any logging from libselinux calls made by
ueventd.

Truly enabling non-error logging also requires uncommenting a line
in Android.mk:
LOCAL_CFLAGS += -DLOG_UEVENTS=1
which enables other logging and sets the default log level to INFO,
or otherwise changing the klog level in the ueventd code (is not
settable by init.rc loglevel).

Change-Id: I00e6f9d6271f2a21d9078c96368816d74d6d2850
Signed-off-by: Stephen Smalley <sds@tycho.nsa.gov>
2014-06-24 14:11:59 -04:00
Narayan Kamath
a42d5bf006 Merge "pixelflinger: Use pointer arithmetic to determine cache flush parameters" 2014-06-24 06:33:30 +00:00
Nick Kralevich
64f5fe2796 Merge "property_service: get rid of hard coded property / control list" 2014-06-25 17:34:34 +00:00
JP Abgrall
077033391b Merge "Wait for device to disappear after "fastboot reboot"." 2014-06-23 21:50:22 +00:00
Mark Wachsler
ec25e7bc4b Wait for device to disappear after "fastboot reboot".
This is a follow-up to commit 157b00171a.
After "fastboot reboot", "fastboot devices" was still showing the device as
connected even though it was starting to reboot; now "fastboot reboot" will
wait until the device has disconnected.

The wait timeout is 3 seconds.

Change-Id: I8066741f0be91e53f3e3f5bc968bc1b9de31db05
2014-06-24 22:34:34 +00:00