Commit eb17c590 authored by Hsiao Chien Sung's avatar Hsiao Chien Sung Committed by Chun-Kuang Hu
Browse files

drm/mediatek: Support "None" blending in Mixer

parent 1f66fe62
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -3,6 +3,7 @@
 * Copyright (c) 2021 MediaTek Inc.
 */

#include <drm/drm_blend.h>
#include <drm/drm_fourcc.h>
#include <drm/drm_framebuffer.h>
#include <linux/clk.h>
@@ -175,7 +176,8 @@ void mtk_ethdr_layer_config(struct device *dev, unsigned int idx,
		alpha_con |= state->base.alpha & MIXER_ALPHA;
	}

	if (state->base.fb && !state->base.fb->format->has_alpha) {
	if ((state->base.fb && !state->base.fb->format->has_alpha) ||
	    state->base.pixel_blend_mode == DRM_MODE_BLEND_PIXEL_NONE) {
		/*
		 * Mixer doesn't support CONST_BLD mode,
		 * use a trick to make the output equivalent