summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Kalesh Singh <kaleshsingh@google.com> 2021-03-05 21:12:43 -0500
committer Kalesh Singh <kaleshsingh@google.com> 2021-03-08 21:36:06 +0000
commit66d2190ed6bdc6533f48ba4256b200555b9b3031 (patch)
tree697164690107e4cf74f06313aab98cd2088c4689
parent055977a3c956458b1b44d27d6e14e7466bf744c0 (diff)
getDmabufMappedSizeKb: Use ReadDmaBufMapRefs()
To allow clients more flexibility AppendDmaBufInfo() is being removed. It allowed reading both mapped and FD-referenced dmabufs, or just mapped dmabufs if read_fdrefs was specified as false. Internally the function called ReadDmaBufMapRefs() and ReadDmaBufFdRefs(). This change replaces AppendDmaBufInfo(read_fdrefs=false) with a call to the underlying ReadDmaBufMapRefs() api which is now made public. Bug: 181976677 Test: dmabufinfo_test Change-Id: I9c05f0be9fc4d9cd40cdb146f3f6ca4860f7cd0f
-rw-r--r--core/jni/android_os_Debug.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/jni/android_os_Debug.cpp b/core/jni/android_os_Debug.cpp
index 0e3db46bd0c9..f379ba0ddebb 100644
--- a/core/jni/android_os_Debug.cpp
+++ b/core/jni/android_os_Debug.cpp
@@ -902,7 +902,7 @@ static jlong android_os_Debug_getDmabufMappedSizeKb(JNIEnv* env, jobject clazz)
continue;
}
- if (!AppendDmaBufInfo(pid, &dmabufs, false)) {
+ if (!ReadDmaBufMapRefs(pid, &dmabufs)) {
LOG(ERROR) << "Failed to read maps for pid " << pid;
}
}