Support priority based dumpsys in surface flinger
Call dump with no args when called with CRITICAL priority. Register
service with support for critical priority dumps.
BUG: 31774394
Test: lunch mini_emulator_x86-userdebug && make -j56
Test: adb bugreport ~/tmp.zip
Test: adb shell dumpsys --priority CRITICAL
Test: mmm -j32 frameworks/native/services/utils && \
adb sync data && adb shell /data/nativetest/prioritydumper_test/prioritydumper_test && \
adb shell /data/nativetest64/prioritydumper_test/prioritydumper_test && \
printf "\n\n#### ALL TESTS PASSED ####\n"
Change-Id: Iec35ef8026d4d9346c83bab203bed8524c28bf89
diff --git a/services/surfaceflinger/SurfaceFlinger.cpp b/services/surfaceflinger/SurfaceFlinger.cpp
index f04cb88..5982422 100644
--- a/services/surfaceflinger/SurfaceFlinger.cpp
+++ b/services/surfaceflinger/SurfaceFlinger.cpp
@@ -3459,8 +3459,7 @@
// ---------------------------------------------------------------------------
-status_t SurfaceFlinger::dump(int fd, const Vector<String16>& args)
-{
+status_t SurfaceFlinger::doDump(int fd, const Vector<String16>& args) {
String8 result;
IPCThreadState* ipc = IPCThreadState::self();