Sync up to v222

This commit is contained in:
Andy CrossGate Yan 2020-08-06 12:01:41 +00:00
parent 7003515879
commit 85c08ba1de
11 changed files with 0 additions and 942 deletions

View File

@ -1,39 +0,0 @@
From efbdeeea6ac6ac7e6a33ba9034d0d26a2da2c92e Mon Sep 17 00:00:00 2001
From: Danny Baumann <dannybaumann@web.de>
Date: Wed, 29 Aug 2018 11:21:52 +0200
Subject: [PATCH 1/6] Implement per-process target SDK version override.
Change-Id: I65bbdbe96541d8aacdd4de125cdb9c1435129413
This is only partial cherry-pick. Value won't be set via Android.bp
---
linker/linker.cpp | 13 ++++++++++++-
1 file changed, 12 insertions(+), 1 deletion(-)
diff --git a/linker/linker.cpp b/linker/linker.cpp
index b59df7302..ccdb131ca 100644
--- a/linker/linker.cpp
+++ b/linker/linker.cpp
@@ -4217,7 +4217,18 @@ std::vector<android_namespace_t*> init_default_namespaces(const char* executable
// somain and ld_preloads are added to these namespaces after LD_PRELOAD libs are linked
}
- set_application_target_sdk_version(config->target_sdk_version());
+ uint32_t target_sdk = config->target_sdk_version();
+#ifdef SDK_VERSION_OVERRIDES
+ for (const auto& entry : android::base::Split(SDK_VERSION_OVERRIDES, " ")) {
+ auto splitted = android::base::Split(entry, "=");
+ if (splitted.size() == 2 && splitted[0] == executable_path) {
+ target_sdk = static_cast<uint32_t>(std::stoul(splitted[1]));
+ break;
+ }
+ }
+ DEBUG("Target SDK for %s = %d", executable_path, target_sdk);
+#endif
+ set_application_target_sdk_version(target_sdk);
std::vector<android_namespace_t*> created_namespaces;
created_namespaces.reserve(namespaces.size());
--
2.17.1

View File

