summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEvan Millar <emillar@google.com>2009-10-29 13:46:31 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2009-10-29 13:46:31 -0700
commit50a59ec1e1bfcaf16d41c63c86f3ccf521c33a2c (patch)
tree7e42f449240512f4848a890e30d95801ab31b27f
parent881304ad5ce2023eb857e93267b45268c9907334 (diff)
parent3034624f68d373d7c79237425319b5b7fd84317e (diff)
downloadframeworks_base-50a59ec1e1bfcaf16d41c63c86f3ccf521c33a2c.zip
frameworks_base-50a59ec1e1bfcaf16d41c63c86f3ccf521c33a2c.tar.gz
frameworks_base-50a59ec1e1bfcaf16d41c63c86f3ccf521c33a2c.tar.bz2
am 3034624f: Merge change I26a2d829 into eclair
Merge commit '3034624f68d373d7c79237425319b5b7fd84317e' into eclair-plus-aosp * commit '3034624f68d373d7c79237425319b5b7fd84317e': 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 = { \