summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndroid (Google) Code Review <android-gerrit@google.com>2009-10-29 16:40:32 -0400
committerAndroid (Google) Code Review <android-gerrit@google.com>2009-10-29 16:40:32 -0400
commit3034624f68d373d7c79237425319b5b7fd84317e (patch)
tree519c5860e0ab2ab35786040bd4b653f95d323af1
parent4388b98845e6a28c689e500cd6ed1e9bb29a2c12 (diff)
parent26a2d829b37d2658e5e037f1f8ce968bbd9f2164 (diff)
downloadframeworks_base-3034624f68d373d7c79237425319b5b7fd84317e.zip
frameworks_base-3034624f68d373d7c79237425319b5b7fd84317e.tar.gz
frameworks_base-3034624f68d373d7c79237425319b5b7fd84317e.tar.bz2
Merge change I26a2d829 into eclair
* changes: Add -P flag to ps in dumpstate
-rw-r--r--cmds/dumpstate/dumpstate.c5
-rw-r--r--cmds/dumpstate/dumpstate.h18
2 files changed, 20 insertions, 3 deletions
diff --git a/cmds/dumpstate/dumpstate.c b/cmds/dumpstate/dumpstate.c
index ca8660c..642c943 100644
--- a/cmds/dumpstate/dumpstate.c
+++ b/cmds/dumpstate/dumpstate.c
@@ -86,9 +86,9 @@ static void dumpstate(int full) {
DUMP("/proc/wakelocks");
PRINT("");
PRINT("------ PROCESSES ------");
- EXEC("ps");
+ EXEC1("ps", "-P");
PRINT("------ PROCESSES AND THREADS ------");
- EXEC2("ps", "-t", "-p");
+ EXEC3("ps", "-t", "-p", "-P");
PRINT("------ LIBRANK ------");
EXEC_XBIN("librank");
PRINT("------ BINDER FAILED TRANSACTION LOG ------");
@@ -362,4 +362,3 @@ static void dump_kernel_log(const char *path, const char *title)
DUMP(path);
}
}
-
diff --git a/cmds/dumpstate/dumpstate.h b/cmds/dumpstate/dumpstate.h
index 6862e5a..b99b6d7 100644
--- a/cmds/dumpstate/dumpstate.h
+++ b/cmds/dumpstate/dumpstate.h
@@ -61,6 +61,15 @@
run_command(&c, TIMEOUT); \
}
+#define EXEC1(cmd, a1) \
+{ \
+ static struct Command c = { \
+ "/system/bin/" cmd, \
+ { cmd, a1, 0 } \
+ }; \
+ run_command(&c, TIMEOUT); \
+}
+
#define EXEC2(cmd, a1, a2) \
{ \
static struct Command c = { \
@@ -70,6 +79,15 @@
run_command(&c, TIMEOUT); \
}
+#define EXEC3(cmd, a1, a2, a3) \
+{ \
+ static struct Command c = { \
+ "/system/bin/" cmd, \
+ { cmd, a1, a2, a3, 0 } \
+ }; \
+ run_command(&c, TIMEOUT); \
+}
+
#define EXEC4(cmd, a1, a2, a3, a4) \
{ \
static struct Command c = { \