Skip to contentSkip to conversation

soc: mediatek: Disable 9-bit alpha in ETHDR

PATCH Applied Hsiao Chien Sung 2 participants 3 messages Jun 19, 2024 – Jun 25, 2024 Arm MediaTek

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 soc: mediatek: Disable 9-bit alpha in ETHDR

When 9-bit alpha is enabled, its value will be converted from 0-255 to 0-256 (255 = not defined). This is designed for special HDR related calculation, which should be disabled by default, otherwise, alpha blending will not work correctly.

---
 drivers/soc/mediatek/mtk-mmsys.c | 1 +
 1 file changed, 1 insertion(+)
drivers/soc/mediatek/mtk-mmsys.c +1 -0
index f370f4ec4b88..938240714e54 100644
@@ -236,6 +236,7 @@ void mtk_mmsys_mixer_in_config(struct device *dev, int idx, bool alpha_sel, u16
 
 	mtk_mmsys_update_bits(mmsys, MT8195_VDO1_MIXER_IN1_ALPHA + (idx - 1) * 4, ~0,
 			      alpha << 16 | alpha, cmdq_pkt);
+	mtk_mmsys_update_bits(mmsys, MT8195_VDO1_HDR_TOP_CFG, BIT(15 + idx), 0, cmdq_pkt);
 	mtk_mmsys_update_bits(mmsys, MT8195_VDO1_HDR_TOP_CFG, BIT(19 + idx),
 			      alpha_sel << (19 + idx), cmdq_pkt);
 	mtk_mmsys_update_bits(mmsys, MT8195_VDO1_MIXER_IN1_PAD + (idx - 1) * 4,

---
base-commit: 62fe4b067581d480e863191305f108bebffbc0e9
change-id: 20240619-9bit_alpha-39fbb99acc3b
prerequisite-change-id: 20240615-mediatek-drm-next-ad601b349f23:v3
prerequisite-patch-id: fdd0efbeca41c69c6fa93a5e49a2f16b3d2e8ef7
prerequisite-patch-id: 24bfda7b207bf9698ab88c7233d9168187aa54bb
prerequisite-patch-id: f2ab4804bbe54091a89b310c2ecd4b65fe031137
prerequisite-patch-id: 26bfe746bda376c070c23c72fcc25949e396d952
prerequisite-patch-id: b0b1589f88a9067b93a1e439e1db9abbde96e9e8
prerequisite-patch-id: 14603755fd2d5b6f0ef8a7843e118d0e8d27f57d
prerequisite-patch-id: 86f89ad0a06705cd2ad2867e9409da5610c9d228
prerequisite-patch-id: bd0b091709980bc6e993055d78573f3979139662
prerequisite-patch-id: 2f4da7b628f9d1f03e045b4c8f04b53eeb133a03
prerequisite-patch-id: 9ee1d1b3c69dc6ca828c21fae9180d2e9b5cd4d5
prerequisite-patch-id: 5c1f57bc1bd2d56061c2b927c9efbc9dad36ab68
prerequisite-patch-id: 05443d9f227599f0784da4006c4c983513654087
prerequisite-patch-id: 694abac72844a2b9753453aa514f9485a47a8f32
prerequisite-patch-id: 99f314c9dc697cb78c57d1311dfe055204b9e7b8

Best regards,

Signature · 1 line
Hsiao Chien Sung <[email protected]>
maintainer Applied
#1 lore raw
Quoted 6 lines · Hsiao Chien Sung

When 9-bit alpha is enabled, its value will be converted from 0-255 to 0-256 (255 = not defined). This is designed for special HDR related calculation, which should be disabled by default, otherwise, alpha blending will not work correctly.

Applied to v6.10-next/soc, thanks!

[1/1] soc: mediatek: Disable 9-bit alpha in ETHDR

      commit: eb36ad096818e11d54256570d7d49e26565daf5c

Cheers,
Angelo

#2 lore raw

Hi Angelo,

I see the patch has been merged.
Thank you for the notification.

Cheers,
Shawn

Quoted 18 lines · AngeloGioacchino Del Regno
Quoted 7 lines · Hsiao Chien Sung

When 9-bit alpha is enabled, its value will be converted from 0-255 to
0-256 (255 = not defined). This is designed for special HDR related calculation, which should be disabled by default, otherwise, alpha blending will not work correctly.

Applied to v6.10-next/soc, thanks!

[1/1] soc: mediatek: Disable 9-bit alpha in ETHDR

      commit: eb36ad096818e11d54256570d7d49e26565daf5c

Cheers,
Angelo