From patchwork Wed Mar 24 15:00:13 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 12161387 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.6 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6D90BC433DB for ; Wed, 24 Mar 2021 15:01:20 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 2A4CA61A0D for ; Wed, 24 Mar 2021 15:01:20 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 2A4CA61A0D Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 6C2816EC4F; Wed, 24 Mar 2021 15:01:17 +0000 (UTC) Received: from mail-lf1-x136.google.com (mail-lf1-x136.google.com [IPv6:2a00:1450:4864:20::136]) by gabe.freedesktop.org (Postfix) with ESMTPS id 6E0F16EC5C for ; Wed, 24 Mar 2021 15:00:44 +0000 (UTC) Received: by mail-lf1-x136.google.com with SMTP id w37so32407072lfu.13 for ; Wed, 24 Mar 2021 08:00:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=zOtkoDiOO2j7crcK/NDW0zJrKE6imOch+G2dYhHVZU4=; b=rXGFoie/9yS3qzs+rJXWTT05Cj9L593a8CPJ8P7JADitduceizCaquXGeJ2dT2THGG l7ptbGmn9xeu5hmaAEvpiQO9qT+FwE/ECaqg3OIbG41DiXySO6h8W9f7aEUI27jVjJPu 1ukn0MVHTlA39wHdC5r1iZPoOZ7gH06iUJRmBpBo9FqpvcudlfkwSNG3b2s+dNavzusX C58AlG06fKU95nLI0ivQwVshnxAxnyUoMg0h6dB+iDj43ZfRK5U3yrpxu5YV0bD5DoFO IExmy9X44z2IW5JhIHpUkXvTVU5ctQYX5CByMy7TzeNohgYjszcY+BuUS5LCblS1gocg T9VQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=zOtkoDiOO2j7crcK/NDW0zJrKE6imOch+G2dYhHVZU4=; b=jeHcPz/1iJBdFFEMLXkLW5ywVGDssQAsRLPol8biMAUjRdZi+7KTK8hwBJJ69qHVVH XjqOlaTElP2Ff8rmcuUOAJXExbUsXYG75ETzVjFWZ6NNhJ27hf5OE8SrQ9X05ajB/vJS /z7Evz1wCUmjRWOGLEUW9foWlTQjGTUHLGFjltoHvPVKY4XW1maBoDv8VwKZ+TZw/uu8 r/sXkJDdBE9CD42UqqRABhV+DCuC275CHVuBjqFzZJYv2xqs7e9g+dFd+Hrb+w6u+ojE +CIxtxQAqC3iF4E8e1e3AuhH1exIeVK9xhcRXAig9greWsALCQCGBJjrwwsE05VIoPg3 wouw== X-Gm-Message-State: AOAM533KyDpN4crXLUk6GNJCT/d8itEB4M2bPK8w8F+M5aHgWjuSvyGO 92b5t4EiSEOfwwBv6adyLhHWPQ== X-Google-Smtp-Source: ABdhPJwfDblbnU+Z1/65/qUpz0vpTBhQEknwMYuUiS0xokuJL1eIt7NEi2fvByDJR8ileYBvUKnNKg== X-Received: by 2002:a19:353:: with SMTP id 80mr2095095lfd.97.1616598042791; Wed, 24 Mar 2021 08:00:42 -0700 (PDT) Received: from eriador.lan ([37.153.55.125]) by smtp.gmail.com with ESMTPSA id p5sm252463lfe.154.2021.03.24.08.00.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 24 Mar 2021 08:00:42 -0700 (PDT) From: Dmitry Baryshkov To: Rob Clark , Sean Paul , Jonathan Marek Subject: [PATCH 10/21] drm/msm/dpu: drop dpu_hw_lm_setup_blend_config() Date: Wed, 24 Mar 2021 18:00:13 +0300 Message-Id: <20210324150024.2768215-11-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210324150024.2768215-1-dmitry.baryshkov@linaro.org> References: <20210324150024.2768215-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Stephen Boyd , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, David Airlie , freedreno@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" DPU1 driver supports only hardware with the version of 4.0 and higher (>= sdm845), so drop the dpu_hw_lm_setup_blend_config() used by previous hardware generations. Signed-off-by: Dmitry Baryshkov --- drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.c | 26 +---------------------- 1 file changed, 1 insertion(+), 25 deletions(-) diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.c index fd09b9ab9b4b..7d5b620f7f42 100644 --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.c +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_lm.c @@ -23,9 +23,6 @@ #define LM_FG_COLOR_FILL_SIZE 0x10 #define LM_FG_COLOR_FILL_XY 0x14 -#define LM_BLEND0_FG_ALPHA 0x04 -#define LM_BLEND0_BG_ALPHA 0x08 - static const struct dpu_lm_cfg *_lm_offset(enum dpu_lm mixer, const struct dpu_mdss_cfg *m, void __iomem *addr, @@ -117,24 +114,6 @@ static void dpu_hw_lm_setup_blend_config_sdm845(struct dpu_hw_mixer *ctx, DPU_REG_WRITE(c, LM_BLEND0_OP + stage_off, blend_op); } -static void dpu_hw_lm_setup_blend_config(struct dpu_hw_mixer *ctx, - u32 stage, u32 fg_alpha, u32 bg_alpha, u32 blend_op) -{ - struct dpu_hw_blk_reg_map *c = &ctx->hw; - int stage_off; - - if (stage == DPU_STAGE_BASE) - return; - - stage_off = _stage_offset(ctx, stage); - if (WARN_ON(stage_off < 0)) - return; - - DPU_REG_WRITE(c, LM_BLEND0_FG_ALPHA + stage_off, fg_alpha); - DPU_REG_WRITE(c, LM_BLEND0_BG_ALPHA + stage_off, bg_alpha); - DPU_REG_WRITE(c, LM_BLEND0_OP + stage_off, blend_op); -} - static void dpu_hw_lm_setup_color3(struct dpu_hw_mixer *ctx, uint32_t mixer_op_mode) { @@ -154,10 +133,7 @@ static void _setup_mixer_ops(const struct dpu_mdss_cfg *m, unsigned long features) { ops->setup_mixer_out = dpu_hw_lm_setup_out; - if (m->hwversion >= DPU_HW_VER_400) - ops->setup_blend_config = dpu_hw_lm_setup_blend_config_sdm845; - else - ops->setup_blend_config = dpu_hw_lm_setup_blend_config; + ops->setup_blend_config = dpu_hw_lm_setup_blend_config_sdm845; ops->setup_alpha_out = dpu_hw_lm_setup_color3; ops->setup_border_color = dpu_hw_lm_setup_border_color; }