@ -1,38 +0,0 @@
From 13acd597e0dd22c5fa462007b20fe4f2398db297 Mon Sep 17 00:00:00 2001
From: Pierre-Hugues Husson <phh@phh.me>
Date: Thu, 12 Sep 2019 13:00:55 +0200
Subject: [PATCH 6/6] fixup! Actually restore pre-P mutex behavior
---
libc/bionic/pthread_mutex.cpp | 8 +-------
1 file changed, 1 insertion(+), 7 deletions(-)
diff --git a/libc/bionic/pthread_mutex.cpp b/libc/bionic/pthread_mutex.cpp
index 969feb43c..bd9fabdb6 100644
--- a/libc/bionic/pthread_mutex.cpp
+++ b/libc/bionic/pthread_mutex.cpp
@@ -528,7 +528,7 @@ int pthread_mutex_init(pthread_mutex_t* mutex_interface, const pthread_mutexattr
}
if (((*attr & MUTEXATTR_PROTOCOL_MASK) >> MUTEXATTR_PROTOCOL_SHIFT) == PTHREAD_PRIO_INHERIT
- && bionic_get_application_target_sdk_version() >= __ANDROID_API_P__) {
+ && android_get_application_target_sdk_version() >= __ANDROID_API_P__) {
#if !defined(__LP64__)
if (state & MUTEX_SHARED_MASK) {
return EINVAL;
@@ -798,12 +798,6 @@ static int __attribute__((noinline)) HandleUsingDestroyedMutex(pthread_mutex_t*
return EBUSY;
}
-static int __always_inline HandleUsingDestroyedMutex(pthread_mutex_t* mutex,
- const char* function_name) {
- __fortify_fatal("%s called on a destroyed mutex (%p)", function_name, mutex);
- return EBUSY;
-}
-
int pthread_mutex_lock(pthread_mutex_t* mutex_interface) {
#if !defined(__LP64__)
// Some apps depend on being able to pass NULL as a mutex and get EINVAL
--
2.17.1

View File

@ -1,327 +0,0 @@
From 291ef6981994f98173d6a6505aa89a018d7bedd3 Mon Sep 17 00:00:00 2001
From: Stan Iliev <stani@google.com>
Date: Thu, 1 Aug 2019 14:22:34 -0400
Subject: [PATCH 2/2] Allow to rebind GL texture if AHB content has changed
Add an output function argument updateProc to MakeBackendTexture.
updateProc needs to be invoked, when AHB buffer content has
changed. OES_EGL_image_external spec requires to bind the
texture, when buffer content has changed.
glEGLImageTargetTexture2DOES is invoked too (spec is not clear,
but MTK devices require it).
Test: Built and ran android
Bug: b/138674291
Change-Id: I4e20885931d1446c45119eec1b992a85bcd97450
Merged-In: Ib5f15408e766c1e5344f18c287a202c1853ddd20
---
src/gpu/GrAHardwareBufferImageGenerator.cpp | 12 ++--
src/gpu/GrAHardwareBufferUtils.cpp | 70 +++++++++++++++++----
src/gpu/GrAHardwareBufferUtils.h | 39 +++++++++++-
src/image/SkImage_Gpu.cpp | 7 ++-
src/image/SkSurface_Gpu.cpp | 9 +--
5 files changed, 110 insertions(+), 27 deletions(-)
diff --git a/src/gpu/GrAHardwareBufferImageGenerator.cpp b/src/gpu/GrAHardwareBufferImageGenerator.cpp
index 205595526f..2dcdeb5911 100644
--- a/src/gpu/GrAHardwareBufferImageGenerator.cpp
+++ b/src/gpu/GrAHardwareBufferImageGenerator.cpp
@@ -152,20 +152,22 @@ sk_sp<GrTextureProxy> GrAHardwareBufferImageGenerator::makeProxy(GrRecordingCont
[direct, buffer = AutoAHBRelease(hardwareBuffer), width, height, pixelConfig,
isProtectedContent, backendFormat](GrResourceProvider* resourceProvider) {
GrAHardwareBufferUtils::DeleteImageProc deleteImageProc = nullptr;
- GrAHardwareBufferUtils::DeleteImageCtx deleteImageCtx = nullptr;
+ GrAHardwareBufferUtils::UpdateImageProc updateImageProc = nullptr;
+ GrAHardwareBufferUtils::TexImageCtx texImageCtx = nullptr;
GrBackendTexture backendTex =
GrAHardwareBufferUtils::MakeBackendTexture(direct, buffer.get(),
width, height,
&deleteImageProc,
- &deleteImageCtx,
+ &updateImageProc,
+ &texImageCtx,
isProtectedContent,
backendFormat,
false);
if (!backendTex.isValid()) {
return sk_sp<GrTexture>();
}
- SkASSERT(deleteImageProc && deleteImageCtx);
+ SkASSERT(deleteImageProc && texImageCtx);
backendTex.fConfig = pixelConfig;
// We make this texture cacheable to avoid recreating a GrTexture every time this
@@ -174,12 +176,12 @@ sk_sp<GrTextureProxy> GrAHardwareBufferImageGenerator::makeProxy(GrRecordingCont
sk_sp<GrTexture> tex = resourceProvider->wrapBackendTexture(
backendTex, kBorrow_GrWrapOwnership, GrWrapCacheable::kYes, kRead_GrIOType);
if (!tex) {
- deleteImageProc(deleteImageCtx);
+ deleteImageProc(texImageCtx);
return sk_sp<GrTexture>();
}
if (deleteImageProc) {
- tex->setRelease(deleteImageProc, deleteImageCtx);
+ tex->setRelease(deleteImageProc, texImageCtx);
}
return tex;
diff --git a/src/gpu/GrAHardwareBufferUtils.cpp b/src/gpu/GrAHardwareBufferUtils.cpp
index 43272cea33..f22343a804 100644
--- a/src/gpu/GrAHardwareBufferUtils.cpp
+++ b/src/gpu/GrAHardwareBufferUtils.cpp
@@ -157,33 +157,59 @@ GrBackendFormat GetBackendFormat(GrContext* context, AHardwareBuffer* hardwareBu
return GrBackendFormat();
}
-class GLCleanupHelper {
+class GLTextureHelper {
public:
- GLCleanupHelper(GrGLuint texID, EGLImageKHR image, EGLDisplay display)
+ GLTextureHelper(GrGLuint texID, EGLImageKHR image, EGLDisplay display, GrGLuint texTarget)
: fTexID(texID)
, fImage(image)
- , fDisplay(display) { }
- ~GLCleanupHelper() {
+ , fDisplay(display)
+ , fTexTarget(texTarget) { }
+ ~GLTextureHelper() {
glDeleteTextures(1, &fTexID);
// eglDestroyImageKHR will remove a ref from the AHardwareBuffer
eglDestroyImageKHR(fDisplay, fImage);
}
+ void rebind(GrContext* grContext);
+
private:
GrGLuint fTexID;
EGLImageKHR fImage;
EGLDisplay fDisplay;
+ GrGLuint fTexTarget;
};
+void GLTextureHelper::rebind(GrContext* grContext) {
+ glBindTexture(fTexTarget, fTexID);
+ GLenum status = GL_NO_ERROR;
+ if ((status = glGetError()) != GL_NO_ERROR) {
+ SkDebugf("glBindTexture(%#x, %d) failed (%#x)", (int) fTexTarget,
+ (int) fTexID, (int) status);
+ return;
+ }
+ glEGLImageTargetTexture2DOES(fTexTarget, fImage);
+ if ((status = glGetError()) != GL_NO_ERROR) {
+ SkDebugf("glEGLImageTargetTexture2DOES failed (%#x)", (int) status);
+ return;
+ }
+ grContext->resetContext(kTextureBinding_GrGLBackendState);
+}
+
void delete_gl_texture(void* context) {
- GLCleanupHelper* cleanupHelper = static_cast<GLCleanupHelper*>(context);
+ GLTextureHelper* cleanupHelper = static_cast<GLTextureHelper*>(context);
delete cleanupHelper;
}
+void update_gl_texture(void* context, GrContext* grContext) {
+ GLTextureHelper* cleanupHelper = static_cast<GLTextureHelper*>(context);
+ cleanupHelper->rebind(grContext);
+}
+
static GrBackendTexture make_gl_backend_texture(
GrContext* context, AHardwareBuffer* hardwareBuffer,
int width, int height,
DeleteImageProc* deleteProc,
- DeleteImageCtx* deleteCtx,
+ UpdateImageProc* updateProc,
+ TexImageCtx* imageCtx,
bool isProtectedContent,
const GrBackendFormat& backendFormat,
bool isRenderable) {
@@ -236,7 +262,8 @@ static GrBackendTexture make_gl_backend_texture(
textureInfo.fFormat = *backendFormat.getGLFormat();
*deleteProc = delete_gl_texture;
- *deleteCtx = new GLCleanupHelper(texID, image, display);
+ *updateProc = update_gl_texture;
+ *imageCtx = new GLTextureHelper(texID, image, display, target);
return GrBackendTexture(width, height, GrMipMapped::kNo, textureInfo);
}
@@ -267,11 +294,16 @@ void delete_vk_image(void* context) {
delete cleanupHelper;
}
+void update_vk_image(void* context, GrContext* grContext) {
+ // no op
+}
+
static GrBackendTexture make_vk_backend_texture(
GrContext* context, AHardwareBuffer* hardwareBuffer,
int width, int height,
DeleteImageProc* deleteProc,
- DeleteImageCtx* deleteCtx,
+ UpdateImageProc* updateProc,
+ TexImageCtx* imageCtx,
bool isProtectedContent,
const GrBackendFormat& backendFormat,
bool isRenderable) {
@@ -456,7 +488,8 @@ static GrBackendTexture make_vk_backend_texture(
imageInfo.fYcbcrConversionInfo = *ycbcrConversion;
*deleteProc = delete_vk_image;
- *deleteCtx = new VulkanCleanupHelper(gpu, image, memory);
+ *updateProc = update_vk_image;
+ *imageCtx = new VulkanCleanupHelper(gpu, image, memory);
return GrBackendTexture(width, height, imageInfo);
}
@@ -489,7 +522,8 @@ static bool can_import_protected_content(GrContext* context) {
GrBackendTexture MakeBackendTexture(GrContext* context, AHardwareBuffer* hardwareBuffer,
int width, int height,
DeleteImageProc* deleteProc,
- DeleteImageCtx* deleteCtx,
+ UpdateImageProc* updateProc,
+ TexImageCtx* imageCtx,
bool isProtectedContent,
const GrBackendFormat& backendFormat,
bool isRenderable) {
@@ -500,7 +534,7 @@ GrBackendTexture MakeBackendTexture(GrContext* context, AHardwareBuffer* hardwar
if (GrBackendApi::kOpenGL == context->backend()) {
return make_gl_backend_texture(context, hardwareBuffer, width, height, deleteProc,
- deleteCtx, createProtectedImage, backendFormat,
+ updateProc, imageCtx, createProtectedImage, backendFormat,
isRenderable);
} else {
SkASSERT(GrBackendApi::kVulkan == context->backend());
@@ -508,7 +542,7 @@ GrBackendTexture MakeBackendTexture(GrContext* context, AHardwareBuffer* hardwar
// Currently we don't support protected images on vulkan
SkASSERT(!createProtectedImage);
return make_vk_backend_texture(context, hardwareBuffer, width, height, deleteProc,
- deleteCtx, createProtectedImage, backendFormat,
+ updateProc, imageCtx, createProtectedImage, backendFormat,
isRenderable);
#else
return GrBackendTexture();
@@ -516,6 +550,18 @@ GrBackendTexture MakeBackendTexture(GrContext* context, AHardwareBuffer* hardwar
}
}
+GrBackendTexture MakeBackendTexture(GrContext* context, AHardwareBuffer* hardwareBuffer,
+ int width, int height,
+ DeleteImageProc* deleteProc,
+ TexImageCtx* imageCtx,
+ bool isProtectedContent,
+ const GrBackendFormat& backendFormat,
+ bool isRenderable) {
+ UpdateImageProc updateProc;
+ return MakeBackendTexture(context, hardwareBuffer, width, height, deleteProc, &updateProc,
+ imageCtx, isProtectedContent, backendFormat, isRenderable);
+}
+
} // GrAHardwareBufferUtils
#endif
diff --git a/src/gpu/GrAHardwareBufferUtils.h b/src/gpu/GrAHardwareBufferUtils.h
index 31cb1407a5..8e637452df 100644
--- a/src/gpu/GrAHardwareBufferUtils.h
+++ b/src/gpu/GrAHardwareBufferUtils.h
@@ -27,13 +27,46 @@ SkColorType GetSkColorTypeFromBufferFormat(uint32_t bufferFormat);
GrBackendFormat GetBackendFormat(GrContext* context, AHardwareBuffer* hardwareBuffer,
uint32_t bufferFormat, bool requireKnownFormat);
-typedef void* DeleteImageCtx;
-typedef void (*DeleteImageProc)(DeleteImageCtx);
+typedef void* TexImageCtx;
+typedef void (*DeleteImageProc)(TexImageCtx);
+typedef void (*UpdateImageProc)(TexImageCtx, GrContext*);
+//TODO: delete this function after clients stop using it.
GrBackendTexture MakeBackendTexture(GrContext* context, AHardwareBuffer* hardwareBuffer,
int width, int height,
DeleteImageProc* deleteProc,
- DeleteImageCtx* deleteCtx,
+ TexImageCtx* imageCtx,
+ bool isProtectedContent,
+ const GrBackendFormat& backendFormat,
+ bool isRenderable);
+
+/**
+ * Create a GrBackendTexture from AHardwareBuffer
+ *
+ * @param context GPU context
+ * @param hardwareBuffer AHB
+ * @param width texture width
+ * @param height texture height
+ * @param deleteProc returns a function that deletes the texture and
+ * other GPU resources. Must be invoked on the same
+ * thread as MakeBackendTexture
+ * @param updateProc returns a function, that needs to be invoked, when
+ * AHB buffer content has changed. Must be invoked on
+ * the same thread as MakeBackendTexture
+ * @param imageCtx returns an opaque image context, that is passed as
+ * first argument to deleteProc and updateProc
+ * @param isProtectedContent if true, GL backend uses EXT_protected_content
+ * @param backendFormat backend format, usually created with helper
+ * function GetBackendFormat
+ * @param isRenderable true if GrBackendTexture can be used as a color
+ * attachment
+ * @return valid GrBackendTexture object on success
+ */
+GrBackendTexture MakeBackendTexture(GrContext* context, AHardwareBuffer* hardwareBuffer,
+ int width, int height,
+ DeleteImageProc* deleteProc,
+ UpdateImageProc* updateProc,
+ TexImageCtx* imageCtx,
bool isProtectedContent,
const GrBackendFormat& backendFormat,
bool isRenderable);
diff --git a/src/image/SkImage_Gpu.cpp b/src/image/SkImage_Gpu.cpp
index eb64b8cf19..708286eb43 100644
--- a/src/image/SkImage_Gpu.cpp
+++ b/src/image/SkImage_Gpu.cpp
@@ -613,13 +613,14 @@ sk_sp<SkImage> SkImage::MakeFromAHardwareBufferWithData(GrContext* context,
}
GrAHardwareBufferUtils::DeleteImageProc deleteImageProc = nullptr;
- GrAHardwareBufferUtils::DeleteImageCtx deleteImageCtx = nullptr;
+ GrAHardwareBufferUtils::UpdateImageProc updateImageProc = nullptr;
+ GrAHardwareBufferUtils::TexImageCtx deleteImageCtx = nullptr;
GrBackendTexture backendTexture =
GrAHardwareBufferUtils::MakeBackendTexture(context, hardwareBuffer,
bufferDesc.width, bufferDesc.height,
- &deleteImageProc, &deleteImageCtx,
- false, backendFormat, true);
+ &deleteImageProc, &updateImageProc,
+ &deleteImageCtx, false, backendFormat, true);
if (!backendTexture.isValid()) {
return nullptr;
}
diff --git a/src/image/SkSurface_Gpu.cpp b/src/image/SkSurface_Gpu.cpp
index 5a2a12d485..cd340000ae 100644
--- a/src/image/SkSurface_Gpu.cpp
+++ b/src/image/SkSurface_Gpu.cpp
@@ -617,14 +617,15 @@ sk_sp<SkSurface> SkSurface::MakeFromAHardwareBuffer(GrContext* context,
if (isTextureable) {
GrAHardwareBufferUtils::DeleteImageProc deleteImageProc = nullptr;
- GrAHardwareBufferUtils::DeleteImageCtx deleteImageCtx = nullptr;
+ GrAHardwareBufferUtils::UpdateImageProc updateImageProc = nullptr;
+ GrAHardwareBufferUtils::TexImageCtx deleteImageCtx = nullptr;
GrBackendTexture backendTexture =
GrAHardwareBufferUtils::MakeBackendTexture(context, hardwareBuffer,
bufferDesc.width, bufferDesc.height,
- &deleteImageProc, &deleteImageCtx,
- isProtectedContent, backendFormat,
- true);
+ &deleteImageProc, &updateImageProc,
+ &deleteImageCtx, isProtectedContent,
+ backendFormat, true);
if (!backendTexture.isValid()) {
return nullptr;
}
--
2.17.1

View File

@ -1,36 +0,0 @@
From 1c4a894af6bb803164eb43f7dd7ae32fcdd24dbf Mon Sep 17 00:00:00 2001
From: Pierre-Hugues Husson <phh@phh.me>
Date: Sun, 12 Apr 2020 16:11:09 +0200
Subject: [PATCH 14/21] Ignore unknown audio codecs in media profiles'
AudioEncoder Cap
---
media/libmedia/MediaProfiles.cpp | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/media/libmedia/MediaProfiles.cpp b/media/libmedia/MediaProfiles.cpp
index 98c54971ad..08d0199a07 100644
--- a/media/libmedia/MediaProfiles.cpp
+++ b/media/libmedia/MediaProfiles.cpp
@@ -300,6 +300,7 @@ MediaProfiles::createAudioEncoderCap(const char **atts)
const size_t nMappings = sizeof(sAudioEncoderNameMap)/sizeof(sAudioEncoderNameMap[0]);
const int codec = findTagForName(sAudioEncoderNameMap, nMappings, atts[1]);
+ if(codec == -1) return nullptr;
CHECK(codec != -1);
MediaProfiles::AudioEncoderCap *cap =
@@ -419,7 +420,9 @@ MediaProfiles::startElementHandler(void *userData, const char *name, const char
profiles->mVideoEncoders.add(createVideoEncoderCap(atts));
} else if (strcmp("AudioEncoderCap", name) == 0 &&
strcmp("true", atts[3]) == 0) {
- profiles->mAudioEncoders.add(createAudioEncoderCap(atts));
+ MediaProfiles::AudioEncoderCap* cap = createAudioEncoderCap(atts);
+ if(cap != nullptr)
+ profiles->mAudioEncoders.add(cap);
} else if (strcmp("VideoDecoderCap", name) == 0 &&
strcmp("true", atts[3]) == 0) {
profiles->mVideoDecoders.add(createVideoDecoderCap(atts));
--
2.17.1

View File

@ -1,42 +0,0 @@
From 7f6429fa4982c534ba6c0fd3cfd2eba1e8ffe80d Mon Sep 17 00:00:00 2001
From: Pierre-Hugues Husson <phh@phh.me>
Date: Fri, 17 Apr 2020 23:15:08 +0200
Subject: [PATCH 16/21] Ignore broken camcorder profiles
---
media/libmedia/MediaProfiles.cpp | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/media/libmedia/MediaProfiles.cpp b/media/libmedia/MediaProfiles.cpp
index 08d0199a07..0944c973db 100644
--- a/media/libmedia/MediaProfiles.cpp
+++ b/media/libmedia/MediaProfiles.cpp
@@ -341,10 +341,12 @@ MediaProfiles::createCamcorderProfile(int cameraId, const char **atts, Vector<in
const size_t nProfileMappings = sizeof(sCamcorderQualityNameMap)/
sizeof(sCamcorderQualityNameMap[0]);
const int quality = findTagForName(sCamcorderQualityNameMap, nProfileMappings, atts[1]);
+ if(quality == -1) return nullptr;
CHECK(quality != -1);
const size_t nFormatMappings = sizeof(sFileFormatMap)/sizeof(sFileFormatMap[0]);
const int fileFormat = findTagForName(sFileFormatMap, nFormatMappings, atts[3]);
+ if(fileFormat == -1) return nullptr;
CHECK(fileFormat != -1);
MediaProfiles::CamcorderProfile *profile = new MediaProfiles::CamcorderProfile;
@@ -435,8 +437,10 @@ MediaProfiles::startElementHandler(void *userData, const char *name, const char
profiles->mCurrentCameraId = getCameraId(atts);
profiles->addStartTimeOffset(profiles->mCurrentCameraId, atts);
} else if (strcmp("EncoderProfile", name) == 0) {
- profiles->mCamcorderProfiles.add(
- createCamcorderProfile(profiles->mCurrentCameraId, atts, profiles->mCameraIds));
+ MediaProfiles::CamcorderProfile* profile = createCamcorderProfile(profiles->mCurrentCameraId, atts, profiles->mCameraIds);
+ if(profile != nullptr) {
+ profiles->mCamcorderProfiles.add(profile);
+ }
} else if (strcmp("ImageEncoding", name) == 0) {
profiles->addImageEncodingQualityLevel(profiles->mCurrentCameraId, atts);
}
--
2.17.1

View File

@ -1,45 +0,0 @@
From 30a73a881ec671fd02fc25a3e38838bbe1454813 Mon Sep 17 00:00:00 2001
From: Pierre-Hugues Husson <phh@phh.me>
Date: Wed, 29 Apr 2020 00:15:49 +0200
Subject: [PATCH 17/21] Revert "Ignore broken camcorder profiles"
This reverts commit 5caabfcd03ca00211a0419ec3c04cff1a4efcf9e.
Will use upstream's better alternative
---
media/libmedia/MediaProfiles.cpp | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)
diff --git a/media/libmedia/MediaProfiles.cpp b/media/libmedia/MediaProfiles.cpp
index 0944c973db..08d0199a07 100644
--- a/media/libmedia/MediaProfiles.cpp
+++ b/media/libmedia/MediaProfiles.cpp
@@ -341,12 +341,10 @@ MediaProfiles::createCamcorderProfile(int cameraId, const char **atts, Vector<in
const size_t nProfileMappings = sizeof(sCamcorderQualityNameMap)/
sizeof(sCamcorderQualityNameMap[0]);
const int quality = findTagForName(sCamcorderQualityNameMap, nProfileMappings, atts[1]);
- if(quality == -1) return nullptr;
CHECK(quality != -1);
const size_t nFormatMappings = sizeof(sFileFormatMap)/sizeof(sFileFormatMap[0]);
const int fileFormat = findTagForName(sFileFormatMap, nFormatMappings, atts[3]);
- if(fileFormat == -1) return nullptr;
CHECK(fileFormat != -1);
MediaProfiles::CamcorderProfile *profile = new MediaProfiles::CamcorderProfile;
@@ -437,10 +435,8 @@ MediaProfiles::startElementHandler(void *userData, const char *name, const char
profiles->mCurrentCameraId = getCameraId(atts);
profiles->addStartTimeOffset(profiles->mCurrentCameraId, atts);
} else if (strcmp("EncoderProfile", name) == 0) {
- MediaProfiles::CamcorderProfile* profile = createCamcorderProfile(profiles->mCurrentCameraId, atts, profiles->mCameraIds);
- if(profile != nullptr) {
- profiles->mCamcorderProfiles.add(profile);
- }
+ profiles->mCamcorderProfiles.add(
+ createCamcorderProfile(profiles->mCurrentCameraId, atts, profiles->mCameraIds));
} else if (strcmp("ImageEncoding", name) == 0) {
profiles->addImageEncodingQualityLevel(profiles->mCurrentCameraId, atts);
}
--
2.17.1

View File

@ -1,37 +0,0 @@
From 3e491a01db93c380807138228337102ffcf6893a Mon Sep 17 00:00:00 2001
From: Pierre-Hugues Husson <phh@phh.me>
Date: Wed, 29 Apr 2020 00:17:01 +0200
Subject: [PATCH 18/21] Revert "Ignore unknown audio codecs in media profiles'
AudioEncoder Cap"
This reverts commit ee00227dc5ddfc88b13fa37ba96f846950c03b4e.
---
media/libmedia/MediaProfiles.cpp | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/media/libmedia/MediaProfiles.cpp b/media/libmedia/MediaProfiles.cpp
index 08d0199a07..98c54971ad 100644
--- a/media/libmedia/MediaProfiles.cpp
+++ b/media/libmedia/MediaProfiles.cpp
@@ -300,7 +300,6 @@ MediaProfiles::createAudioEncoderCap(const char **atts)
const size_t nMappings = sizeof(sAudioEncoderNameMap)/sizeof(sAudioEncoderNameMap[0]);
const int codec = findTagForName(sAudioEncoderNameMap, nMappings, atts[1]);
- if(codec == -1) return nullptr;
CHECK(codec != -1);
MediaProfiles::AudioEncoderCap *cap =
@@ -420,9 +419,7 @@ MediaProfiles::startElementHandler(void *userData, const char *name, const char
profiles->mVideoEncoders.add(createVideoEncoderCap(atts));
} else if (strcmp("AudioEncoderCap", name) == 0 &&
strcmp("true", atts[3]) == 0) {
- MediaProfiles::AudioEncoderCap* cap = createAudioEncoderCap(atts);
- if(cap != nullptr)
- profiles->mAudioEncoders.add(cap);
+ profiles->mAudioEncoders.add(createAudioEncoderCap(atts));
} else if (strcmp("VideoDecoderCap", name) == 0 &&
strcmp("true", atts[3]) == 0) {
profiles->mVideoDecoders.add(createVideoDecoderCap(atts));
--
2.17.1

View File

@ -1,140 +0,0 @@
From 3a0b6a588a9cf02fdc5b47644ed446687469a025 Mon Sep 17 00:00:00 2001
From: Alex Zhang <difan@google.com>
Date: Fri, 17 Apr 2020 16:08:24 -0700
Subject: [PATCH 19/21] Allow graceful degradation of MediaProfile with broken
configuration.
Currently, when media profile declares something unsupported / broken,
MediaProfile will crash. This patch will change the behavior to
gracefully degradation instead. b/147701370 is an example IRL. If
vendor declares profile unsupported in AOSP, Treble firmware will crash
instead of having a non-working or suboptimally working camera.
Test: Compiles
Signed-off-by: Alex Zhang <difan@google.com>
Change-Id: Icc0f85fe0aac748be4d4f7dd94814f615d528a03
---
media/libmedia/MediaProfiles.cpp | 42 +++++++++++++++++++++-----------
1 file changed, 28 insertions(+), 14 deletions(-)
diff --git a/media/libmedia/MediaProfiles.cpp b/media/libmedia/MediaProfiles.cpp
index 98c54971ad..366d90de9e 100644
--- a/media/libmedia/MediaProfiles.cpp
+++ b/media/libmedia/MediaProfiles.cpp
@@ -194,7 +194,7 @@ MediaProfiles::createVideoCodec(const char **atts, MediaProfiles *profiles)
const size_t nMappings = sizeof(sVideoEncoderNameMap)/sizeof(sVideoEncoderNameMap[0]);
const int codec = findTagForName(sVideoEncoderNameMap, nMappings, atts[1]);
- CHECK(codec != -1);
+ if (codec == -1) return nullptr;
MediaProfiles::VideoCodec *videoCodec =
new MediaProfiles::VideoCodec(static_cast<video_encoder>(codec),
@@ -216,7 +216,7 @@ MediaProfiles::createAudioCodec(const char **atts, MediaProfiles *profiles)
!strcmp("channels", atts[6]));
const size_t nMappings = sizeof(sAudioEncoderNameMap)/sizeof(sAudioEncoderNameMap[0]);
const int codec = findTagForName(sAudioEncoderNameMap, nMappings, atts[1]);
- CHECK(codec != -1);
+ if (codec == -1) return nullptr;
MediaProfiles::AudioCodec *audioCodec =
new MediaProfiles::AudioCodec(static_cast<audio_encoder>(codec),
@@ -236,7 +236,7 @@ MediaProfiles::createAudioDecoderCap(const char **atts)
const size_t nMappings = sizeof(sAudioDecoderNameMap)/sizeof(sAudioDecoderNameMap[0]);
const int codec = findTagForName(sAudioDecoderNameMap, nMappings, atts[1]);
- CHECK(codec != -1);
+ if (codec == -1) return nullptr;
MediaProfiles::AudioDecoderCap *cap =
new MediaProfiles::AudioDecoderCap(static_cast<audio_decoder>(codec));
@@ -252,7 +252,7 @@ MediaProfiles::createVideoDecoderCap(const char **atts)
const size_t nMappings = sizeof(sVideoDecoderNameMap)/sizeof(sVideoDecoderNameMap[0]);
const int codec = findTagForName(sVideoDecoderNameMap, nMappings, atts[1]);
- CHECK(codec != -1);
+ if (codec == -1) return nullptr;
MediaProfiles::VideoDecoderCap *cap =
new MediaProfiles::VideoDecoderCap(static_cast<video_decoder>(codec));
@@ -276,7 +276,7 @@ MediaProfiles::createVideoEncoderCap(const char **atts)
const size_t nMappings = sizeof(sVideoEncoderNameMap)/sizeof(sVideoEncoderNameMap[0]);
const int codec = findTagForName(sVideoEncoderNameMap, nMappings, atts[1]);
- CHECK(codec != -1);
+ if (codec == -1) return nullptr;
MediaProfiles::VideoEncoderCap *cap =
new MediaProfiles::VideoEncoderCap(static_cast<video_encoder>(codec),
@@ -300,7 +300,7 @@ MediaProfiles::createAudioEncoderCap(const char **atts)
const size_t nMappings = sizeof(sAudioEncoderNameMap)/sizeof(sAudioEncoderNameMap[0]);
const int codec = findTagForName(sAudioEncoderNameMap, nMappings, atts[1]);
- CHECK(codec != -1);
+ if (codec == -1) return nullptr;
MediaProfiles::AudioEncoderCap *cap =
new MediaProfiles::AudioEncoderCap(static_cast<audio_encoder>(codec), atoi(atts[5]),
@@ -340,11 +340,11 @@ MediaProfiles::createCamcorderProfile(int cameraId, const char **atts, Vector<in
const size_t nProfileMappings = sizeof(sCamcorderQualityNameMap)/
sizeof(sCamcorderQualityNameMap[0]);
const int quality = findTagForName(sCamcorderQualityNameMap, nProfileMappings, atts[1]);
- CHECK(quality != -1);
+ if (quality == -1) return nullptr;
const size_t nFormatMappings = sizeof(sFileFormatMap)/sizeof(sFileFormatMap[0]);
const int fileFormat = findTagForName(sFileFormatMap, nFormatMappings, atts[3]);
- CHECK(fileFormat != -1);
+ if (fileFormat == -1) return nullptr;
MediaProfiles::CamcorderProfile *profile = new MediaProfiles::CamcorderProfile;
profile->mCameraId = cameraId;
@@ -416,24 +416,38 @@ MediaProfiles::startElementHandler(void *userData, const char *name, const char
createAudioCodec(atts, profiles);
} else if (strcmp("VideoEncoderCap", name) == 0 &&
strcmp("true", atts[3]) == 0) {
- profiles->mVideoEncoders.add(createVideoEncoderCap(atts));
+ MediaProfiles::VideoEncoderCap* cap = createVideoEncoderCap(atts);
+ if (cap != nullptr) {
+ profiles->mVideoEncoders.add(cap);
+ }
} else if (strcmp("AudioEncoderCap", name) == 0 &&
strcmp("true", atts[3]) == 0) {
- profiles->mAudioEncoders.add(createAudioEncoderCap(atts));
+ MediaProfiles::AudioEncoderCap* cap = createAudioEncoderCap(atts);
+ if (cap != nullptr) {
+ profiles->mAudioEncoders.add(cap);
+ }
} else if (strcmp("VideoDecoderCap", name) == 0 &&
strcmp("true", atts[3]) == 0) {
- profiles->mVideoDecoders.add(createVideoDecoderCap(atts));
+ MediaProfiles::VideoDecoderCap* cap = createVideoDecoderCap(atts);
+ if (cap != nullptr) {
+ profiles->mVideoDecoders.add(cap);
+ }
} else if (strcmp("AudioDecoderCap", name) == 0 &&
strcmp("true", atts[3]) == 0) {
- profiles->mAudioDecoders.add(createAudioDecoderCap(atts));
+ MediaProfiles::AudioDecoderCap* cap = createAudioDecoderCap(atts);
+ if (cap != nullptr) {
+ profiles->mAudioDecoders.add(cap);
+ }
} else if (strcmp("EncoderOutputFileFormat", name) == 0) {
profiles->mEncoderOutputFileFormats.add(createEncoderOutputFileFormat(atts));
} else if (strcmp("CamcorderProfiles", name) == 0) {
profiles->mCurrentCameraId = getCameraId(atts);
profiles->addStartTimeOffset(profiles->mCurrentCameraId, atts);
} else if (strcmp("EncoderProfile", name) == 0) {
- profiles->mCamcorderProfiles.add(
- createCamcorderProfile(profiles->mCurrentCameraId, atts, profiles->mCameraIds));
+ MediaProfiles::CamcorderProfile* profile = createCamcorderProfile(profiles->mCurrentCameraId, atts, profiles->mCameraIds);
+ if (profile != nullptr) {
+ profiles->mCamcorderProfiles.add(profile);
+ }
} else if (strcmp("ImageEncoding", name) == 0) {
profiles->addImageEncodingQualityLevel(profiles->mCurrentCameraId, atts);
}
--
2.17.1

View File

@ -1,87 +0,0 @@
From cc25640b4712cd8eb8e98829bf523f2786fbb5ca Mon Sep 17 00:00:00 2001
From: Marcus Huang <marcus.huang@mediatek.com>
Date: Fri, 18 Oct 2019 15:51:35 +0800
Subject: [PATCH 20/21] Fix android.media.cts.ImageReaderDecoderTest fail on
MT6580 project
Root Cause:
Google C2 H264/H265 decoder request 64-aligned stride from graphic block; but ARM GPU would return
with 128-aligned stride when input height ONLY satisfies 2-aligned (e.g. 130).
Solution:
Revise stride alignment from 64 to 128 of C2 H264/H265 decoder
Bug: 142924202
Test: Build C2 Codec
Test:
run cts -m CtsMediaTestCases -t android.media.cts.ImageReaderDecoderTest#testGoogH264Image
run cts -m CtsMediaTestCases -t android.media.cts.ImageReaderDecoderTest#testGoogH264ImageReader
run cts -m CtsMediaTestCases -t android.media.cts.ImageReaderDecoderTest#testGoogH265Image
run cts -m CtsMediaTestCases -t android.media.cts.ImageReaderDecoderTest#testGoogH265ImageReader
Change-Id: I6eaff1b858e031b64744bc67d8aee5cc51cfd92d
(cherry picked from commit 28af1154b5f52c1f1a3687ff099ca609218bd78a)
---
media/codec2/components/avc/C2SoftAvcDec.cpp | 4 ++--
media/codec2/components/avc/C2SoftAvcDec.h | 1 +
media/codec2/components/hevc/C2SoftHevcDec.cpp | 4 ++--
media/codec2/components/hevc/C2SoftHevcDec.h | 1 +
4 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/media/codec2/components/avc/C2SoftAvcDec.cpp b/media/codec2/components/avc/C2SoftAvcDec.cpp
index fa98178187..75a612276d 100644
--- a/media/codec2/components/avc/C2SoftAvcDec.cpp
+++ b/media/codec2/components/avc/C2SoftAvcDec.cpp
@@ -755,8 +755,8 @@ c2_status_t C2SoftAvcDec::ensureDecoderState(const std::shared_ptr<C2BlockPool>
ALOGE("not supposed to be here, invalid decoder context");
return C2_CORRUPTED;
}
- if (mStride != ALIGN64(mWidth)) {
- mStride = ALIGN64(mWidth);
+ if (mStride != ALIGN128(mWidth)) {
+ mStride = ALIGN128(mWidth);
if (OK != setParams(mStride, IVD_DECODE_FRAME)) return C2_CORRUPTED;
}
if (mOutBlock &&
diff --git a/media/codec2/components/avc/C2SoftAvcDec.h b/media/codec2/components/avc/C2SoftAvcDec.h
index 4414a26c96..ed27493f32 100644
--- a/media/codec2/components/avc/C2SoftAvcDec.h
+++ b/media/codec2/components/avc/C2SoftAvcDec.h
@@ -40,6 +40,7 @@ namespace android {
#define ivdext_ctl_get_vui_params_ip_t ih264d_ctl_get_vui_params_ip_t
#define ivdext_ctl_get_vui_params_op_t ih264d_ctl_get_vui_params_op_t
#define ALIGN64(x) ((((x) + 63) >> 6) << 6)
+#define ALIGN128(x) ((((x) + 127) >> 7) << 7)
#define MAX_NUM_CORES 4
#define IVDEXT_CMD_CTL_SET_NUM_CORES \
(IVD_CONTROL_API_COMMAND_TYPE_T)IH264D_CMD_CTL_SET_NUM_CORES
diff --git a/media/codec2/components/hevc/C2SoftHevcDec.cpp b/media/codec2/components/hevc/C2SoftHevcDec.cpp
index df677c284e..389ea610dc 100644
--- a/media/codec2/components/hevc/C2SoftHevcDec.cpp
+++ b/media/codec2/components/hevc/C2SoftHevcDec.cpp
@@ -752,8 +752,8 @@ c2_status_t C2SoftHevcDec::ensureDecoderState(const std::shared_ptr<C2BlockPool>
ALOGE("not supposed to be here, invalid decoder context");
return C2_CORRUPTED;
}
- if (mStride != ALIGN64(mWidth)) {
- mStride = ALIGN64(mWidth);
+ if (mStride != ALIGN128(mWidth)) {
+ mStride = ALIGN128(mWidth);
if (OK != setParams(mStride, IVD_DECODE_FRAME)) return C2_CORRUPTED;
}
if (mOutBlock &&
diff --git a/media/codec2/components/hevc/C2SoftHevcDec.h b/media/codec2/components/hevc/C2SoftHevcDec.h
index ce63a6c4c3..aecd1011de 100644
--- a/media/codec2/components/hevc/C2SoftHevcDec.h
+++ b/media/codec2/components/hevc/C2SoftHevcDec.h
@@ -38,6 +38,7 @@ namespace android {
#define ivdext_ctl_get_vui_params_ip_t ihevcd_cxa_ctl_get_vui_params_ip_t
#define ivdext_ctl_get_vui_params_op_t ihevcd_cxa_ctl_get_vui_params_op_t
#define ALIGN64(x) ((((x) + 63) >> 6) << 6)
+#define ALIGN128(x) ((((x) + 127) >> 7) << 7)
#define MAX_NUM_CORES 4
#define IVDEXT_CMD_CTL_SET_NUM_CORES \
(IVD_CONTROL_API_COMMAND_TYPE_T)IHEVCD_CXA_CMD_CTL_SET_NUM_CORES
--
2.17.1

View File

@ -1,61 +0,0 @@
From 12e2bc3a80b81c0b399ec5d0c3b1ddead5085fef Mon Sep 17 00:00:00 2001
From: Wonsik Kim <wonsik@google.com>
Date: Fri, 10 Jan 2020 09:59:42 -0800
Subject: [PATCH 21/21] avc/hevc: Align 128 everywhere
Bug: 142924202
Test: media module tests
Change-Id: Icef9b6b19d11bbf1ce0a2078113bfcc0a9cdc3ad
(cherry picked from commit 48dfc8c137b161cfcf652947621439deed7d9252)
---
media/codec2/components/avc/C2SoftAvcDec.cpp | 4 ++--
media/codec2/components/hevc/C2SoftHevcDec.cpp | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/media/codec2/components/avc/C2SoftAvcDec.cpp b/media/codec2/components/avc/C2SoftAvcDec.cpp
index 75a612276d..2be51dd49e 100644
--- a/media/codec2/components/avc/C2SoftAvcDec.cpp
+++ b/media/codec2/components/avc/C2SoftAvcDec.cpp
@@ -500,7 +500,7 @@ void C2SoftAvcDec::getVersion() {
status_t C2SoftAvcDec::initDecoder() {
if (OK != createDecoder()) return UNKNOWN_ERROR;
mNumCores = MIN(getCpuCoreCount(), MAX_NUM_CORES);
- mStride = ALIGN64(mWidth);
+ mStride = ALIGN128(mWidth);
mSignalledError = false;
resetPlugin();
(void) setNumCores();
@@ -908,7 +908,7 @@ void C2SoftAvcDec::process(
if (0 < s_decode_op.u4_pic_wd && 0 < s_decode_op.u4_pic_ht) {
if (mHeaderDecoded == false) {
mHeaderDecoded = true;
- setParams(ALIGN64(s_decode_op.u4_pic_wd), IVD_DECODE_FRAME);
+ setParams(ALIGN128(s_decode_op.u4_pic_wd), IVD_DECODE_FRAME);
}
if (s_decode_op.u4_pic_wd != mWidth || s_decode_op.u4_pic_ht != mHeight) {
mWidth = s_decode_op.u4_pic_wd;
diff --git a/media/codec2/components/hevc/C2SoftHevcDec.cpp b/media/codec2/components/hevc/C2SoftHevcDec.cpp
index 389ea610dc..6db4387272 100644
--- a/media/codec2/components/hevc/C2SoftHevcDec.cpp
+++ b/media/codec2/components/hevc/C2SoftHevcDec.cpp
@@ -497,7 +497,7 @@ status_t C2SoftHevcDec::getVersion() {
status_t C2SoftHevcDec::initDecoder() {
if (OK != createDecoder()) return UNKNOWN_ERROR;
mNumCores = MIN(getCpuCoreCount(), MAX_NUM_CORES);
- mStride = ALIGN64(mWidth);
+ mStride = ALIGN128(mWidth);
mSignalledError = false;
resetPlugin();
(void) setNumCores();
@@ -904,7 +904,7 @@ void C2SoftHevcDec::process(
if (0 < s_decode_op.u4_pic_wd && 0 < s_decode_op.u4_pic_ht) {
if (mHeaderDecoded == false) {
mHeaderDecoded = true;
- setParams(ALIGN64(s_decode_op.u4_pic_wd), IVD_DECODE_FRAME);
+ setParams(ALIGN128(s_decode_op.u4_pic_wd), IVD_DECODE_FRAME);
}
if (s_decode_op.u4_pic_wd != mWidth || s_decode_op.u4_pic_ht != mHeight) {
mWidth = s_decode_op.u4_pic_wd;
--
2.17.1

View File

@ -1,90 +0,0 @@
From 50cc46681b211922da50a0d97624499f551642a1 Mon Sep 17 00:00:00 2001
From: Pierre-Hugues Husson <phh@phh.me>
Date: Wed, 18 Sep 2019 11:50:14 +0200
Subject: [PATCH 2/2] Mark mediacodec_2{6,7,8} as hal_omx_server
Change-Id: I03e763b8092a9089739db68ed17368ff574879bb
---
prebuilts/api/29.0/private/compat/26.0/26.0.cil | 1 +
prebuilts/api/29.0/private/compat/27.0/27.0.cil | 1 +
prebuilts/api/29.0/private/compat/28.0/28.0.cil | 1 +
private/compat/26.0/26.0.cil | 1 +
private/compat/27.0/27.0.cil | 1 +
private/compat/28.0/28.0.cil | 1 +
6 files changed, 6 insertions(+)
diff --git a/prebuilts/api/29.0/private/compat/26.0/26.0.cil b/prebuilts/api/29.0/private/compat/26.0/26.0.cil
index 3b3dae1c..60f42b9c 100644
--- a/prebuilts/api/29.0/private/compat/26.0/26.0.cil
+++ b/prebuilts/api/29.0/private/compat/26.0/26.0.cil
@@ -336,6 +336,7 @@
(typeattributeset mdnsd_socket_26_0 (mdnsd_socket))
(typeattributeset mdns_socket_26_0 (mdns_socket))
(typeattributeset mediacasserver_service_26_0 (mediacasserver_service))
+(typeattributeset hal_omx_server (mediacodec_26_0))
(typeattributeset mediacodec_26_0 (mediacodec))
(typeattributeset mediacodec_exec_26_0 (mediacodec_exec))
(typeattributeset mediacodec_service_26_0 (mediacodec_service))
diff --git a/prebuilts/api/29.0/private/compat/27.0/27.0.cil b/prebuilts/api/29.0/private/compat/27.0/27.0.cil
index 365d791a..8c8f82fc 100644
--- a/prebuilts/api/29.0/private/compat/27.0/27.0.cil
+++ b/prebuilts/api/29.0/private/compat/27.0/27.0.cil
@@ -1047,6 +1047,7 @@
(typeattributeset mdnsd_27_0 (mdnsd))
(typeattributeset mdnsd_socket_27_0 (mdnsd_socket))
(typeattributeset mdns_socket_27_0 (mdns_socket))
+(typeattributeset hal_omx_server (mediacodec_27_0))
(typeattributeset mediacodec_27_0 (mediacodec))
(typeattributeset mediacodec_exec_27_0 (mediacodec_exec))
(typeattributeset mediacodec_service_27_0 (mediacodec_service))
diff --git a/prebuilts/api/29.0/private/compat/28.0/28.0.cil b/prebuilts/api/29.0/private/compat/28.0/28.0.cil
index 305cb3ac..338cbd02 100644
--- a/prebuilts/api/29.0/private/compat/28.0/28.0.cil
+++ b/prebuilts/api/29.0/private/compat/28.0/28.0.cil
@@ -1242,6 +1242,7 @@
(typeattributeset mdnsd_28_0 (mdnsd))
(typeattributeset mdnsd_socket_28_0 (mdnsd_socket))
(typeattributeset mdns_socket_28_0 (mdns_socket))
+(typeattributeset hal_omx_server (mediacodec_28_0))
(typeattributeset mediacodec_28_0 (mediacodec))
(typeattributeset mediacodec_exec_28_0 (mediacodec_exec))
(typeattributeset mediacodec_service_28_0 (mediacodec_service))
diff --git a/private/compat/26.0/26.0.cil b/private/compat/26.0/26.0.cil
index 3b3dae1c..60f42b9c 100644
--- a/private/compat/26.0/26.0.cil
+++ b/private/compat/26.0/26.0.cil
@@ -336,6 +336,7 @@
(typeattributeset mdnsd_socket_26_0 (mdnsd_socket))
(typeattributeset mdns_socket_26_0 (mdns_socket))
(typeattributeset mediacasserver_service_26_0 (mediacasserver_service))
+(typeattributeset hal_omx_server (mediacodec_26_0))
(typeattributeset mediacodec_26_0 (mediacodec))
(typeattributeset mediacodec_exec_26_0 (mediacodec_exec))
(typeattributeset mediacodec_service_26_0 (mediacodec_service))
diff --git a/private/compat/27.0/27.0.cil b/private/compat/27.0/27.0.cil
index 365d791a..8c8f82fc 100644
--- a/private/compat/27.0/27.0.cil
+++ b/private/compat/27.0/27.0.cil
@@ -1047,6 +1047,7 @@
(typeattributeset mdnsd_27_0 (mdnsd))
(typeattributeset mdnsd_socket_27_0 (mdnsd_socket))
(typeattributeset mdns_socket_27_0 (mdns_socket))
+(typeattributeset hal_omx_server (mediacodec_27_0))
(typeattributeset mediacodec_27_0 (mediacodec))
(typeattributeset mediacodec_exec_27_0 (mediacodec_exec))
(typeattributeset mediacodec_service_27_0 (mediacodec_service))
diff --git a/private/compat/28.0/28.0.cil b/private/compat/28.0/28.0.cil
index 305cb3ac..338cbd02 100644
--- a/private/compat/28.0/28.0.cil
+++ b/private/compat/28.0/28.0.cil
@@ -1242,6 +1242,7 @@
(typeattributeset mdnsd_28_0 (mdnsd))
(typeattributeset mdnsd_socket_28_0 (mdnsd_socket))
(typeattributeset mdns_socket_28_0 (mdns_socket))
+(typeattributeset hal_omx_server (mediacodec_28_0))
(typeattributeset mediacodec_28_0 (mediacodec))
(typeattributeset mediacodec_exec_28_0 (mediacodec_exec))
(typeattributeset mediacodec_service_28_0 (mediacodec_service))
--
2.17.1