Revert "cros_gralloc: map custom drm fourcc back to standard fourcc"
This reverts commit 64d22e93619230d334475b7cf1555e6204663f5e.
The underlying change is being reverted and then will be re-added
via a fresh merge from upstream in order to sync internal and aosp
branches.
Bug: b/161909468
Test: launch_cvd
Change-Id: Icf785d33d4b219a1ac95b37bb03f23541347e446
diff --git a/cros_gralloc/gralloc4/CrosGralloc4Mapper.cc b/cros_gralloc/gralloc4/CrosGralloc4Mapper.cc
index 2a3f4c0..47e24ac 100644
--- a/cros_gralloc/gralloc4/CrosGralloc4Mapper.cc
+++ b/cros_gralloc/gralloc4/CrosGralloc4Mapper.cc
@@ -467,12 +467,7 @@
PixelFormat pixelFormat = static_cast<PixelFormat>(crosHandle->droid_format);
status = android::gralloc4::encodePixelFormatRequested(pixelFormat, &encodedMetadata);
} else if (metadataType == android::gralloc4::MetadataType_PixelFormatFourCC) {
- uint32_t format = crosHandle->format;
- // Map internal fourcc codes back to standard fourcc codes.
- if (format == DRM_FORMAT_YVU420_ANDROID) {
- format = DRM_FORMAT_YVU420;
- }
- status = android::gralloc4::encodePixelFormatFourCC(format, &encodedMetadata);
+ status = android::gralloc4::encodePixelFormatFourCC(crosHandle->format, &encodedMetadata);
} else if (metadataType == android::gralloc4::MetadataType_PixelFormatModifier) {
status = android::gralloc4::encodePixelFormatModifier(crosHandle->format_modifier,
&encodedMetadata);