From patchwork Mon Oct 9 17:17:57 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 731073 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9847DCD6112 for ; Mon, 9 Oct 2023 17:18:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1377415AbjJIRSI (ORCPT ); Mon, 9 Oct 2023 13:18:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47108 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1377412AbjJIRSH (ORCPT ); Mon, 9 Oct 2023 13:18:07 -0400 Received: from mail-lj1-x22b.google.com (mail-lj1-x22b.google.com [IPv6:2a00:1450:4864:20::22b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9C7C59E for ; Mon, 9 Oct 2023 10:18:03 -0700 (PDT) Received: by mail-lj1-x22b.google.com with SMTP id 38308e7fff4ca-2c3c661f1a8so37540141fa.0 for ; Mon, 09 Oct 2023 10:18:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1696871882; x=1697476682; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=iqf751KKQfxwldVh3O4+QqYv6/dvoeaMh1iiCq2kv80=; b=bpwyuEUtwlxIsmn1sogDzsrAcYLDvNXm6ql98YYL0HiJmR3jvCOulef8LfHmy9Oxlq YosEPRCRPK9eLH3N2XjZuOSqSg8ODD40lAkkSTkjc0GhYPu9QCArHFYSSoExW95OjpCU cTxOwsDU7XscRCL4jmpCH/PtOXyeLdCK5gMQS0L7pE6S2LMejN/jQuXWghiviw7uL0pW HmupmjtZGXk8xLIv2UpIqho30n8B+yNmxk0n3l0LWG92rB8K0y/7hETL2X8E48rBz/Ec ZyTG3puAzkcYhHenXp8P8BoNwvlBmLozN1EuS+U4VFbG0lkRdtESKzhHW6AWjM4dursq HF6Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1696871882; x=1697476682; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=iqf751KKQfxwldVh3O4+QqYv6/dvoeaMh1iiCq2kv80=; b=rulUhuWb+0cqqisMeM8UcaoMZRLqSVwkazOY3LDazbIe/FGt/feISQZjb8xn/5agKc NSLS2XQs4awFDag+ZIgqfPSLF6sZHtdiQ1SPnPsO7BnR7BxM/EUaPPAUyMQoQ2d/cxrd OQtL2Yt4wSSq/0YU21cskL18K1OuzeSsvztOn8sMFQTK6WTwzZysf78kKg75FwPFhuJp e5v34FFFWUYdkFasqZ7SgWLAmS2udbGXC04VkanU2uRBxnpA1TXkWfD7HuAP8YqB3Z9F Kl+4adsFzk2OM0jnRxx25tLPSDwl3jOZUw52X2ZiNVaRRX0AJ8qpwzbl+C5XppdBZ8dz uw/A== X-Gm-Message-State: AOJu0Yw8hy7/EiZuPHb+AUUFzlZrLUZvuHPEtD52pptSFrgDNYeGzVaH chnKnJNW55owGDzhKDHl6s4fk7e8L31uTTzKoFWrrg== X-Google-Smtp-Source: AGHT+IEzTQpRmQ5AlYjb8eVMR+MpL/UW6yD7a6TxSauWCKs8l58SzgMyy/RyM9pU/T8I8AqqipGdOQ== X-Received: by 2002:a2e:8e98:0:b0:2bf:f32a:1f68 with SMTP id z24-20020a2e8e98000000b002bff32a1f68mr14690515ljk.19.1696871881909; Mon, 09 Oct 2023 10:18:01 -0700 (PDT) Received: from umbar.unikie.fi ([192.130.178.91]) by smtp.gmail.com with ESMTPSA id p18-20020a2e7412000000b002bcd2653872sm2088284ljc.30.2023.10.09.10.18.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 09 Oct 2023 10:18:01 -0700 (PDT) From: Dmitry Baryshkov To: Rob Clark , Sean Paul , Abhinav Kumar , Marijn Suijten Cc: Stephen Boyd , David Airlie , Daniel Vetter , Bjorn Andersson , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, freedreno@lists.freedesktop.org Subject: [RFT PATCH 1/4] drm/msm/dpu: enable writeback on SM8150 Date: Mon, 9 Oct 2023 20:17:57 +0300 Message-Id: <20231009171800.2691247-2-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231009171800.2691247-1-dmitry.baryshkov@linaro.org> References: <20231009171800.2691247-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Enable WB2 hardware block, enabling writeback support on this platform. Signed-off-by: Dmitry Baryshkov --- .../drm/msm/disp/dpu1/catalog/dpu_5_0_sm8150.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_0_sm8150.h b/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_0_sm8150.h index 99acaf917e43..b641e67f6afe 100644 --- a/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_0_sm8150.h +++ b/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_0_sm8150.h @@ -34,6 +34,7 @@ static const struct dpu_mdp_cfg sm8150_mdp = { [DPU_CLK_CTRL_DMA1] = { .reg_off = 0x2b4, .bit_off = 8 }, [DPU_CLK_CTRL_DMA2] = { .reg_off = 0x2bc, .bit_off = 8 }, [DPU_CLK_CTRL_DMA3] = { .reg_off = 0x2c4, .bit_off = 8 }, + [DPU_CLK_CTRL_WB2] = { .reg_off = 0x3b8, .bit_off = 24 }, }, }; @@ -297,6 +298,21 @@ static const struct dpu_dsc_cfg sm8150_dsc[] = { }, }; +static const struct dpu_wb_cfg sm8150_wb[] = { + { + .name = "wb_2", .id = WB_2, + .base = 0x65000, .len = 0x2c8, + .features = WB_SDM845_MASK, + .format_list = wb2_formats, + .num_formats = ARRAY_SIZE(wb2_formats), + .clk_ctrl = DPU_CLK_CTRL_WB2, + .xin_id = 6, + .vbif_idx = VBIF_RT, + .maxlinewidth = 4096, + .intr_wb_done = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 4), + }, +}; + static const struct dpu_intf_cfg sm8150_intf[] = { { .name = "intf_0", .id = INTF_0, @@ -393,6 +409,8 @@ const struct dpu_mdss_cfg dpu_sm8150_cfg = { .pingpong = sm8150_pp, .merge_3d_count = ARRAY_SIZE(sm8150_merge_3d), .merge_3d = sm8150_merge_3d, + .wb_count = ARRAY_SIZE(sm8150_wb), + .wb = sm8150_wb, .intf_count = ARRAY_SIZE(sm8150_intf), .intf = sm8150_intf, .vbif_count = ARRAY_SIZE(sdm845_vbif), From patchwork Mon Oct 9 17:17:58 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 732131 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6401BCD6113 for ; Mon, 9 Oct 2023 17:18:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1376935AbjJIRSH (ORCPT ); Mon, 9 Oct 2023 13:18:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49284 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1377403AbjJIRSG (ORCPT ); Mon, 9 Oct 2023 13:18:06 -0400 Received: from mail-lj1-x235.google.com (mail-lj1-x235.google.com [IPv6:2a00:1450:4864:20::235]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1C051CF for ; Mon, 9 Oct 2023 10:18:05 -0700 (PDT) Received: by mail-lj1-x235.google.com with SMTP id 38308e7fff4ca-2bff936e10fso69587401fa.1 for ; Mon, 09 Oct 2023 10:18:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1696871883; x=1697476683; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=oNuBdgTqnLvsaFXnef7V2YyQGajnGwk3qDz3SFukOEs=; b=N39+Zw6jTefNiwREjt6JbW4X3sycwahn5VFS884uz1VX1xQHa4O6gqqYjqGJ30ACHy ScgsRPv/0muv+JEMQQ9PYO7ROMKSxAeGllpCe0pyOjbapkPGonLe2nFcvYNt0PZngJu0 q+/5puBCnSxixvzKQztZujaf4yEeRi+GG8U5517iFQaSYVCQmT+Zyc3s2lIJAvdPDAnR rQtgCrN0dc/4ZU4NerQW5R0tkomRGO0wze8/xwX8me6hy3CWgtPWl72/XJowEmzQduAc I8mQ5PWg6TfRM85gP7kIAESxKvjM5WSLN5nL4Y1exfzCxUBgrU7dbtPHkzV+OPCHH0M+ 8qGw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1696871883; x=1697476683; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=oNuBdgTqnLvsaFXnef7V2YyQGajnGwk3qDz3SFukOEs=; b=Vm9iyc1VBvd4HlB1b8ArVub0VrMqOiUis6f/SW7VzmNanTb9HUC1T9sovQPsJZvwKn j4K82aZ7a8ZiYYTgLsRGly14Dr0+hJpPSR1YiZXQbJTCbbk4HkXxMvsZDSybJ8fFBomv thOZS+msTsySiNi83dwhfTgXYG2h34zEjNZk/kz+AD8FRjvYXTeH8K5FkAaz81Tse41i kUz2cM4D0CVBLzTVnYGcnV560p9ehY2uVD3E/sslT4y47g4waU1kKq/iRyEoOm0XMV4O lBhtyxoLoHHRGZtSlzn9Tvwi5TGef/btVnLDoTGg/QpL2KjNBE+lKSsZ/ah7VN7ibLF/ uu0g== X-Gm-Message-State: AOJu0Yyj6az0YItN5j7NydK2eV26nhhDQ2OQ7H8YzVWZOExGETLJ4XdJ XhdUj7b4KKrzXi/Ww2JXv2SOSA== X-Google-Smtp-Source: AGHT+IFqUXB62QSOWQHg8DjJu6B8zTraugdCMY3Fw7pHyqr58gvCtWcGEMFyMnrJ1920E4eblAq6CQ== X-Received: by 2002:a05:651c:1699:b0:2c1:6d1c:2cef with SMTP id bd25-20020a05651c169900b002c16d1c2cefmr10009637ljb.14.1696871882713; Mon, 09 Oct 2023 10:18:02 -0700 (PDT) Received: from umbar.unikie.fi ([192.130.178.91]) by smtp.gmail.com with ESMTPSA id p18-20020a2e7412000000b002bcd2653872sm2088284ljc.30.2023.10.09.10.18.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 09 Oct 2023 10:18:02 -0700 (PDT) From: Dmitry Baryshkov To: Rob Clark , Sean Paul , Abhinav Kumar , Marijn Suijten Cc: Stephen Boyd , David Airlie , Daniel Vetter , Bjorn Andersson , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, freedreno@lists.freedesktop.org Subject: [RFT PATCH 2/4] drm/msm/dpu: enable writeback on SC8108X Date: Mon, 9 Oct 2023 20:17:58 +0300 Message-Id: <20231009171800.2691247-3-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231009171800.2691247-1-dmitry.baryshkov@linaro.org> References: <20231009171800.2691247-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Enable WB2 hardware block, enabling writeback support on this platform. Signed-off-by: Dmitry Baryshkov --- .../msm/disp/dpu1/catalog/dpu_5_1_sc8180x.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_1_sc8180x.h b/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_1_sc8180x.h index f3de21025ca7..1631a121e471 100644 --- a/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_1_sc8180x.h +++ b/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_1_sc8180x.h @@ -34,6 +34,7 @@ static const struct dpu_mdp_cfg sc8180x_mdp = { [DPU_CLK_CTRL_DMA1] = { .reg_off = 0x2b4, .bit_off = 8 }, [DPU_CLK_CTRL_DMA2] = { .reg_off = 0x2bc, .bit_off = 8 }, [DPU_CLK_CTRL_DMA3] = { .reg_off = 0x2c4, .bit_off = 8 }, + [DPU_CLK_CTRL_WB2] = { .reg_off = 0x3b8, .bit_off = 24 }, }, }; @@ -304,6 +305,21 @@ static const struct dpu_dsc_cfg sc8180x_dsc[] = { }, }; +static const struct dpu_wb_cfg sc8180x_wb[] = { + { + .name = "wb_2", .id = WB_2, + .base = 0x65000, .len = 0x2c8, + .features = WB_SDM845_MASK, + .format_list = wb2_formats, + .num_formats = ARRAY_SIZE(wb2_formats), + .clk_ctrl = DPU_CLK_CTRL_WB2, + .xin_id = 6, + .vbif_idx = VBIF_RT, + .maxlinewidth = 4096, + .intr_wb_done = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 4), + }, +}; + static const struct dpu_intf_cfg sc8180x_intf[] = { { .name = "intf_0", .id = INTF_0, @@ -420,6 +436,8 @@ const struct dpu_mdss_cfg dpu_sc8180x_cfg = { .pingpong = sc8180x_pp, .merge_3d_count = ARRAY_SIZE(sc8180x_merge_3d), .merge_3d = sc8180x_merge_3d, + .wb_count = ARRAY_SIZE(sc8180x_wb), + .wb = sc8180x_wb, .intf_count = ARRAY_SIZE(sc8180x_intf), .intf = sc8180x_intf, .vbif_count = ARRAY_SIZE(sdm845_vbif), From patchwork Mon Oct 9 17:17:59 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 732130 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7E7C6CD6116 for ; Mon, 9 Oct 2023 17:18:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1377403AbjJIRSJ (ORCPT ); Mon, 9 Oct 2023 13:18:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47134 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1377410AbjJIRSH (ORCPT ); Mon, 9 Oct 2023 13:18:07 -0400 Received: from mail-lj1-x22e.google.com (mail-lj1-x22e.google.com [IPv6:2a00:1450:4864:20::22e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4C3F194 for ; Mon, 9 Oct 2023 10:18:05 -0700 (PDT) Received: by mail-lj1-x22e.google.com with SMTP id 38308e7fff4ca-2c1807f3400so58406561fa.1 for ; Mon, 09 Oct 2023 10:18:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1696871883; x=1697476683; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=D+M8hrUb+u/XzpJ6qoH9Pb/8miMIjbd1ZgpYuYEGZ78=; b=F1iaRuQLEhWHTvyZH/fD30yCM8rFxPbHcgqEVICRoSSD6UGfNYlDW5eBagCfYtekp9 +KcZd6tb+AQof3NHo5vRlumeuvTtNQ87ofBYE4RsmOIXpMHptQM3ceLjqXn1fXeuAPAA +pY053bgTi1wiSNzteIZeFUN3GlpgulHo2psZCd3Zvm6V+ljqadolx7mv+zvPZcyvCqQ JM9a21ggamHzWbXJgTSPVlGcA3tva4wIcXuJf5y48pAdcLSY2OtiCQIT2ndhp8DlGKIi HcyMQ+/ypvG8DgLn6NdcuWl7Y01L2vFm7WlWkr1wj7sr5b9RuN90BPZ9yGG704Ssu8Om KuAQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1696871883; x=1697476683; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=D+M8hrUb+u/XzpJ6qoH9Pb/8miMIjbd1ZgpYuYEGZ78=; b=qEJjQUs20dQXPI6YvsLOZIRw0OYyvkWkkVXV+ETRBYHtsM46z4YQVoqnNJD9I9rwW3 u48yjJrZkoaAoacSS/G4ed7gZFDNJaAmGVN15NECCpAK3B1EgVQinqFknSFaqaou92tw fBH2jrx+bTH0CP9H4KkX3YBWppK/UCQe+FuDAFNFwAhngoO/309NOdsK2/hdbzGXceOz hie2RB4bDcOj442qnHoDPAAYhYll2C5oeohpZo+1Xds7PFe/SF5hb+rLuUrLYi7YTyDu N2WD8dQADkBlndNl5x6rfx4hrr6xxMSQA8p5FqOrtu+1dVslrsZcUrh98Fx2P2UDauoG QZEg== X-Gm-Message-State: AOJu0YxU10uBj6+YCW1sNPKhpFhHcs5XWmNXLe1NDk4JjrcfY+n0iuWn 7nNRVNw+tOWzoY3fZnjoDiGxBQ== X-Google-Smtp-Source: AGHT+IH1NT1m/e250wIAJtsyFe63IKbaoF3hiLBrzHBN/C99UBBxtv+az0vLuWUjD65N5IK+mHt18Q== X-Received: by 2002:a2e:b4b3:0:b0:2c1:86da:3f61 with SMTP id q19-20020a2eb4b3000000b002c186da3f61mr9085547ljm.9.1696871883614; Mon, 09 Oct 2023 10:18:03 -0700 (PDT) Received: from umbar.unikie.fi ([192.130.178.91]) by smtp.gmail.com with ESMTPSA id p18-20020a2e7412000000b002bcd2653872sm2088284ljc.30.2023.10.09.10.18.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 09 Oct 2023 10:18:02 -0700 (PDT) From: Dmitry Baryshkov To: Rob Clark , Sean Paul , Abhinav Kumar , Marijn Suijten Cc: Stephen Boyd , David Airlie , Daniel Vetter , Bjorn Andersson , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, freedreno@lists.freedesktop.org Subject: [RFT PATCH 3/4] drm/msm/dpu: enable writeback on SM6125 Date: Mon, 9 Oct 2023 20:17:59 +0300 Message-Id: <20231009171800.2691247-4-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231009171800.2691247-1-dmitry.baryshkov@linaro.org> References: <20231009171800.2691247-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Enable WB2 hardware block, enabling writeback support on this platform. Signed-off-by: Dmitry Baryshkov --- .../drm/msm/disp/dpu1/catalog/dpu_5_4_sm6125.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_4_sm6125.h b/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_4_sm6125.h index 2491eed10039..c1b31a063a6f 100644 --- a/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_4_sm6125.h +++ b/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_5_4_sm6125.h @@ -27,6 +27,7 @@ static const struct dpu_mdp_cfg sm6125_mdp = { [DPU_CLK_CTRL_VIG0] = { .reg_off = 0x2ac, .bit_off = 0 }, [DPU_CLK_CTRL_DMA0] = { .reg_off = 0x2ac, .bit_off = 8 }, [DPU_CLK_CTRL_DMA1] = { .reg_off = 0x2b4, .bit_off = 8 }, + [DPU_CLK_CTRL_WB2] = { .reg_off = 0x3b8, .bit_off = 24 }, }, }; @@ -141,6 +142,21 @@ static const struct dpu_pingpong_cfg sm6125_pp[] = { }, }; +static const struct dpu_wb_cfg sm6125_wb[] = { + { + .name = "wb_2", .id = WB_2, + .base = 0x65000, .len = 0x2c8, + .features = WB_SDM845_MASK, + .format_list = wb2_formats, + .num_formats = ARRAY_SIZE(wb2_formats), + .clk_ctrl = DPU_CLK_CTRL_WB2, + .xin_id = 6, + .vbif_idx = VBIF_RT, + .maxlinewidth = 2160, + .intr_wb_done = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 4), + }, +}; + static const struct dpu_intf_cfg sm6125_intf[] = { { .name = "intf_0", .id = INTF_0, @@ -213,6 +229,8 @@ const struct dpu_mdss_cfg dpu_sm6125_cfg = { .dspp = sm6125_dspp, .pingpong_count = ARRAY_SIZE(sm6125_pp), .pingpong = sm6125_pp, + .wb_count = ARRAY_SIZE(sm6125_wb), + .wb = sm6125_wb, .intf_count = ARRAY_SIZE(sm6125_intf), .intf = sm6125_intf, .vbif_count = ARRAY_SIZE(sdm845_vbif), From patchwork Mon Oct 9 17:18:00 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Baryshkov X-Patchwork-Id: 731074 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id DA01DCD6115 for ; Mon, 9 Oct 2023 17:18:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1377414AbjJIRSI (ORCPT ); Mon, 9 Oct 2023 13:18:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47120 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1376797AbjJIRSH (ORCPT ); Mon, 9 Oct 2023 13:18:07 -0400 Received: from mail-lj1-x231.google.com (mail-lj1-x231.google.com [IPv6:2a00:1450:4864:20::231]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E3EA8B9 for ; Mon, 9 Oct 2023 10:18:05 -0700 (PDT) Received: by mail-lj1-x231.google.com with SMTP id 38308e7fff4ca-2c186ea81c7so60628001fa.1 for ; Mon, 09 Oct 2023 10:18:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1696871884; x=1697476684; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=CEblOIocXlow3cb9XQyMsSKR9zDBhqpUmKljUztzkSU=; b=g+su7kyhAUFKbA/K4+QgokTkuDJfn9el3AQ22PU48K+31qP85RHAC3lSqDuarTVoLc Q7VZAROETRfp8XdI/1bXFxwKyV6mcj57RuqzEXcP8M69NwgSwBNGhAl8azg/AlnIkZoY ZWT6BSxmc6DUSDdeTRb9KW4GyA24oHD4lrRrdXjMFqcb96X8fK5HvPM4zvSaoPdsSpwo 0+pNO45M5cJoo0OL3R/+CM4xf5+hLFDinRaurq9Wyf1KLLmzHbRQsrg3Q22Pt7SqEjQZ kcI8u/3mSYnWzIvbOnDe1sTvynC1CHbnXXRQGxRP38vY1coCPfzYtKesFFnJkweyQbgv YTEA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1696871884; x=1697476684; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=CEblOIocXlow3cb9XQyMsSKR9zDBhqpUmKljUztzkSU=; b=G8ax1X1JvwDJW0xMaZiTLdCXNdaiYxHpw3ibNCzajPJFMe35LrPE90e+jPyARbwXIm UNj7rtf0PL6zLwbz+l+ICjTRFHaSWxO2Z5oOS1B0jM9FI3h/IG4soRh0HblKc/s9r797 +OPR1uYZj7HabIzm0dQaBn7MBPxNyQIEp456afS6cX4tst1BJncLbGNcwyjrTxKVYedV GyJ1EnG2tJoExBmOehc6S1NfF9rbpg+N89sd+v67taxzMpM7NHtKccNr0imZutoJdl3+ siNEMU/XRPYqOEShNH5GC5sRcjR5cLULc7v+U95ShjD1mvMwBe0ddT0LdZWDNQDgsT/+ L55w== X-Gm-Message-State: AOJu0YwLKXlxaomjAfQ8H1X8sx7rAdfb6EIc42tkBV5ifV0DSMMXNoMz BsZ8173vQv067mw3IPxHcfGz1w== X-Google-Smtp-Source: AGHT+IG4RdCPzZlKt6l4Watu6D2W7vlq+2/tsr/8tE/NcaZWsglRlppVXo11VIt0pfqpBekhWpNfEA== X-Received: by 2002:a05:651c:87:b0:2c0:a2:77d7 with SMTP id 7-20020a05651c008700b002c000a277d7mr13038278ljq.24.1696871884288; Mon, 09 Oct 2023 10:18:04 -0700 (PDT) Received: from umbar.unikie.fi ([192.130.178.91]) by smtp.gmail.com with ESMTPSA id p18-20020a2e7412000000b002bcd2653872sm2088284ljc.30.2023.10.09.10.18.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 09 Oct 2023 10:18:03 -0700 (PDT) From: Dmitry Baryshkov To: Rob Clark , Sean Paul , Abhinav Kumar , Marijn Suijten Cc: Stephen Boyd , David Airlie , Daniel Vetter , Bjorn Andersson , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, freedreno@lists.freedesktop.org Subject: [RFT PATCH 4/4] drm/msm/dpu: enable writeback on SM6350 Date: Mon, 9 Oct 2023 20:18:00 +0300 Message-Id: <20231009171800.2691247-5-dmitry.baryshkov@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231009171800.2691247-1-dmitry.baryshkov@linaro.org> References: <20231009171800.2691247-1-dmitry.baryshkov@linaro.org> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org Enable WB2 hardware block, enabling writeback support on this platform. Signed-off-by: Dmitry Baryshkov --- .../drm/msm/disp/dpu1/catalog/dpu_6_4_sm6350.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_4_sm6350.h b/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_4_sm6350.h index cf5db6f296bd..206ee16acb86 100644 --- a/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_4_sm6350.h +++ b/drivers/gpu/drm/msm/disp/dpu1/catalog/dpu_6_4_sm6350.h @@ -27,6 +27,7 @@ static const struct dpu_mdp_cfg sm6350_mdp = { [DPU_CLK_CTRL_DMA0] = { .reg_off = 0x2ac, .bit_off = 8 }, [DPU_CLK_CTRL_DMA1] = { .reg_off = 0x2b4, .bit_off = 8 }, [DPU_CLK_CTRL_DMA2] = { .reg_off = 0x2c4, .bit_off = 8 }, + [DPU_CLK_CTRL_WB2] = { .reg_off = 0x3b8, .bit_off = 24 }, [DPU_CLK_CTRL_REG_DMA] = { .reg_off = 0x2bc, .bit_off = 20 }, }, }; @@ -148,6 +149,21 @@ static const struct dpu_dsc_cfg sm6350_dsc[] = { }, }; +static const struct dpu_wb_cfg sm6350_wb[] = { + { + .name = "wb_2", .id = WB_2, + .base = 0x65000, .len = 0x2c8, + .features = WB_SM8250_MASK, + .format_list = wb2_formats, + .num_formats = ARRAY_SIZE(wb2_formats), + .clk_ctrl = DPU_CLK_CTRL_WB2, + .xin_id = 6, + .vbif_idx = VBIF_RT, + .maxlinewidth = 1920, + .intr_wb_done = DPU_IRQ_IDX(MDP_SSPP_TOP0_INTR, 4), + }, +}; + static const struct dpu_intf_cfg sm6350_intf[] = { { .name = "intf_0", .id = INTF_0, @@ -222,6 +238,8 @@ const struct dpu_mdss_cfg dpu_sm6350_cfg = { .dsc = sm6350_dsc, .pingpong_count = ARRAY_SIZE(sm6350_pp), .pingpong = sm6350_pp, + .wb_count = ARRAY_SIZE(sm6350_wb), + .wb = sm6350_wb, .intf_count = ARRAY_SIZE(sm6350_intf), .intf = sm6350_intf, .vbif_count = ARRAY_SIZE(sdm845_vbif),