From patchwork Tue Mar 14 12:13:43 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 69594 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp1729446wrd; Tue, 14 Mar 2023 05:34:30 -0700 (PDT) X-Google-Smtp-Source: AK7set+o0yNZ93QtVTICrLAekoQorbXuQQr0T2f1ChwCOPn/tzHXm2m5WY4LyQIzMv7SSX1JvAjK X-Received: by 2002:a05:6a20:2a22:b0:d3:eab3:bc0e with SMTP id e34-20020a056a202a2200b000d3eab3bc0emr7363815pzh.25.1678797269813; Tue, 14 Mar 2023 05:34:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1678797269; cv=none; d=google.com; s=arc-20160816; b=0czmLhA2v27AFc0onDVQ6MZIX/llqNnmaArgsy4wIl+qPh/uvfgdqBAjSTcPHsuSBJ QqTIZto2vpLVRQc6ZQFfgiPzwDYHEhkPj0VV+HbtcgPRMcqVwnSbT96Ocm8WL32Fc/eE 4Ehd50IBPtQh3G/mpGWN3ngTeoRF8PENwp/we4c2ll8SMMS+pDs3GdyTgS+IFeLqeEfo l+d9L0Ap2r1R/XQPWkjtO6CSEFxEm21F8694ijHCR77NGNtW9wH0FyUrlXIvU+crrTX+ wR6tshVsHGa087eytlh7YVrC/gfU7C0nBpI4cutRyoUI6Vru5+lT0I3ii63twG+VLUb9 MhMw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=FyfU1KJpQXcUs5jhogFBaoFTlgPH63DY/U4xjNHTWjQ=; b=EHddzRZMu4VjWfecKQuH2HmJYaVx+/Tic5ryJt3c2m1hhOAt/QcNYK7V6qWkrpAnjT 71lorgbvfz0We8Ze7pX2vEJbaYJVeNzlYJDj+7U4tFYXOrQbvTauK29fyF11cftnEEGo nNZQ9NpX666EarSI/HkfOL6kodgLWIqCRSmGa7rr8sgGpVuzXqJXqKzORp91+qfEO8FF g2m04fIPRzKjhlQDF/jiDjy+cMfCbs614knAPRMxQhBzk4JglG6bua7OwqsSXmC0ekKS LgUDewbelNEhFwYp7Jnx1RzQ5yq1tOVd3ZV9reJxCZuTKFlOwL49BnwbAsWFtY4LVgsW g3FQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=pdn4SeDI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u190-20020a6385c7000000b0050abbe0e256si2064078pgd.842.2023.03.14.05.34.16; Tue, 14 Mar 2023 05:34:29 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=pdn4SeDI; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232021AbjCNMSv (ORCPT + 99 others); Tue, 14 Mar 2023 08:18:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57072 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232025AbjCNMQf (ORCPT ); Tue, 14 Mar 2023 08:16:35 -0400 Received: from mail-lf1-x132.google.com (mail-lf1-x132.google.com [IPv6:2a00:1450:4864:20::132]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 940D69545C for ; Tue, 14 Mar 2023 05:14:52 -0700 (PDT) Received: by mail-lf1-x132.google.com with SMTP id d36so19719143lfv.8 for ; Tue, 14 Mar 2023 05:14:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1678796056; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=FyfU1KJpQXcUs5jhogFBaoFTlgPH63DY/U4xjNHTWjQ=; b=pdn4SeDIFby6ImJU/zRU79g8OAJJqEZxUN3MkvHIVGImPYJ9wsKs3u9VMOaAr9qV77 +3P8JP2YgAUlgtKjCXpDOm6T9MNdJx1YGj8cCwvt0m9asErPxg6UtELTb5vkpj6+qpd7 OVUxDCKwtJf9MECXA+H1fkwo0y57I4m1/MCqe0kcaubQmmRydS0lkEDHh+YMtoTSq0HZ K7RtVe9maQc6YVfZ7MmrryNyQGIzhVO09QtpBq8OZb4HJfi4ZaLdX3E+jgZQnkV/6Q3e LMig87LVRaU7LLAPeyNFFPEUJDRKXLv6mPuJjgNb8xyMLYkaLCsb2eb0OH9Yk42X7frJ fnFw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678796056; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=FyfU1KJpQXcUs5jhogFBaoFTlgPH63DY/U4xjNHTWjQ=; b=KjOr2oFksMRrHXqFQZKeFREfGXAAmNubschxCiSEkZpmH5KdG9g08Fa+23K/3z3aYY vs8EXFVf6EPJh80wxYbKRgdbZLmZ5YpAaU2FY/RZERXVjEp7UPUQlafl/IJWKF/r5h5D asgVB1JBEP2xxPhunnPWoPekT/jz/4mNZNyt/52Nih2g12arrkgsqiLlcptoGFAcylV1 Pv3tdo/Ep6b72NGS4a0MM4qo09GAv9gBT3yDKLvpKU3R29N784k/yOWmhT61PJY9oT8I d2/iLG7Rh6JdSBdOeAZLrOflcvKc9yUkONyOu+pQ0iT0x3yxNCKj2JQZPbr/X2L/beu5 Ibeg== X-Gm-Message-State: AO0yUKUCFg/g5g6yl9FJnydxoCTnKgivPYTKwyiQw5ZMzF6d1nKIj4uz ag4pQEfwEA8xWAs3cCUI4u4rvQ== X-Received: by 2002:a05:6512:11e1:b0:4db:2cdf:4c12 with SMTP id p1-20020a05651211e100b004db2cdf4c12mr574193lfs.43.1678796056346; Tue, 14 Mar 2023 05:14:16 -0700 (PDT) Received: from [192.168.1.101] (abyj16.neoplus.adsl.tpnet.pl. [83.9.29.16]) by smtp.gmail.com with ESMTPSA id s4-20020a19ad44000000b004dda87ecae3sm379058lfd.246.2023.03.14.05.14.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 14 Mar 2023 05:14:15 -0700 (PDT) From: Konrad Dybcio Date: Tue, 14 Mar 2023 13:13:43 +0100 Subject: [PATCH v4 05/10] drm/msm/dsi: dsi_cfg: Merge SC7180 config into SDM845 MIME-Version: 1.0 Message-Id: <20230307-topic-dsi_qcm-v4-5-54b4898189cb@linaro.org> References: <20230307-topic-dsi_qcm-v4-0-54b4898189cb@linaro.org> In-Reply-To: <20230307-topic-dsi_qcm-v4-0-54b4898189cb@linaro.org> To: Rob Clark , Abhinav Kumar , Dmitry Baryshkov , Sean Paul , David Airlie , Daniel Vetter , Rob Herring , Krzysztof Kozlowski , Krishna Manikandan , Bryan O'Donoghue , Andy Gross , Bjorn Andersson Cc: Rob Herring , linux-arm-msm@vger.kernel.org, dri-devel@lists.freedesktop.org, freedreno@lists.freedesktop.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Marijn Suijten , Konrad Dybcio X-Mailer: b4 0.12.1 X-Developer-Signature: v=1; a=ed25519-sha256; t=1678796043; l=2206; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=+ePdH/Gl1hrkxIW7hm63Vg7SPtBJUhhLLi5EVaR0ltI=; b=6qaalpt6trqBL9lpfNbfElg+UaFZCgOIrVJIg4XC74C8ALx5+2CrAwZmGw17FlnbZ0bAMRADXbBA 9frNKRM/BXGnZlhK5OrA/+mUVrGsmf8FXYy0AFBZ1RPeaHMrREgz X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-Spam-Status: No, score=-0.2 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_SORBS_HTTP,RCVD_IN_SORBS_SOCKS,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1760346525718620535?= X-GMAIL-MSGID: =?utf-8?q?1760346525718620535?= The configs are identical, other than the number of *maximum* DSI hosts allowed. This isn't an issue, unless somebody deliberately tries to access the inexistent host by adding a dt node for it. Remove the SC7180 struct and point the hw revision match to the SDM845's one. On a note, this could have been done back when 7180 support was introduced. Reviewed-by: Dmitry Baryshkov Reviewed-by: Marijn Suijten Signed-off-by: Konrad Dybcio --- drivers/gpu/drm/msm/dsi/dsi_cfg.c | 15 ++------------- 1 file changed, 2 insertions(+), 13 deletions(-) diff --git a/drivers/gpu/drm/msm/dsi/dsi_cfg.c b/drivers/gpu/drm/msm/dsi/dsi_cfg.c index 039f503233d7..03d98cbcc978 100644 --- a/drivers/gpu/drm/msm/dsi/dsi_cfg.c +++ b/drivers/gpu/drm/msm/dsi/dsi_cfg.c @@ -169,7 +169,7 @@ static const struct msm_dsi_config sdm845_dsi_cfg = { .bus_clk_names = dsi_v2_4_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_v2_4_clk_names), .io_start = { - { 0xae94000, 0xae96000 }, + { 0xae94000, 0xae96000 }, /* SDM845 / SDM670 / SC7180 */ }, }; @@ -188,17 +188,6 @@ static const struct msm_dsi_config sm8550_dsi_cfg = { }, }; -static const struct msm_dsi_config sc7180_dsi_cfg = { - .io_offset = DSI_6G_REG_SHIFT, - .regulator_data = dsi_v2_4_regulators, - .num_regulators = ARRAY_SIZE(dsi_v2_4_regulators), - .bus_clk_names = dsi_v2_4_clk_names, - .num_bus_clks = ARRAY_SIZE(dsi_v2_4_clk_names), - .io_start = { - { 0xae94000 }, - }, -}; - static const struct regulator_bulk_data sc7280_dsi_regulators[] = { { .supply = "vdda", .init_load_uA = 8350 }, /* 1.2 V */ }; @@ -291,7 +280,7 @@ static const struct msm_dsi_cfg_handler dsi_cfg_handlers[] = { {MSM_DSI_VER_MAJOR_6G, MSM_DSI_6G_VER_MINOR_V2_4_0, &sdm845_dsi_cfg, &msm_dsi_6g_v2_host_ops}, {MSM_DSI_VER_MAJOR_6G, MSM_DSI_6G_VER_MINOR_V2_4_1, - &sc7180_dsi_cfg, &msm_dsi_6g_v2_host_ops}, + &sdm845_dsi_cfg, &msm_dsi_6g_v2_host_ops}, {MSM_DSI_VER_MAJOR_6G, MSM_DSI_6G_VER_MINOR_V2_5_0, &sc7280_dsi_cfg, &msm_dsi_6g_v2_host_ops}, {MSM_DSI_VER_MAJOR_6G, MSM_DSI_6G_VER_MINOR_V2_6_0,