Merge "h265: CB2 change 265 HDR signal type. [1/1]" into android-tv-deadpool-4.9-android12
diff --git a/drivers/frame_provider/decoder/h265/vh265.c b/drivers/frame_provider/decoder/h265/vh265.c
index 9369556..516d74a 100644
--- a/drivers/frame_provider/decoder/h265/vh265.c
+++ b/drivers/frame_provider/decoder/h265/vh265.c
@@ -8513,6 +8513,13 @@
}
if (hevc->video_signal_type & VIDEO_SIGNAL_TYPE_AVAILABLE_MASK) {
vf->signal_type = pic->video_signal_type;
+ /* When the matrix_coeffiecents, transfer_characteristics and colour_primaries
+ * syntax elements are absent, their values shall be presumed to be equal to 2
+ */
+ if ((vf->signal_type & 0x1000000) == 0) {
+ vf->signal_type = vf->signal_type & 0xff000000;
+ vf->signal_type = vf->signal_type | 0x20202;
+ }
if (hevc->sei_present_flag & SEI_HDR10PLUS_MASK) {
u32 data;
data = vf->signal_type;