From patchwork Thu Apr 25 19:13:26 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sean Paul X-Patchwork-Id: 2489781 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by patchwork1.kernel.org (Postfix) with ESMTP id 376C03FD85 for ; Thu, 25 Apr 2013 19:13:48 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 335A2E66A4 for ; Thu, 25 Apr 2013 12:13:48 -0700 (PDT) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-qc0-f169.google.com (mail-qc0-f169.google.com [209.85.216.169]) by gabe.freedesktop.org (Postfix) with ESMTP id 7B24DE620B for ; Thu, 25 Apr 2013 12:13:37 -0700 (PDT) Received: by mail-qc0-f169.google.com with SMTP id t2so1740701qcq.28 for ; Thu, 25 Apr 2013 12:13:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=x-received:from:to:subject:date:message-id:x-mailer; bh=9xchmMplR9mGTk7n5KSXVbGy9FFC6R0T8KwX+MA+jj8=; b=jrL7mmLmW6rDR4nPLkQL9rmU7FiZO1bN1tyfEUz4r54ECVMfE5OaGhuDJUVfv9dW0U VOQcERQJyVSfI32/LptcMF6GKYL8AX4Z1JdMYVtQrCB6ThC8jvtRHPPzkVsB3uUm/aXi Oc5Vmhbe9U1tbrax/V0Y85dlEnON0ZWtjm2ug= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:from:to:subject:date:message-id:x-mailer :x-gm-message-state; bh=9xchmMplR9mGTk7n5KSXVbGy9FFC6R0T8KwX+MA+jj8=; b=m7oz6fgmAb39Agc6fGM9zfUe+yXgSSTpZaOPKRWnkQTooWCXTC2T47V9QWFSvMTjPr CYkVXCTaEuwYyG/fdmpgtqDVAEd7UCNSQtcCMLcQhuo75saVh7Mdjjb/TrZpEwE1po3u EkNotjeKOSK0FcY/7rQAvXhGR/J3Js3wewidZ/e78OvI2uwlEo7GFSF08j72iCzfchuD NR/H2812ck93TzUh8D/j4pn0Ha50o2txliHVoOeUB4tFbfi9uxvJC0U7rNVPeHCwRIvR CLtnGiiZBXg9Y9pApjVGZkz9q25T/jLe+X1JSYronUuJ46sKc7t37kK3PNVwwvtM7rvA XEmA== X-Received: by 10.229.128.30 with SMTP id i30mr4742028qcs.1.1366917216469; Thu, 25 Apr 2013 12:13:36 -0700 (PDT) Received: from seanpaul-glaptop.roam.corp.google.com (cpe-173-095-180-236.nc.res.rr.com. [173.95.180.236]) by mx.google.com with ESMTPSA id ed8sm11596635qeb.7.2013.04.25.12.13.34 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 25 Apr 2013 12:13:35 -0700 (PDT) From: Sean Paul To: seanpaul@chromium.org, inki.dae@samsung.com, dri-devel@lists.freedesktop.org Subject: [PATCH] drm/exynos: Don't blend mixer layer 0 Date: Thu, 25 Apr 2013 15:13:26 -0400 Message-Id: <1366917206-9780-1-git-send-email-seanpaul@chromium.org> X-Mailer: git-send-email 1.7.7.3 X-Gm-Message-State: ALoCoQn0BJyVQfB2G8Nh77d8u/f80Mj7PaMTF3dTdYW9rQxsvoe/q/9SCX+l+LP+q/iVqgmbUW3i X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org Errors-To: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org This patch disables blending the mixer's layer 0 onto the background (solid color). It doesn't make sense to blend this layer by default, and causes color distortion if the layer is used for arbitrary content. Signed-off-by: Sean Paul --- drivers/gpu/drm/exynos/exynos_mixer.c | 8 +++++--- 1 files changed, 5 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_mixer.c b/drivers/gpu/drm/exynos/exynos_mixer.c index f08e251..ec3e376 100644 --- a/drivers/gpu/drm/exynos/exynos_mixer.c +++ b/drivers/gpu/drm/exynos/exynos_mixer.c @@ -643,12 +643,14 @@ static void mixer_win_reset(struct mixer_context *ctx) /* setting graphical layers */ val = MXR_GRP_CFG_COLOR_KEY_DISABLE; /* no blank key */ val |= MXR_GRP_CFG_WIN_BLEND_EN; - val |= MXR_GRP_CFG_BLEND_PRE_MUL; - val |= MXR_GRP_CFG_PIXEL_BLEND_EN; val |= MXR_GRP_CFG_ALPHA_VAL(0xff); /* non-transparent alpha */ - /* the same configuration for both layers */ + /* Don't blend layer 0 onto the mixer background */ mixer_reg_write(res, MXR_GRAPHIC_CFG(0), val); + + /* Blend layer 1 into layer 0 */ + val |= MXR_GRP_CFG_BLEND_PRE_MUL; + val |= MXR_GRP_CFG_PIXEL_BLEND_EN; mixer_reg_write(res, MXR_GRAPHIC_CFG(1), val); /* setting video layers */