Merge "media.c2 aidl: provide a waitable fd for blockpool creation" into main am: a9050e3ac0 am: 42655cc0d8 am: b7a7088042

Original change: https://android-review.googlesource.com/c/platform/hardware/interfaces/+/2805373

Change-Id: Ib29cffb5bcab11bd8c057c0194592f84a9c95daa
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Treehugger Robot
2023-10-28 08:09:06 +00:00
committed by Automerger Merge Worker
2 changed files with 20 additions and 2 deletions

View File

@@ -49,8 +49,12 @@ interface IComponent {
long blockPoolId;
android.hardware.media.c2.IConfigurable configurable;
}
parcelable C2AidlGbAllocator {
android.hardware.media.c2.IGraphicBufferAllocator igba;
ParcelFileDescriptor waitableFd;
}
union BlockPoolAllocator {
int allocatorId;
android.hardware.media.c2.IGraphicBufferAllocator igba;
android.hardware.media.c2.IComponent.C2AidlGbAllocator allocator;
}
}

View File

@@ -22,6 +22,8 @@ import android.hardware.media.c2.IComponentInterface;
import android.hardware.media.c2.IConfigurable;
import android.hardware.media.c2.IGraphicBufferAllocator;
import android.hardware.media.c2.WorkBundle;
import android.os.ParcelFileDescriptor;
/**
* Interface for an AIDL Codec2 component.
@@ -45,6 +47,18 @@ interface IComponent {
IConfigurable configurable;
}
/**
* C2AIDL allocator interface along with a waitable fd.
*
* The interface is used from a specific type of C2BlockPool to allocate
* graphic blocks. the waitable fd is used to create a specific type of
* C2Fence which can be used for waiting until to allocate is not blocked.
*/
parcelable C2AidlGbAllocator {
IGraphicBufferAllocator igba;
ParcelFileDescriptor waitableFd;
}
/**
* Allocator for C2BlockPool.
*
@@ -53,7 +67,7 @@ interface IComponent {
*/
union BlockPoolAllocator {
int allocatorId;
IGraphicBufferAllocator igba;
C2AidlGbAllocator allocator;
}
/**