mirror of
https://github.com/Evolution-X/hardware_interfaces
synced 2026-02-01 16:50:18 +00:00
Merge changes from topic "lazy-dumpstate"
* changes: Make dumpstate HAL lazy. dumpstate: add interface into rc file
This commit is contained in:
committed by
Gerrit Code Review
commit
5c2a8265c6
@@ -18,6 +18,7 @@
|
||||
|
||||
#include "DumpstateDevice.h"
|
||||
|
||||
#include <hidl/HidlBinderSupport.h>
|
||||
#include <log/log.h>
|
||||
|
||||
#include "DumpstateUtil.h"
|
||||
@@ -37,6 +38,11 @@ Return<void> DumpstateDevice::dumpstateBoard(const hidl_handle& handle) {
|
||||
// this interface - since HIDL_FETCH_IDumpstateDevice() is not defined, this function will never
|
||||
// be called by dumpstate.
|
||||
|
||||
// Exit when dump is completed since this is a lazy HAL.
|
||||
addPostCommandTask([]() {
|
||||
exit(0);
|
||||
});
|
||||
|
||||
if (handle == nullptr || handle->numFds < 1) {
|
||||
ALOGE("no FDs\n");
|
||||
return Void();
|
||||
|
||||
@@ -2,3 +2,6 @@ service dumpstate-1-0 /vendor/bin/hw/android.hardware.dumpstate@1.0-service
|
||||
class hal
|
||||
user system
|
||||
group system
|
||||
interface android.hardware.dumpstate@1.0::IDumpstateDevice default
|
||||
oneshot
|
||||
disabled
|
||||
|
||||
Reference in New Issue
Block a user