diff options
| author | 2019-09-10 21:36:39 +0000 | |
|---|---|---|
| committer | 2019-09-10 21:36:39 +0000 | |
| commit | 45f75b719dc480e915b9fce16a1e417423b2caf1 (patch) | |
| tree | 7930fb1897eea9115be83472673bef077daa9739 | |
| parent | 6ae4e4c182a71701ab6ee2829ca84a4cd5c84201 (diff) | |
| parent | d9ba4754dc19ed745934ee70bebcec26d0200433 (diff) | |
Merge "dumpstate: Log logical partition metadata in bugreports"
| -rw-r--r-- | cmds/dumpstate/Android.bp | 2 | ||||
| -rw-r--r-- | cmds/dumpstate/dumpstate.cpp | 9 |
2 files changed, 11 insertions, 0 deletions
diff --git a/cmds/dumpstate/Android.bp b/cmds/dumpstate/Android.bp index 519b13bd01..09aee89e1b 100644 --- a/cmds/dumpstate/Android.bp +++ b/cmds/dumpstate/Android.bp @@ -118,6 +118,8 @@ cc_binary { "kill", "librank", "logcat", + "lpdump", + "lpdumpd", "lsmod", "lsof", "netstat", diff --git a/cmds/dumpstate/dumpstate.cpp b/cmds/dumpstate/dumpstate.cpp index c98784e681..693525ae68 100644 --- a/cmds/dumpstate/dumpstate.cpp +++ b/cmds/dumpstate/dumpstate.cpp @@ -929,6 +929,14 @@ static void DumpIpTablesAsRoot() { RunCommand("IP6TABLES RAW", {"ip6tables", "-t", "raw", "-L", "-nvx"}); } +static void DumpDynamicPartitionInfo() { + if (!::android::base::GetBoolProperty("ro.boot.dynamic_partitions", false)) { + return; + } + + RunCommand("LPDUMP", {"lpdump", "--all"}); +} + static void AddAnrTraceDir(const bool add_to_zip, const std::string& anr_traces_dir) { MYLOGD("AddAnrTraceDir(): dump_traces_file=%s, anr_traces_dir=%s\n", dump_traces_path, anr_traces_dir.c_str()); @@ -1515,6 +1523,7 @@ static Dumpstate::RunStatus DumpstateDefault() { } add_mountinfo(); DumpIpTablesAsRoot(); + DumpDynamicPartitionInfo(); // Capture any IPSec policies in play. No keys are exposed here. RunCommand("IP XFRM POLICY", {"ip", "xfrm", "policy"}, CommandOptions::WithTimeout(10).Build()); |