dumpsys: Print total DMA-BUFs exported from the DMA-BUF heaps framework

This patch adds the total size of DMA-BUFs exported from the DMA-BUF
heaps framework to dumpsys meminfo.

Bug: 167709539
Test: adb shell dumpsys meminfo
Change-Id: I153721a0dc91ee5084a446ba1ce4f8ec9c51c4f0
Merged-In: I153721a0dc91ee5084a446ba1ce4f8ec9c51c4f0
This commit is contained in:
Hridya Valsaraju
2021-02-10 11:02:27 -08:00
parent 1a8d198b5b
commit 1ff4e91e6c
3 changed files with 39 additions and 0 deletions

View File

@@ -2559,6 +2559,14 @@ public final class Debug
*/
public static native long getDmabufTotalExportedKb();
/**
* Return total memory size in kilobytes for DMA-BUFs exported from the DMA-BUF
* heaps frameworks or -1 in the case of an error.
*
* @hide
*/
public static native long getDmabufHeapTotalExportedKb();
/**
* Return memory size in kilobytes allocated for ION heaps or -1 if
* /sys/kernel/ion/total_heaps_kb could not be read.