Fix unnecessary DmaBuffer copying in getIonMappedSizeKb
Change the loop to access DmaBuffer by reference rather than copying it. Bug: 138148041 Signed-off-by: Suren Baghdasaryan <surenb@google.com> Change-Id: I47fb49deb46d24897d75f350f4b47679cad37542
This commit is contained in:
@@ -826,7 +826,7 @@ static jlong android_os_Debug_getIonMappedSizeKb(JNIEnv* env, jobject clazz) {
|
||||
}
|
||||
}
|
||||
|
||||
for (dmabufinfo::DmaBuffer buf : dmabufs) {
|
||||
for (const dmabufinfo::DmaBuffer& buf : dmabufs) {
|
||||
ionPss += buf.size() / 1024;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user