gralloc4: remove dumpDebugInfo

dumpDebugInfo could be called by anyone. A safer
approach is for processes to dump their own buffers
via IMapper's dumpBuffers.

Bug: 137966819
Test: Compiles
Change-Id: I4c8c7a6415babfb93034ee8674ba0f40cd8c1bb8
This commit is contained in:
Marissa Wall
2019-12-12 14:34:49 -08:00
parent 2a34cdb7ce
commit 6a2ecb424c
4 changed files with 0 additions and 24 deletions

View File

@@ -19,14 +19,6 @@ package android.hardware.graphics.allocator@4.0;
import android.hardware.graphics.mapper@4.0;
interface IAllocator {
/**
* Retrieves implementation-defined debug information, which will be
* displayed during, for example, `dumpsys SurfaceFlinger`.
*
* @return debugInfo is a string of debug information.
*/
dumpDebugInfo() generates (string debugInfo);
/**
* Allocates buffers with the properties specified by the descriptor.
*

View File

@@ -71,13 +71,6 @@ sp<IAllocator> Gralloc::getAllocator() const {
return mAllocator;
}
std::string Gralloc::dumpDebugInfo() {
std::string debugInfo;
mAllocator->dumpDebugInfo([&](const auto& tmpDebugInfo) { debugInfo = tmpDebugInfo.c_str(); });
return debugInfo;
}
const native_handle_t* Gralloc::cloneBuffer(const hidl_handle& rawHandle) {
const native_handle_t* bufferHandle = native_handle_clone(rawHandle.getNativeHandle());
EXPECT_NE(nullptr, bufferHandle);

View File

@@ -45,8 +45,6 @@ class Gralloc {
sp<IAllocator> getAllocator() const;
std::string dumpDebugInfo();
// When import is false, this simply calls IAllocator::allocate. When import
// is true, the returned buffers are also imported into the mapper.
//

View File

@@ -305,13 +305,6 @@ const std::set<StandardMetadataType> GraphicsMapperHidlTest::sRequiredMetadataTy
StandardMetadataType::BLEND_MODE,
};
/**
* Test IAllocator::dumpDebugInfo by calling it.
*/
TEST_P(GraphicsMapperHidlTest, AllocatorDumpDebugInfo) {
mGralloc->dumpDebugInfo();
}
/**
* Test IAllocator::allocate with valid buffer descriptors.
*/