From patchwork Sat Mar 18 13:42:47 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 71594 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:604a:0:0:0:0:0 with SMTP id j10csp295635wrt; Sat, 18 Mar 2023 06:43:57 -0700 (PDT) X-Google-Smtp-Source: AK7set98eTRpu1L9lpwLhvfrxXqVoWPkIxcVLN0+K6xJyz2rdtO50OU68R8+/Y/fVztU6FohAtLP X-Received: by 2002:a17:903:188:b0:19d:323:e68 with SMTP id z8-20020a170903018800b0019d03230e68mr10500062plg.1.1679147036904; Sat, 18 Mar 2023 06:43:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679147036; cv=none; d=google.com; s=arc-20160816; b=b0Yp4b+jrXxsynBNp2xujCJ/7YCG85zLwfym/fhLYfG41QEFj/VLSTIKcQwXJuAX6F RIJ4tnZtu8YCouooWcdtgcWC3pURlJY26/PbsTMzYDq6Voj15fV29TpV5su8c6nD4L4R cy8EYMXS5sEj+cKq1o+mnGebbBboVWlRgFvw3rkm5a7kR31POIxlGzYQbrroxxSm3djj 0phTAr/zuFFHr1XWQ1ptc/5TsZUfF7oHsy6I4qICG+qu1AaaPuLWtBr0lPqmwSOamUqb a08nG7yCknlyFgw/D73t+kgFdYMufbj2OT68sJpbQYWdWeCxMOnQYiUGLsmrKwHrRbRV MdPg== 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=gR7d4RO2oXpB/c3r0bQ4Ajknjymjb6WOVIZPuCDVi/s=; b=RXB1/Oub1CWI7pI4G/H7IysIv92KQYmt4eraut0QqF3+/HB4Lz6giSIXtymoghF4P7 k6MmSXKEQXfxRzOUnDFklLextbn2/Eleh0aiBjvHU36Ltikc64i/Wy4vnb3HGhGGoeRT U2KIFaOwHHPzrOJhyW2FHSJIjIE0bHFHf2CXlS5+8H6lOAV99IRmmbI5N+6DeSCzS4qU gGSa3KLb5h1wfqmeL8PqxFLjkIfjb0nOGhIagSufaoOohvoQbhO4OtCzLjqHZCDrmruE q8jLd5rWMdrgXHA/Lzd63KLn6Mu4b4X0eEGwODNkQytQwnw+rozKWEP/Pvjs66MXLgoy e55g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=H+KKwkXj; 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 kw13-20020a170902f90d00b0019a7375dfcasi5153017plb.247.2023.03.18.06.43.42; Sat, 18 Mar 2023 06:43:56 -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=H+KKwkXj; 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 S229784AbjCRNnA (ORCPT + 99 others); Sat, 18 Mar 2023 09:43:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34324 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229769AbjCRNm6 (ORCPT ); Sat, 18 Mar 2023 09:42:58 -0400 Received: from mail-lj1-x232.google.com (mail-lj1-x232.google.com [IPv6:2a00:1450:4864:20::232]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6675427D64 for ; Sat, 18 Mar 2023 06:42:56 -0700 (PDT) Received: by mail-lj1-x232.google.com with SMTP id x36so7789580ljq.7 for ; Sat, 18 Mar 2023 06:42:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1679146974; 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=gR7d4RO2oXpB/c3r0bQ4Ajknjymjb6WOVIZPuCDVi/s=; b=H+KKwkXjEOO0xzTuKFQmmnSBPzTcBRlFbmOuHHf0Uf1URi+8D0dsxGBIdjFfhSufft DrJpuK0pjFw5vgPotYM8FgqBQan/tczhlitMFlsrMRdr6y1YoAiafr7ZNKsSQhjxcP9i QdGlVVNlQVzg2orND8EdgzhC7jo6B2q11qv2GhzXuxoRIPLQsqaKpQR8yYmitCbxFlf6 8ePht5xEcqLrc9tJ/+GOPrYedYc/80thHuI+k1zq2FBRjOTtam2lDB+hz6s/gbG+/4vc nKCUA3ZMHKf8TG1JhXh7229zquYFFboM05CWaQpMqtUQQcK0bYW25K/WR2h7EV2y+JD6 bT+g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679146974; 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=gR7d4RO2oXpB/c3r0bQ4Ajknjymjb6WOVIZPuCDVi/s=; b=nFoa0pN6C+eo66Pk9EwmvkbEAqTgu88d59WORgPV4fNp7TXonNfYvb/Wo355aP00IC zuSyon7+2nRBnHpLgzVRCdG6GDUKvBrD5VKjGCr4Zvf3jC0ClOq8wmfq9N7gDlLBSyMv n30u5K/MVNKyaMUs/S+OCnsJNbO+NQqyH0D9AkfxczM7YA5RPifPKPeRY5sIVR+juSuM CJ84g7JKYsjVadWd8GDxrFO241kQvrxfe7I8kWyysaK1PcXHJsq7cUrobU4QFJY7cUv1 oe8k5F+/kTpVUJoFJvD37iNmYXPnFTq3FtLg5d2cB6av4I6+8tcKxxB+E0B6yRyLjjth kY4w== X-Gm-Message-State: AO0yUKUg1Rw6YqFR9Yec8ec8iWu508u+tRocG0eOYGmRSgjdUb4mQDLI uv0aOyQQOnSL1as5t8Cu5gPAfgW7J6222uHoTFc= X-Received: by 2002:a05:651c:391:b0:298:9db0:a9dd with SMTP id e17-20020a05651c039100b002989db0a9ddmr3848542ljp.50.1679146974706; Sat, 18 Mar 2023 06:42:54 -0700 (PDT) Received: from [192.168.1.101] (abym238.neoplus.adsl.tpnet.pl. [83.9.32.238]) by smtp.gmail.com with ESMTPSA id c2-20020a2e9d82000000b0029a0b50a34asm888367ljj.36.2023.03.18.06.42.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 18 Mar 2023 06:42:54 -0700 (PDT) From: Konrad Dybcio Date: Sat, 18 Mar 2023 14:42:47 +0100 Subject: [PATCH v6 1/9] dt-bindings: display/msm: dsi-controller-main: Fix deprecated QCM2290 compatible MIME-Version: 1.0 Message-Id: <20230307-topic-dsi_qcm-v6-1-70e13b1214fa@linaro.org> References: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@linaro.org> In-Reply-To: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@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=1679146971; l=1481; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=lSCVKFJ04QtIFibtVglZV7BCCs/8/zx27+lAfw7WMPU=; b=X/s/41QPUlm8nRs2vQaKIl635XNevr5YacB1S+xQkmK9HwhcN8L3ph+JFfv/IpLFvBj0pHm1IC6M af8muWHKDv5rbdPZkHE5JmnQP98Q8umthXsGYo2492dX8ODNKJbj X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable 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?1760713283272586711?= X-GMAIL-MSGID: =?utf-8?q?1760713283272586711?= The point of the previous cleanup was to disallow "qcom,mdss-dsi-ctrl" alone. This however didn't quite work out and the property became undocumented instead of deprecated. Fix that. Additionally, the "qcom," prefix was missed previously. Fix it. Fixes: 0c0f65c6dd44 ("dt-bindings: msm: dsi-controller-main: Add compatible strings for every current SoC") Acked-by: Rob Herring Reviewed-by: Marijn Suijten Signed-off-by: Konrad Dybcio Reviewed-by: Krzysztof Kozlowski --- .../devicetree/bindings/display/msm/dsi-controller-main.yaml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml index e75a3efe4dac..ecc89011bec4 100644 --- a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml +++ b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml @@ -31,10 +31,9 @@ properties: - qcom,sm8450-dsi-ctrl - qcom,sm8550-dsi-ctrl - const: qcom,mdss-dsi-ctrl - - items: - - enum: - - dsi-ctrl-6g-qcm2290 - - const: qcom,mdss-dsi-ctrl + - enum: + - qcom,dsi-ctrl-6g-qcm2290 + - qcom,mdss-dsi-ctrl # This should always come with an SoC-specific compatible deprecated: true reg: From patchwork Sat Mar 18 13:42:48 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 71598 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:604a:0:0:0:0:0 with SMTP id j10csp297021wrt; Sat, 18 Mar 2023 06:47:45 -0700 (PDT) X-Google-Smtp-Source: AK7set8PgiGnMnhPF5H3jQH/uduoW7wurHZzMdDVw1KKZoS59eVAwbhcNDLaYTuAVS0o9avRwlxz X-Received: by 2002:a05:6a20:a10a:b0:d4:beda:7a56 with SMTP id q10-20020a056a20a10a00b000d4beda7a56mr13383350pzk.50.1679147265736; Sat, 18 Mar 2023 06:47:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679147265; cv=none; d=google.com; s=arc-20160816; b=slmQlyhB5aMtqkFjvPhr9A1dUNvZdH2GNFMvx9ylidTTaQPkvh/p/RKiNAMCgT+59A IE4wi2cGw2/mNYX9AJkUUywOD4RzJcYx3xnbk14+wKETfCXurXWS6yfVrz9Ft1/G2Ho0 eu9q+HAOFevAk7MQfTUA9uvxp65WnB+VwWhw9Y1NpMd0czGC0BqiyFkWIGiH3nKo+pw/ L7/QGInLibpAEsz/tqZMsP92NsK4+TUAEI0q/f48dhPawCEUORx69mNP8UpU0qPApxq9 4yXkFaSRCb9fqo8W+1wJHirSoL/JJaQv08UOT0xHJm1i2tDlVjAEhYp9z8BhVyZbJPYC QfZA== 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=Ja37xKiglxJ/lPrUpuyUvSbThkrJV11m94PBRXq1WhI=; b=nhk5utTZ0cQ2XlcMVyaerOWMqiRsVYo/Q2eyy2rGq1BbrfE89XBD3roSOMwetN0HLr 0LRjYNm5uNBu9H7M1z+DnvfGG616Rf8Rhhrh5lWDeco3QqThiYIvUnc2WSFdXId5lpxq CG/aFxPIeOgLZes0tdzZaIoUzS5EY3vBSVBBByPOQtJavTYgYAy5UEo86Do/4AccNVOV VOgl7roPcZeJxgyIBvAAZoqFn9jPopLCnFZyclbJo2pVycP1pduvzILG0e5dPJCzQB2O 994FUfWjOnxmxtCcVZ1vUzGeyDKSy4zrF+Qt0C8y2EQ/Gs1kglsfFva8fdI3mXZRzMF8 4ctQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=j63kOdN4; 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 b14-20020a056a000cce00b005a8e1cc59bfsi5649605pfv.295.2023.03.18.06.47.31; Sat, 18 Mar 2023 06:47:45 -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=j63kOdN4; 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 S229799AbjCRNnJ (ORCPT + 99 others); Sat, 18 Mar 2023 09:43:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34388 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229787AbjCRNnB (ORCPT ); Sat, 18 Mar 2023 09:43:01 -0400 Received: from mail-lj1-x22c.google.com (mail-lj1-x22c.google.com [IPv6:2a00:1450:4864:20::22c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1D80216898 for ; Sat, 18 Mar 2023 06:42:58 -0700 (PDT) Received: by mail-lj1-x22c.google.com with SMTP id z5so7778310ljc.8 for ; Sat, 18 Mar 2023 06:42:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1679146976; 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=Ja37xKiglxJ/lPrUpuyUvSbThkrJV11m94PBRXq1WhI=; b=j63kOdN48NM1FMwxcRvOouDRuBkw/SDRBHKcP2kCDXbu3eHffkQvdRMB5TPrDoXTcX mHr1VIHZmvH42mEPA3OI5L0LoLqyrsx3ZyHhwdllm985tYhkwUSHBTBf9xgZP1CnUgTy NxeutMT6w3eoDEOWbp74rUCl1bSWJAZLEfTlaHP138zVMIqyhh25b74XRzQfERfdMGKm a3TqcZoBGwQEkRIFc9bG7NZx76E0ZY/ALPtwDZcBrsPYXH9Vkw3rmxnJurwkukLBHiOE Jd/fkrIYQVRk/5yg2Y4uQZI4ZgtCNDUFmrsTufkgG7z35+BfeMn+K8YNwK8jNjQrHUMN PcrQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679146976; 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=Ja37xKiglxJ/lPrUpuyUvSbThkrJV11m94PBRXq1WhI=; b=SN9EHrbCedXoascpUZRaN4RMLwte0WXLe4vrNy4HGEUu+kB/E3AZIMXiAtVWpgwNMn +TPfzJi6ZWgkJRvGteNNYMf6sAf9bYZo6Ss+hLQO2IBXdg/FcGXhSTul9wcUOWnO0d8i UkoK+uz8kymETcCCp+HB4wEFYBPBanHmB0P9guUxnU5n2utkGQvJhq4sOXUH9HLWU5sO Zu5uCZrfZgZqQVhZDIM2b0jsOLeGjB5ZI/BG/cGZgcpaMcWhUxRbE6Vj82BBAImfJl8/ bCqW9zNqxcgY8WIY+ItehjdsDredkIYc2zzAuEy5n8/FPrDV2Qh8MrlkbrVwl/7bgIkg uOeA== X-Gm-Message-State: AO0yUKXap6CbisJOyDQe1d1t4rFag8agPHqVPUYtHEhC4ISnlWSDSNVL wgSwlU3n9zQwa9oRJ6BVpNyW1g== X-Received: by 2002:a05:651c:b10:b0:295:9659:fba5 with SMTP id b16-20020a05651c0b1000b002959659fba5mr5354998ljr.37.1679146976294; Sat, 18 Mar 2023 06:42:56 -0700 (PDT) Received: from [192.168.1.101] (abym238.neoplus.adsl.tpnet.pl. [83.9.32.238]) by smtp.gmail.com with ESMTPSA id c2-20020a2e9d82000000b0029a0b50a34asm888367ljj.36.2023.03.18.06.42.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 18 Mar 2023 06:42:55 -0700 (PDT) From: Konrad Dybcio Date: Sat, 18 Mar 2023 14:42:48 +0100 Subject: [PATCH v6 2/9] drm/msm/dsi: Get rid of msm_dsi_config::num_dsi MIME-Version: 1.0 Message-Id: <20230307-topic-dsi_qcm-v6-2-70e13b1214fa@linaro.org> References: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@linaro.org> In-Reply-To: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@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=1679146971; l=5720; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=nAK7VhpEOKQPVDoVxGmSH//l3jkm1AocrDNJW7zWKno=; b=0sipnApXZIY2+VWgYQXjuxdpIip3V7pkk/e9SMtNlW7/sozotVv8DC+ri2fXG6ktgln5mEWPoQx6 cO56WjaJAvSYJhZTn5zVwfoXybtVsC1jvQYz/UY85zPo2/VBzZMG X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham 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?1760713523257423334?= X-GMAIL-MSGID: =?utf-8?q?1760713523257423334?= In preparation for supporting multiple sets of possible base registers, remove the num_dsi variable. We're comparing the io_start array contents with the reg value from the DTS, so it will either match one of the expected values or don't match against a zero (which we get from partial array initialization). Reviewed-by: Dmitry Baryshkov Reviewed-by: Marijn Suijten Signed-off-by: Konrad Dybcio --- drivers/gpu/drm/msm/dsi/dsi_cfg.c | 13 ------------- drivers/gpu/drm/msm/dsi/dsi_cfg.h | 1 - drivers/gpu/drm/msm/dsi/dsi_host.c | 2 +- 3 files changed, 1 insertion(+), 15 deletions(-) diff --git a/drivers/gpu/drm/msm/dsi/dsi_cfg.c b/drivers/gpu/drm/msm/dsi/dsi_cfg.c index 6d21f0b33411..4515f52b407a 100644 --- a/drivers/gpu/drm/msm/dsi/dsi_cfg.c +++ b/drivers/gpu/drm/msm/dsi/dsi_cfg.c @@ -22,7 +22,6 @@ static const struct msm_dsi_config apq8064_dsi_cfg = { .bus_clk_names = dsi_v2_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_v2_bus_clk_names), .io_start = { 0x4700000, 0x5800000 }, - .num_dsi = 2, }; static const char * const dsi_6g_bus_clk_names[] = { @@ -42,7 +41,6 @@ static const struct msm_dsi_config msm8974_apq8084_dsi_cfg = { .bus_clk_names = dsi_6g_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_6g_bus_clk_names), .io_start = { 0xfd922800, 0xfd922b00 }, - .num_dsi = 2, }; static const char * const dsi_8916_bus_clk_names[] = { @@ -61,7 +59,6 @@ static const struct msm_dsi_config msm8916_dsi_cfg = { .bus_clk_names = dsi_8916_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_8916_bus_clk_names), .io_start = { 0x1a98000 }, - .num_dsi = 1, }; static const char * const dsi_8976_bus_clk_names[] = { @@ -80,7 +77,6 @@ static const struct msm_dsi_config msm8976_dsi_cfg = { .bus_clk_names = dsi_8976_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_8976_bus_clk_names), .io_start = { 0x1a94000, 0x1a96000 }, - .num_dsi = 2, }; static const struct regulator_bulk_data msm8994_dsi_regulators[] = { @@ -99,7 +95,6 @@ static const struct msm_dsi_config msm8994_dsi_cfg = { .bus_clk_names = dsi_6g_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_6g_bus_clk_names), .io_start = { 0xfd998000, 0xfd9a0000 }, - .num_dsi = 2, }; static const char * const dsi_8996_bus_clk_names[] = { @@ -119,7 +114,6 @@ static const struct msm_dsi_config msm8996_dsi_cfg = { .bus_clk_names = dsi_8996_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_8996_bus_clk_names), .io_start = { 0x994000, 0x996000 }, - .num_dsi = 2, }; static const char * const dsi_msm8998_bus_clk_names[] = { @@ -138,7 +132,6 @@ static const struct msm_dsi_config msm8998_dsi_cfg = { .bus_clk_names = dsi_msm8998_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_msm8998_bus_clk_names), .io_start = { 0xc994000, 0xc996000 }, - .num_dsi = 2, }; static const char * const dsi_sdm660_bus_clk_names[] = { @@ -156,7 +149,6 @@ static const struct msm_dsi_config sdm660_dsi_cfg = { .bus_clk_names = dsi_sdm660_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_sdm660_bus_clk_names), .io_start = { 0xc994000, 0xc996000 }, - .num_dsi = 2, }; static const char * const dsi_sdm845_bus_clk_names[] = { @@ -178,7 +170,6 @@ static const struct msm_dsi_config sdm845_dsi_cfg = { .bus_clk_names = dsi_sdm845_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_sdm845_bus_clk_names), .io_start = { 0xae94000, 0xae96000 }, - .num_dsi = 2, }; static const struct regulator_bulk_data sm8550_dsi_regulators[] = { @@ -192,7 +183,6 @@ static const struct msm_dsi_config sm8550_dsi_cfg = { .bus_clk_names = dsi_sdm845_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_sdm845_bus_clk_names), .io_start = { 0xae94000, 0xae96000 }, - .num_dsi = 2, }; static const struct regulator_bulk_data sc7180_dsi_regulators[] = { @@ -206,7 +196,6 @@ static const struct msm_dsi_config sc7180_dsi_cfg = { .bus_clk_names = dsi_sc7180_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_sc7180_bus_clk_names), .io_start = { 0xae94000 }, - .num_dsi = 1, }; static const char * const dsi_sc7280_bus_clk_names[] = { @@ -224,7 +213,6 @@ static const struct msm_dsi_config sc7280_dsi_cfg = { .bus_clk_names = dsi_sc7280_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_sc7280_bus_clk_names), .io_start = { 0xae94000, 0xae96000 }, - .num_dsi = 2, }; static const char * const dsi_qcm2290_bus_clk_names[] = { @@ -242,7 +230,6 @@ static const struct msm_dsi_config qcm2290_dsi_cfg = { .bus_clk_names = dsi_qcm2290_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_qcm2290_bus_clk_names), .io_start = { 0x5e94000 }, - .num_dsi = 1, }; static const struct msm_dsi_host_cfg_ops msm_dsi_v2_host_ops = { diff --git a/drivers/gpu/drm/msm/dsi/dsi_cfg.h b/drivers/gpu/drm/msm/dsi/dsi_cfg.h index 44be4a88aa83..6b6b16c5fd25 100644 --- a/drivers/gpu/drm/msm/dsi/dsi_cfg.h +++ b/drivers/gpu/drm/msm/dsi/dsi_cfg.h @@ -39,7 +39,6 @@ struct msm_dsi_config { const char * const *bus_clk_names; const int num_bus_clks; const resource_size_t io_start[DSI_MAX]; - const int num_dsi; }; struct msm_dsi_host_cfg_ops { diff --git a/drivers/gpu/drm/msm/dsi/dsi_host.c b/drivers/gpu/drm/msm/dsi/dsi_host.c index 18fa30e1e858..9021f0d65515 100644 --- a/drivers/gpu/drm/msm/dsi/dsi_host.c +++ b/drivers/gpu/drm/msm/dsi/dsi_host.c @@ -1868,7 +1868,7 @@ static int dsi_host_get_id(struct msm_dsi_host *msm_host) if (!res) return -EINVAL; - for (i = 0; i < cfg->num_dsi; i++) { + for (i = 0; i < DSI_MAX; i++) { if (cfg->io_start[i] == res->start) return i; } From patchwork Sat Mar 18 13:42:49 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 71595 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:604a:0:0:0:0:0 with SMTP id j10csp295717wrt; Sat, 18 Mar 2023 06:44:14 -0700 (PDT) X-Google-Smtp-Source: AK7set9QdZML9IkGLqYt+Git3ZUg4ib1aMzVGuVL7sGk/Ci0blIzevHNj0VHdNhvg/SyU5cH4V8L X-Received: by 2002:a17:903:11cf:b0:19f:1bd9:505 with SMTP id q15-20020a17090311cf00b0019f1bd90505mr13914807plh.36.1679147054380; Sat, 18 Mar 2023 06:44:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679147054; cv=none; d=google.com; s=arc-20160816; b=AERwA5oURYwPzjBl2KWFJbVsouSD13SD3m4tLwO2lswsELGCQNqEAbNypCwtavjPUQ UInlMWS4kDIjyeesi+M1KDbNJr9br074VFq/xye9C8wf1W/IN9ezL34e2EFeaEPGaBD6 TSaFyO56JzNO++lvuIK7xZLX3ydU8pTpy/6QaeFmt2yUnEYCVEdvHloJoanpi5mHQBBF QgjHdWjLWq/wUB2v1bDqSIxNOqZdF83b0x9Fj9UgeuxkkKOlQQRDDda9YrH3uRwN32zA e1v2z7vHfuyntPPZ7VYe+uGHbODcZYNLZt53NtKCJ250Y7frYdUZXzdjgs/CmxTg5drJ tjWg== 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=6mz7dhLEVkKzAk8Lkvywe3WYisGA69PWt7jvCUOITN8=; b=qgegkyW9e2PjTf3eXfoIq2nk0JqsymkIJpUYRsKi1TgUJdw5y9ehU7dfMqhvvXcWxI prF4Yx7yvfVRxyQ4MpJpaOjgSm1ssBzlqXh71sBF/GKxBw9ESkItpE/ApCfBVMfLLv2l GWSsBGZyVTuisTNyb41fVKaSExAP2vjp7zfcNi3fKsrDH/ni/NZwY/ttAxpaW8rV/qNO vEeayj+X7q3/40MWWoOsnIDsOzjcJ4wonU4a1RXjceNXMiTBW47DCh8VN589KaoHdLjy Kzq7LYSskHLl9HScU51Zj1WPBcpor2mxNek/lk/AQjplmISOxCIk/dXb3yxEQLSK2SKF 16IQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=l5RxrNP+; 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 ke11-20020a170903340b00b001a0544138b8si4924844plb.395.2023.03.18.06.43.58; Sat, 18 Mar 2023 06:44:14 -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=l5RxrNP+; 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 S229890AbjCRNnP (ORCPT + 99 others); Sat, 18 Mar 2023 09:43:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34628 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229788AbjCRNnI (ORCPT ); Sat, 18 Mar 2023 09:43:08 -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 9C87332532 for ; Sat, 18 Mar 2023 06:42:59 -0700 (PDT) Received: by mail-lj1-x22b.google.com with SMTP id 20so644648lju.0 for ; Sat, 18 Mar 2023 06:42:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1679146978; 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=6mz7dhLEVkKzAk8Lkvywe3WYisGA69PWt7jvCUOITN8=; b=l5RxrNP+TtC35jL5wSHwWEmzYcpTKYJiVNeU7phV2VuXQ+JNCMp9q4UexzZrpDwU5R KnrjB8DZn/kONTNEpVXtXYcwFz3d2zUNaW/F1cq5hnQ4btoQ3FjYLYzF9nqeyFxo6Mx2 pPaLMOroe7P5/SolQ1DbJ24fU1cgAR8nMdI3FgG2fh7th0mxOKOr0Jm2Qmgo6q+S7ZmQ JB8em81q1zC6hvGehieWV5a9f7SGlQWuSg4hhxa2nwjEw+zRbmirvKE0dDaDOYsx3LIw Dj6iwzbceiOypEbHT7yT650y2SVD1MCjPdksuRsOXJX/tXKH8XOvO9d1nJL76CDaHXR3 zqEQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679146978; 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=6mz7dhLEVkKzAk8Lkvywe3WYisGA69PWt7jvCUOITN8=; b=gDRUKCddSwhGd8nyWyB86xIZeGCVY+2dd6LupOSxZX6rSJZjy+r0D1VBDjjOAzB8RK SP6gCSSkjq6YgMq2xIJbdqHsrfhtuXNXGGh9cBzLkIkJr+6zLDD5QBzXfQw5Z68DWVDX VdGoAKRMXR6XxMW9yCaRw0a2xkg59RFknNqFPksocubo687Vi4CFZBcxMbg34pgYwBkE ir4tthDWH+FveKENOZG4zeGbiSIcAE8XemU41JUvA7FIGkow6VLENVXlBNi3QsHlpzTj TiyWdd3TNyVg5icodrU7xh/ne4/1/nZq1edcRwp42xawJ+0u6CfkiE8lWvhYJgDi7LrA tsig== X-Gm-Message-State: AO0yUKX0gU5xcW7x3bTeMGY3ZfnYIAiqrp5Q7VJb6teZ9a+oEXTdnpWz IN7scD50k1XgS/LvWWWHDZbI5w== X-Received: by 2002:a2e:9255:0:b0:299:f770:db5e with SMTP id v21-20020a2e9255000000b00299f770db5emr2373447ljg.16.1679146977879; Sat, 18 Mar 2023 06:42:57 -0700 (PDT) Received: from [192.168.1.101] (abym238.neoplus.adsl.tpnet.pl. [83.9.32.238]) by smtp.gmail.com with ESMTPSA id c2-20020a2e9d82000000b0029a0b50a34asm888367ljj.36.2023.03.18.06.42.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 18 Mar 2023 06:42:57 -0700 (PDT) From: Konrad Dybcio Date: Sat, 18 Mar 2023 14:42:49 +0100 Subject: [PATCH v6 3/9] drm/msm/dsi: Fix DSI index detection when version clash occurs MIME-Version: 1.0 Message-Id: <20230307-topic-dsi_qcm-v6-3-70e13b1214fa@linaro.org> References: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@linaro.org> In-Reply-To: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@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=1679146971; l=8216; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=b+otjvnFVNWNHQbPO9HD+5KH7xMK3hiBo7WDBK4sSP4=; b=MfZ/bvuF4tdu+wbKKRHHAtd41nx3udsJRMbHkWH2gfTniRqLXaDQHSqqfteGWRp+h1YUTjF/qq6r JTxxWCUfCNm02easWL3yM/g3WG9mmiNRWC9jK8SbyOk64nVlBdiJ X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham 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?1760713301871696613?= X-GMAIL-MSGID: =?utf-8?q?1760713301871696613?= Currently, we allow for MAX_DSI entries in io_start to facilitate for MAX_DSI number of DSI hosts at different addresses. The configuration is matched against the DSI CTRL hardware revision read back from the component. We need a way to resolve situations where multiple SoCs with different register maps may use the same version of DSI CTRL. In preparation to do so, make msm_dsi_config a 2d array where each entry represents a set of configurations adequate for a given SoC. This is totally fine to do, as the only differentiating factors between same-version-different-SoCs configurations are the number of DSI hosts (1 or 2, at least as of today) and the set of base registers. The regulator setup is the same, because the DSI hardware is the same, regardless of the SoC it was implemented in. In addition to that, update the matching logic such that it will loop over VARIANTS_MAX variants, making sure they are all taken into account. Reviewed-by: Dmitry Baryshkov Reviewed-by: Marijn Suijten Signed-off-by: Konrad Dybcio --- drivers/gpu/drm/msm/dsi/dsi_cfg.c | 52 ++++++++++++++++++++++++++++---------- drivers/gpu/drm/msm/dsi/dsi_cfg.h | 5 +++- drivers/gpu/drm/msm/dsi/dsi_host.c | 10 ++++---- 3 files changed, 48 insertions(+), 19 deletions(-) diff --git a/drivers/gpu/drm/msm/dsi/dsi_cfg.c b/drivers/gpu/drm/msm/dsi/dsi_cfg.c index 4515f52b407a..6c192963c100 100644 --- a/drivers/gpu/drm/msm/dsi/dsi_cfg.c +++ b/drivers/gpu/drm/msm/dsi/dsi_cfg.c @@ -21,7 +21,9 @@ static const struct msm_dsi_config apq8064_dsi_cfg = { .num_regulators = ARRAY_SIZE(apq8064_dsi_regulators), .bus_clk_names = dsi_v2_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_v2_bus_clk_names), - .io_start = { 0x4700000, 0x5800000 }, + .io_start = { + { 0x4700000, 0x5800000 }, + }, }; static const char * const dsi_6g_bus_clk_names[] = { @@ -40,7 +42,9 @@ static const struct msm_dsi_config msm8974_apq8084_dsi_cfg = { .num_regulators = ARRAY_SIZE(msm8974_apq8084_regulators), .bus_clk_names = dsi_6g_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_6g_bus_clk_names), - .io_start = { 0xfd922800, 0xfd922b00 }, + .io_start = { + { 0xfd922800, 0xfd922b00 }, + }, }; static const char * const dsi_8916_bus_clk_names[] = { @@ -58,7 +62,9 @@ static const struct msm_dsi_config msm8916_dsi_cfg = { .num_regulators = ARRAY_SIZE(msm8916_dsi_regulators), .bus_clk_names = dsi_8916_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_8916_bus_clk_names), - .io_start = { 0x1a98000 }, + .io_start = { + { 0x1a98000 }, + }, }; static const char * const dsi_8976_bus_clk_names[] = { @@ -76,7 +82,9 @@ static const struct msm_dsi_config msm8976_dsi_cfg = { .num_regulators = ARRAY_SIZE(msm8976_dsi_regulators), .bus_clk_names = dsi_8976_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_8976_bus_clk_names), - .io_start = { 0x1a94000, 0x1a96000 }, + .io_start = { + { 0x1a94000, 0x1a96000 }, + }, }; static const struct regulator_bulk_data msm8994_dsi_regulators[] = { @@ -94,7 +102,9 @@ static const struct msm_dsi_config msm8994_dsi_cfg = { .num_regulators = ARRAY_SIZE(msm8994_dsi_regulators), .bus_clk_names = dsi_6g_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_6g_bus_clk_names), - .io_start = { 0xfd998000, 0xfd9a0000 }, + .io_start = { + { 0xfd998000, 0xfd9a0000 }, + }, }; static const char * const dsi_8996_bus_clk_names[] = { @@ -113,7 +123,9 @@ static const struct msm_dsi_config msm8996_dsi_cfg = { .num_regulators = ARRAY_SIZE(msm8996_dsi_regulators), .bus_clk_names = dsi_8996_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_8996_bus_clk_names), - .io_start = { 0x994000, 0x996000 }, + .io_start = { + { 0x994000, 0x996000 }, + }, }; static const char * const dsi_msm8998_bus_clk_names[] = { @@ -131,7 +143,9 @@ static const struct msm_dsi_config msm8998_dsi_cfg = { .num_regulators = ARRAY_SIZE(msm8998_dsi_regulators), .bus_clk_names = dsi_msm8998_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_msm8998_bus_clk_names), - .io_start = { 0xc994000, 0xc996000 }, + .io_start = { + { 0xc994000, 0xc996000 }, + }, }; static const char * const dsi_sdm660_bus_clk_names[] = { @@ -148,7 +162,9 @@ static const struct msm_dsi_config sdm660_dsi_cfg = { .num_regulators = ARRAY_SIZE(sdm660_dsi_regulators), .bus_clk_names = dsi_sdm660_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_sdm660_bus_clk_names), - .io_start = { 0xc994000, 0xc996000 }, + .io_start = { + { 0xc994000, 0xc996000 }, + }, }; static const char * const dsi_sdm845_bus_clk_names[] = { @@ -169,7 +185,9 @@ static const struct msm_dsi_config sdm845_dsi_cfg = { .num_regulators = ARRAY_SIZE(sdm845_dsi_regulators), .bus_clk_names = dsi_sdm845_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_sdm845_bus_clk_names), - .io_start = { 0xae94000, 0xae96000 }, + .io_start = { + { 0xae94000, 0xae96000 }, + }, }; static const struct regulator_bulk_data sm8550_dsi_regulators[] = { @@ -182,7 +200,9 @@ static const struct msm_dsi_config sm8550_dsi_cfg = { .num_regulators = ARRAY_SIZE(sm8550_dsi_regulators), .bus_clk_names = dsi_sdm845_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_sdm845_bus_clk_names), - .io_start = { 0xae94000, 0xae96000 }, + .io_start = { + { 0xae94000, 0xae96000 }, + }, }; static const struct regulator_bulk_data sc7180_dsi_regulators[] = { @@ -195,7 +215,9 @@ static const struct msm_dsi_config sc7180_dsi_cfg = { .num_regulators = ARRAY_SIZE(sc7180_dsi_regulators), .bus_clk_names = dsi_sc7180_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_sc7180_bus_clk_names), - .io_start = { 0xae94000 }, + .io_start = { + { 0xae94000 }, + }, }; static const char * const dsi_sc7280_bus_clk_names[] = { @@ -212,7 +234,9 @@ static const struct msm_dsi_config sc7280_dsi_cfg = { .num_regulators = ARRAY_SIZE(sc7280_dsi_regulators), .bus_clk_names = dsi_sc7280_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_sc7280_bus_clk_names), - .io_start = { 0xae94000, 0xae96000 }, + .io_start = { + { 0xae94000, 0xae96000 }, + }, }; static const char * const dsi_qcm2290_bus_clk_names[] = { @@ -229,7 +253,9 @@ static const struct msm_dsi_config qcm2290_dsi_cfg = { .num_regulators = ARRAY_SIZE(qcm2290_dsi_cfg_regulators), .bus_clk_names = dsi_qcm2290_bus_clk_names, .num_bus_clks = ARRAY_SIZE(dsi_qcm2290_bus_clk_names), - .io_start = { 0x5e94000 }, + .io_start = { + { 0x5e94000 }, + }, }; static const struct msm_dsi_host_cfg_ops msm_dsi_v2_host_ops = { diff --git a/drivers/gpu/drm/msm/dsi/dsi_cfg.h b/drivers/gpu/drm/msm/dsi/dsi_cfg.h index 6b6b16c5fd25..8772a3631ac1 100644 --- a/drivers/gpu/drm/msm/dsi/dsi_cfg.h +++ b/drivers/gpu/drm/msm/dsi/dsi_cfg.h @@ -32,13 +32,16 @@ #define DSI_6G_REG_SHIFT 4 +/* Maximum number of configurations matched against the same hw revision */ +#define VARIANTS_MAX 2 + struct msm_dsi_config { u32 io_offset; const struct regulator_bulk_data *regulator_data; int num_regulators; const char * const *bus_clk_names; const int num_bus_clks; - const resource_size_t io_start[DSI_MAX]; + const resource_size_t io_start[VARIANTS_MAX][DSI_MAX]; }; struct msm_dsi_host_cfg_ops { diff --git a/drivers/gpu/drm/msm/dsi/dsi_host.c b/drivers/gpu/drm/msm/dsi/dsi_host.c index 9021f0d65515..9cfb9e91bfea 100644 --- a/drivers/gpu/drm/msm/dsi/dsi_host.c +++ b/drivers/gpu/drm/msm/dsi/dsi_host.c @@ -1862,16 +1862,16 @@ static int dsi_host_get_id(struct msm_dsi_host *msm_host) struct platform_device *pdev = msm_host->pdev; const struct msm_dsi_config *cfg = msm_host->cfg_hnd->cfg; struct resource *res; - int i; + int i, j; res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "dsi_ctrl"); if (!res) return -EINVAL; - for (i = 0; i < DSI_MAX; i++) { - if (cfg->io_start[i] == res->start) - return i; - } + for (i = 0; i < VARIANTS_MAX; i++) + for (j = 0; j < DSI_MAX; j++) + if (cfg->io_start[i][j] == res->start) + return j; return -EINVAL; } From patchwork Sat Mar 18 13:42:50 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 71601 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:604a:0:0:0:0:0 with SMTP id j10csp297712wrt; Sat, 18 Mar 2023 06:50:06 -0700 (PDT) X-Google-Smtp-Source: AK7set9kcv/T2U8eWBueBs7fbUjrc7hUIPqNwtcmeK+sjKIdB21vmyoVaw4Zks4jyRHwBuqHw2dy X-Received: by 2002:a17:90b:3e8b:b0:231:248c:6ac4 with SMTP id rj11-20020a17090b3e8b00b00231248c6ac4mr11593416pjb.7.1679147406225; Sat, 18 Mar 2023 06:50:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679147406; cv=none; d=google.com; s=arc-20160816; b=VDYp5zg1l9FO7ZC+TFcXE07Fb99+Wi+BjKmbTxqDpGt7O5dq93bd8y+Kj26e3OoiId vntKi05lqtqsi+A+rsqUjrwaaIr0uxQQRCk6QzdK+gCMXPyeiTrqPLFWlBUMx4+8cH31 5Qe61YH3oa4KZATksAAVruFHqy+4bqBPHPtwco1uQxmEqOg8Jonuhxxj+XMdo8EryMgC nQBogr5E/ydBhCO89ExhXZxnGL2/au6+EX7c05oxI9oL7BBvdYA1rKmTafHtXlWKcL6Q 7lCuqdGJ/qog7xnJmXNwHOJH2U07ztTiiV0Xqws4yk8VYAn3JbQHq2pOIfIrHhQUN/nI uu6Q== 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=64Eim4J+wnLNg16H207185gsYiLvTQ9YXeAiDAajBeo=; b=uqGiiz0CRVK8OcfjOUtARfZcNwH7P4SzyCbelQzeHmuaE4HrGG166LoHmfyGGwKOoX BvumAP6bfITzMpMy60LeZ+2mRyQ/4mnTJWkoPtMKW7GZdgCVyNayzyksQHJhuLRPv3S8 /hxVRuu2tsPWEGxbRChJUlUz1vpem1aXleXvKgWyi/Ogv22FKh/m4h4D9RS3oDMdx0nW GawRFCLa4VFooatQQD8W0qUDRpy1iEvcLgU42e4o5NNwOqDMo6ozIdG9D1FMdPcnrQda Thn4Ykb0Dg02Z/cchQhXMZK8HDahqdEXmLmKgoFj59TTg996Ef6gfowegUnL/EmIOHiW KUSQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ZmPK7f34; 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 v20-20020a17090a899400b0023ef9514233si4993427pjn.116.2023.03.18.06.49.50; Sat, 18 Mar 2023 06:50:06 -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=ZmPK7f34; 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 S229820AbjCRNnL (ORCPT + 99 others); Sat, 18 Mar 2023 09:43:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34462 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229798AbjCRNnE (ORCPT ); Sat, 18 Mar 2023 09:43:04 -0400 Received: from mail-lj1-x230.google.com (mail-lj1-x230.google.com [IPv6:2a00:1450:4864:20::230]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 552B432CD5 for ; Sat, 18 Mar 2023 06:43:00 -0700 (PDT) Received: by mail-lj1-x230.google.com with SMTP id t14so7791032ljd.5 for ; Sat, 18 Mar 2023 06:43:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1679146979; 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=64Eim4J+wnLNg16H207185gsYiLvTQ9YXeAiDAajBeo=; b=ZmPK7f34jfn/APMqkk2gLGWySTgDjm48S5x6Fwx1Zwi05nRKt3SlJO2IUJNDEz7THd WIHnpkcpQ74MDnGHngpTAYbq/Hhd5BFfMKGWp7TKLIHFy7bZRvkZB8qZMbTBmHnr0EwG kN3puilAjHRR8Bb8Gua92H6kezHcO7qXGscCeZP5OsnIYYtU1PwztkZSL69EWp46uZro 83wBQxrU1qRvCAU9e1/I6x5x2+BtAxriBbQJ+R3Ofa44foGypVUWnIn9FcNXwclp2Ipt mr6t+WNUpqHmzCqAL6hSWoUmobNTQEhedKKdIpLN/zFaEhy8/OSf+kdGovb4wKABxAG+ 36Pg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679146979; 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=64Eim4J+wnLNg16H207185gsYiLvTQ9YXeAiDAajBeo=; b=5RHoh/D3pHgpvlvDFbUoQi4CGa5vb9Y+D+o1arUxNdtXiKA2fNgcccIObtr4Kh6h21 ancC7UyH23uGJ+cTYpuReCPkyHcEtPkz0WbUROl9cXmGRqbeZ7ss8LoEMiApOg90rKAb dGb4YRjuyKhYv0M+yXgMXu6ojVuIAA+9a2bKtmfS8qZDGK97FPDnkRyY1w1ySnT69bzD do1eLrEBl45A5pARJxiGbUP26xaZJbZ7fU/vcSNZotY01LJO9vAuWQmPT+vG4nUqOpsL iGeLMAWVQd1SiK0g4CbtOuv6VU1JqRTtUHBZ/ASoYKO9CHBdwKIviMJhSG9edhH7FjvX 6b1A== X-Gm-Message-State: AO0yUKWl21ZssqbqJ1OCaz5efnwj6ST5iFkEk00XbrNI9qRUm4P4xEfZ mlx3QLQKfQH/eP6QISJXP3egxA== X-Received: by 2002:a2e:be29:0:b0:290:6af8:ec25 with SMTP id z41-20020a2ebe29000000b002906af8ec25mr5831340ljq.52.1679146979675; Sat, 18 Mar 2023 06:42:59 -0700 (PDT) Received: from [192.168.1.101] (abym238.neoplus.adsl.tpnet.pl. [83.9.32.238]) by smtp.gmail.com with ESMTPSA id c2-20020a2e9d82000000b0029a0b50a34asm888367ljj.36.2023.03.18.06.42.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 18 Mar 2023 06:42:59 -0700 (PDT) From: Konrad Dybcio Date: Sat, 18 Mar 2023 14:42:50 +0100 Subject: [PATCH v6 4/9] drm/msm/dsi: dsi_cfg: Deduplicate identical structs MIME-Version: 1.0 Message-Id: <20230307-topic-dsi_qcm-v6-4-70e13b1214fa@linaro.org> References: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@linaro.org> In-Reply-To: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@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=1679146971; l=7014; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=eQGewel5eMIUbnjRWU8o9jYKXbfa44urQPoDhCO0rnI=; b=aIP2Ci+k4bWQEmaszkmmla0vcEoEAg71XC+VZWKNhlyqM9RKec6JOrzeikoDuGx8RBfy+CT/bgY5 4VtK1qW0BucTsvI7eVuEMI9vqDsF32vJ41jz2cAyaFqhOepQXBkq X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham 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?1760713670306350159?= X-GMAIL-MSGID: =?utf-8?q?1760713670306350159?= Some structs were defined multiple times for no apparent reason. Deduplicate them. Reviewed-by: Dmitry Baryshkov Reviewed-by: Marijn Suijten Signed-off-by: Konrad Dybcio --- drivers/gpu/drm/msm/dsi/dsi_cfg.c | 93 +++++++++++++-------------------------- 1 file changed, 30 insertions(+), 63 deletions(-) diff --git a/drivers/gpu/drm/msm/dsi/dsi_cfg.c b/drivers/gpu/drm/msm/dsi/dsi_cfg.c index 6c192963c100..039f503233d7 100644 --- a/drivers/gpu/drm/msm/dsi/dsi_cfg.c +++ b/drivers/gpu/drm/msm/dsi/dsi_cfg.c @@ -47,41 +47,32 @@ static const struct msm_dsi_config msm8974_apq8084_dsi_cfg = { }, }; -static const char * const dsi_8916_bus_clk_names[] = { +static const char * const dsi_v1_3_1_clk_names[] = { "mdp_core", "iface", "bus", }; -static const struct regulator_bulk_data msm8916_dsi_regulators[] = { +static const struct regulator_bulk_data dsi_v1_3_1_regulators[] = { { .supply = "vdda", .init_load_uA = 100000 }, /* 1.2 V */ { .supply = "vddio", .init_load_uA = 100000 }, /* 1.8 V */ }; static const struct msm_dsi_config msm8916_dsi_cfg = { .io_offset = DSI_6G_REG_SHIFT, - .regulator_data = msm8916_dsi_regulators, - .num_regulators = ARRAY_SIZE(msm8916_dsi_regulators), - .bus_clk_names = dsi_8916_bus_clk_names, - .num_bus_clks = ARRAY_SIZE(dsi_8916_bus_clk_names), + .regulator_data = dsi_v1_3_1_regulators, + .num_regulators = ARRAY_SIZE(dsi_v1_3_1_regulators), + .bus_clk_names = dsi_v1_3_1_clk_names, + .num_bus_clks = ARRAY_SIZE(dsi_v1_3_1_clk_names), .io_start = { { 0x1a98000 }, }, }; -static const char * const dsi_8976_bus_clk_names[] = { - "mdp_core", "iface", "bus", -}; - -static const struct regulator_bulk_data msm8976_dsi_regulators[] = { - { .supply = "vdda", .init_load_uA = 100000 }, /* 1.2 V */ - { .supply = "vddio", .init_load_uA = 100000 }, /* 1.8 V */ -}; - static const struct msm_dsi_config msm8976_dsi_cfg = { .io_offset = DSI_6G_REG_SHIFT, - .regulator_data = msm8976_dsi_regulators, - .num_regulators = ARRAY_SIZE(msm8976_dsi_regulators), - .bus_clk_names = dsi_8976_bus_clk_names, - .num_bus_clks = ARRAY_SIZE(dsi_8976_bus_clk_names), + .regulator_data = dsi_v1_3_1_regulators, + .num_regulators = ARRAY_SIZE(dsi_v1_3_1_regulators), + .bus_clk_names = dsi_v1_3_1_clk_names, + .num_bus_clks = ARRAY_SIZE(dsi_v1_3_1_clk_names), .io_start = { { 0x1a94000, 0x1a96000 }, }, @@ -107,10 +98,6 @@ static const struct msm_dsi_config msm8994_dsi_cfg = { }, }; -static const char * const dsi_8996_bus_clk_names[] = { - "mdp_core", "iface", "bus", "core_mmss", -}; - static const struct regulator_bulk_data msm8996_dsi_regulators[] = { { .supply = "vdda", .init_load_uA = 18160 }, /* 1.25 V */ { .supply = "vcca", .init_load_uA = 17000 }, /* 0.925 V */ @@ -121,8 +108,8 @@ static const struct msm_dsi_config msm8996_dsi_cfg = { .io_offset = DSI_6G_REG_SHIFT, .regulator_data = msm8996_dsi_regulators, .num_regulators = ARRAY_SIZE(msm8996_dsi_regulators), - .bus_clk_names = dsi_8996_bus_clk_names, - .num_bus_clks = ARRAY_SIZE(dsi_8996_bus_clk_names), + .bus_clk_names = dsi_6g_bus_clk_names, + .num_bus_clks = ARRAY_SIZE(dsi_6g_bus_clk_names), .io_start = { { 0x994000, 0x996000 }, }, @@ -167,24 +154,20 @@ static const struct msm_dsi_config sdm660_dsi_cfg = { }, }; -static const char * const dsi_sdm845_bus_clk_names[] = { +static const char * const dsi_v2_4_clk_names[] = { "iface", "bus", }; -static const char * const dsi_sc7180_bus_clk_names[] = { - "iface", "bus", -}; - -static const struct regulator_bulk_data sdm845_dsi_regulators[] = { +static const struct regulator_bulk_data dsi_v2_4_regulators[] = { { .supply = "vdda", .init_load_uA = 21800 }, /* 1.2 V */ }; static const struct msm_dsi_config sdm845_dsi_cfg = { .io_offset = DSI_6G_REG_SHIFT, - .regulator_data = sdm845_dsi_regulators, - .num_regulators = ARRAY_SIZE(sdm845_dsi_regulators), - .bus_clk_names = dsi_sdm845_bus_clk_names, - .num_bus_clks = ARRAY_SIZE(dsi_sdm845_bus_clk_names), + .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, 0xae96000 }, }, @@ -198,32 +181,24 @@ static const struct msm_dsi_config sm8550_dsi_cfg = { .io_offset = DSI_6G_REG_SHIFT, .regulator_data = sm8550_dsi_regulators, .num_regulators = ARRAY_SIZE(sm8550_dsi_regulators), - .bus_clk_names = dsi_sdm845_bus_clk_names, - .num_bus_clks = ARRAY_SIZE(dsi_sdm845_bus_clk_names), + .bus_clk_names = dsi_v2_4_clk_names, + .num_bus_clks = ARRAY_SIZE(dsi_v2_4_clk_names), .io_start = { { 0xae94000, 0xae96000 }, }, }; -static const struct regulator_bulk_data sc7180_dsi_regulators[] = { - { .supply = "vdda", .init_load_uA = 21800 }, /* 1.2 V */ -}; - static const struct msm_dsi_config sc7180_dsi_cfg = { .io_offset = DSI_6G_REG_SHIFT, - .regulator_data = sc7180_dsi_regulators, - .num_regulators = ARRAY_SIZE(sc7180_dsi_regulators), - .bus_clk_names = dsi_sc7180_bus_clk_names, - .num_bus_clks = ARRAY_SIZE(dsi_sc7180_bus_clk_names), + .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 char * const dsi_sc7280_bus_clk_names[] = { - "iface", "bus", -}; - static const struct regulator_bulk_data sc7280_dsi_regulators[] = { { .supply = "vdda", .init_load_uA = 8350 }, /* 1.2 V */ }; @@ -232,27 +207,19 @@ static const struct msm_dsi_config sc7280_dsi_cfg = { .io_offset = DSI_6G_REG_SHIFT, .regulator_data = sc7280_dsi_regulators, .num_regulators = ARRAY_SIZE(sc7280_dsi_regulators), - .bus_clk_names = dsi_sc7280_bus_clk_names, - .num_bus_clks = ARRAY_SIZE(dsi_sc7280_bus_clk_names), + .bus_clk_names = dsi_v2_4_clk_names, + .num_bus_clks = ARRAY_SIZE(dsi_v2_4_clk_names), .io_start = { { 0xae94000, 0xae96000 }, }, }; -static const char * const dsi_qcm2290_bus_clk_names[] = { - "iface", "bus", -}; - -static const struct regulator_bulk_data qcm2290_dsi_cfg_regulators[] = { - { .supply = "vdda", .init_load_uA = 21800 }, /* 1.2 V */ -}; - static const struct msm_dsi_config qcm2290_dsi_cfg = { .io_offset = DSI_6G_REG_SHIFT, - .regulator_data = qcm2290_dsi_cfg_regulators, - .num_regulators = ARRAY_SIZE(qcm2290_dsi_cfg_regulators), - .bus_clk_names = dsi_qcm2290_bus_clk_names, - .num_bus_clks = ARRAY_SIZE(dsi_qcm2290_bus_clk_names), + .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 = { { 0x5e94000 }, }, From patchwork Sat Mar 18 13:42:51 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 71602 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:604a:0:0:0:0:0 with SMTP id j10csp298824wrt; Sat, 18 Mar 2023 06:53:20 -0700 (PDT) X-Google-Smtp-Source: AK7set+6HCJy7+9L/wWRBfwnWz6ZsNZfuYr5ZE7OqnaeW3TPBvpm91Ve2xkTbB24XKdEwUU32YtL X-Received: by 2002:a62:7bc5:0:b0:623:c943:a2f8 with SMTP id w188-20020a627bc5000000b00623c943a2f8mr10418005pfc.20.1679147600303; Sat, 18 Mar 2023 06:53:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679147600; cv=none; d=google.com; s=arc-20160816; b=q38yXmr41stM+KH+kQ4vmh6cQPWDDF7G+CjuOrkTN8Bf5uYBtkoKzV0F78/F5cXOb0 Glkq/E+5h9V4Y+OrV8yxDaglQjZgiFH5caMCSh4U10fjxze8t9JeftHd2Twd7c3do4WO 3E/jyIL/ygoF2bEnC/QDmJg9zSgBbzhuU+02d+Ngrq+tkhFJEYkq4pb0rQpJGblA2+ln EmBg/h4bnSrSx/CXYAYRwtmRWYq9pUsOLlPLa2XQn4O6nIfUDztKJ2K+kWrXGxCths5k AnjMScaRUUn5GB7z+2cSs76WLajsGtrUUm2Hbnsc/vKr94rTJYWjGUaEOF9P+iSOD8Zo l47A== 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=YtmjJAznucxEqf19PknLMOiFqaeiZ+3FUQd0lnqmek8hyYTQaTuoTCNrsxY+kW9JI5 71g4SKm5C14bnp2H2xpGE1D03pmMWG08QV4GYF+/s15JfEiz1506A5JwEee5PbnFq2Ff cQi8TvV8Xqz5ff9JuB5ZUfskDCK4VlBDNlLu5Gr+UmyRCpuo6mBR5JpXJU8jV7ZS8Rcc 23j0KEaWq+3EmkugaiBIJQBbr0Tk6y8eOUf/lXC8kZA3HnGbWJ5rjyGArnSSgKkEgOUZ 3HGTDwBpH8sAB+9x76FR+6OAT5qKkVoqbJulqRwR9d7Apxilxj+vdJKGmvhQMyAhV/+u RJ+Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="j/SuZWK4"; 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 b14-20020a056a000cce00b005a8e1cc59bfsi5649605pfv.295.2023.03.18.06.53.02; Sat, 18 Mar 2023 06:53:20 -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="j/SuZWK4"; 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 S229867AbjCRNnV (ORCPT + 99 others); Sat, 18 Mar 2023 09:43:21 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34708 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229822AbjCRNnI (ORCPT ); Sat, 18 Mar 2023 09:43:08 -0400 Received: from mail-lf1-x135.google.com (mail-lf1-x135.google.com [IPv6:2a00:1450:4864:20::135]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0D4BC33CD7 for ; Sat, 18 Mar 2023 06:43:02 -0700 (PDT) Received: by mail-lf1-x135.google.com with SMTP id y15so9744214lfa.7 for ; Sat, 18 Mar 2023 06:43:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1679146981; 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=j/SuZWK4hGzsjGSVxR7d8gdxnkenVxTgbXW9BWPte7dDWKjpvkRvb1DaNyfRBX4I0W G1bXkkbuItkcaCtiEuozT4vbyXYez0ODAylavTT9AO89s9TCGUCq52Q7v9U9emZ8ZGO8 0ixeuALLMGp9IEpUREfGs5x88UQYFRFt6y8uYYsGi4TamiEBru8aSD7Fq54IkJ7wHUED Vt8ZH1TuoXEBaYTzzJsmhZBpBAIGNdEuTWEolCyfgUUSBnOpy6duLCJAafqlflsvYlNq KW3PjuXgCOhDRhkydqBFNjrTz/7OxQ/WGNlDaKSGDt7RD0EYbHaMidi6KEKKBkyM3jcv TIow== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679146981; 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=E0XeXPX2/QylKLRdd6i4bG6Le8L9OMICgwdZeIeJeOhj5MWuiRg8MVFlcw3+cbtgp3 fNrdyKkYmnUfBjW9aFI9qFREtPhRK4TsM3HCScEUlOxHa9ToYlTfNShCA/57JAUyy4il Ohhe3gBRfaw3XlWognzyXJfc/TM/khqPolZmvXYxX/vYwcNFcq2X1188qsT7f8af/A3L yx52bse6jS9v8flF91P4sINl7uXvNTqkklxai3fegSkP1mbluNWt6ZX1qHP3ozjf/0D4 MUP2odGdsSGdo47ZoCqbVifxMEVwnJO1FxSGaVRAo3kMYD5R27lq8vPA6pNSfHSuLmS1 Tm/A== X-Gm-Message-State: AO0yUKU1wLE0HDXVKG7L8KviXr3MuWO7H/YJP+VXlSeROqhhKSz1iEY3 hmd4JQhol5M0saFnTHElw8l6LPE14BpvVpVD+m8= X-Received: by 2002:a05:6512:68:b0:4dd:a0f6:8f3b with SMTP id i8-20020a056512006800b004dda0f68f3bmr4918976lfo.15.1679146981212; Sat, 18 Mar 2023 06:43:01 -0700 (PDT) Received: from [192.168.1.101] (abym238.neoplus.adsl.tpnet.pl. [83.9.32.238]) by smtp.gmail.com with ESMTPSA id c2-20020a2e9d82000000b0029a0b50a34asm888367ljj.36.2023.03.18.06.42.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 18 Mar 2023 06:43:00 -0700 (PDT) From: Konrad Dybcio Date: Sat, 18 Mar 2023 14:42:51 +0100 Subject: [PATCH v6 5/9] drm/msm/dsi: dsi_cfg: Merge SC7180 config into SDM845 MIME-Version: 1.0 Message-Id: <20230307-topic-dsi_qcm-v6-5-70e13b1214fa@linaro.org> References: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@linaro.org> In-Reply-To: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@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=1679146971; l=2206; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=+ePdH/Gl1hrkxIW7hm63Vg7SPtBJUhhLLi5EVaR0ltI=; b=w5Qh/YigwR8zbCdmDXGOkZlPU3gF9O6EA79QXQ5pTEeLd1VBTvHZNJbYrKDsfGCO2AS16d1bFlvD uVp8tqA5CgXbiLvyhr8IITU9ATLjE8GSafvPJ5cCcflMzSIQK9/y X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable 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?1760713873711094986?= X-GMAIL-MSGID: =?utf-8?q?1760713873711094986?= 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, From patchwork Sat Mar 18 13:42:52 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 71604 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:604a:0:0:0:0:0 with SMTP id j10csp299077wrt; Sat, 18 Mar 2023 06:54:01 -0700 (PDT) X-Google-Smtp-Source: AK7set9yrlEd9rh/sdrDEmc/d+CaolG6v58UT2OgP1VVAyxZXxFwmYu9TVcvQJWwNPX+PmIiZvIV X-Received: by 2002:a17:90b:1bc4:b0:23b:bd09:7f0b with SMTP id oa4-20020a17090b1bc400b0023bbd097f0bmr12065010pjb.30.1679147641369; Sat, 18 Mar 2023 06:54:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679147641; cv=none; d=google.com; s=arc-20160816; b=E7PT0pcGVslefEwkEesEuLWiXOM1lMWc04rI2a5bDgFG6HJURtCARG82B4kKyak135 9sjwyum6xPPWBVB5y8SuW0H+aVhPv0dpO0bEkryFYe/ipIh5tYNT9XjbZXExct+LdXmk pepZq4hC0fxNvVr3dyidPx1C/jjfuxN35wNu0shrcFmkyQO525rMbPEcBOd8QG/iS79y wK4fgE2I+mJK67UttH5d5nnEe7J7fhCuq73TbDgF4Ke0biLWVgQsYlr6XuzX2YESbkMS ylrSO5uIUxo0wOSnUng0xuawQ/TI1fxu2GHo5H8SLNYTkzVy18zq/jJyrv+LU07+Jq/k A5TA== 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=4ybpWSBp4lClKqhK/g5tZCNekBaDds3KID0LOYjNmjg=; b=aIbPombbDxmyRDTywJgWjOf1CZd4cWgNaES0ktW/3I3r6rD32iaF3s/RdY4LvliL7v XsHoffXoUtRH5aQeE0v2fd5UNqDge/UjKeimL2aXcBMCK19gSu1UdYdtCIHZuV6mbX/1 peIdEZDGKl+LLYjmgGou7dTRhykYinUBQhlsjMke865suIxDDZQm/iQAsofMKcl9db+i 9eNmjhjuQ7K9XBNI9zLdI2DTsHv9LMFNAV4f4S+NVAM4LqUqAbIy4slevw2fVSFE+Ke+ v/rdr65cqJ4oQRvrWPWEDVL27iHdJkmTH19tuetFIavUI8wBUofwFzxAsEMGpaqKouIJ 5apg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=wqtSFUFV; 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 u19-20020a632353000000b00502f60c6809si5229939pgm.358.2023.03.18.06.53.46; Sat, 18 Mar 2023 06:54:01 -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=wqtSFUFV; 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 S229904AbjCRNnR (ORCPT + 99 others); Sat, 18 Mar 2023 09:43:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34676 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229816AbjCRNnI (ORCPT ); Sat, 18 Mar 2023 09:43:08 -0400 Received: from mail-lj1-x22a.google.com (mail-lj1-x22a.google.com [IPv6:2a00:1450:4864:20::22a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2A64333CDB for ; Sat, 18 Mar 2023 06:43:03 -0700 (PDT) Received: by mail-lj1-x22a.google.com with SMTP id z42so7764944ljq.13 for ; Sat, 18 Mar 2023 06:43:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1679146982; 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=4ybpWSBp4lClKqhK/g5tZCNekBaDds3KID0LOYjNmjg=; b=wqtSFUFVe/xqQiyDgL02mrMIhKD9j3mvK3IMDaZT8NgtIad7uKJJJkPKJcNePc7zov papqa6Qe/Kmi6OW/nMwuPx31WMjgWPcbtPdd2xZTPLmfhugWHXncyIZK0x0/NkAqS6j2 oPzRd1Iw1WeR5enLKJxhQK5Wuz1M84u1MBjvOMdDGzkzZhoVhcpZd4tMUuebP8/vKgv0 J1m6+r9QY91Yk7GR98stE9vmz2rFIYUZxE7uLrKi+l2e6KA1YcElDyQ06rlfU03dWyQo 58XTu8umRnOxy55H3oVR/GZkPnpqLxkmeAmtrgtVhYYjwleHxusdPqsZT1UhEsq5YCaX 9zsg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679146982; 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=4ybpWSBp4lClKqhK/g5tZCNekBaDds3KID0LOYjNmjg=; b=UFiH61XjhXw8CryMbvitSrdM4sEZLP0JyOht78Cl+2/g+SF+kDUXkmTsJuo+eH+o7E mmYbyfanZ/5Ar9TtQp37vfBuRh+zXqCtsrjEuPPh+IQl+YQQmCN17O+tE4zK0BZv3G7P QXVyRmiynkOsV9VI2x5DRBCKEmAZzsr0OZhaXk5loa3WgXrO4zHQAeb0T30Kt+AVnUT3 RfDG4tOkiyIiJHNjU+hYxMnDmUX39yN3g+ND7tea4syRUX9rMXrfqKwquFnRO44JpcQY eQanJesVSw36NvuNHYaIRCeEA3d7xR+tENz0Miq6R6dC8gHAXqDq9v/yIllOCzOXdWCF mSAg== X-Gm-Message-State: AO0yUKVubA46L9AQvwZ9X38o5vnbOGjAdo75gSgLBEG+Sa/1iexsDqWd U5PLTSNuAXWxyMP3GKhjnqrnug== X-Received: by 2002:a2e:be85:0:b0:298:a7c4:f838 with SMTP id a5-20020a2ebe85000000b00298a7c4f838mr6668341ljr.25.1679146982761; Sat, 18 Mar 2023 06:43:02 -0700 (PDT) Received: from [192.168.1.101] (abym238.neoplus.adsl.tpnet.pl. [83.9.32.238]) by smtp.gmail.com with ESMTPSA id c2-20020a2e9d82000000b0029a0b50a34asm888367ljj.36.2023.03.18.06.43.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 18 Mar 2023 06:43:02 -0700 (PDT) From: Konrad Dybcio Date: Sat, 18 Mar 2023 14:42:52 +0100 Subject: [PATCH v6 6/9] drm/msm/dsi: Switch the QCM2290-specific compatible to index autodetection MIME-Version: 1.0 Message-Id: <20230307-topic-dsi_qcm-v6-6-70e13b1214fa@linaro.org> References: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@linaro.org> In-Reply-To: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@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=1679146971; l=3233; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=e/ZDvN1pmXEVddNSmMJ2iSlA9sSO8FBakW2FjAcs2pg=; b=V6Mrw47+2xiejKuA4uajLkdylpMy4cmo+WOXWJZ/4BliI+KHPvZtBJ0Vkpgzr6xBJ34wctaW+Dq4 s4DT+DkuBDHmrFTQtyimBbnhBxb+LvZdkB5AmljaE4Xw0F8T0BJ9 X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham 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?1760713917689886405?= X-GMAIL-MSGID: =?utf-8?q?1760713917689886405?= Now that the logic can handle multiple sets of registers, move the QCM2290 to the common logic and mark it deprecated. This allows us to remove a couple of structs, saving some memory. Reviewed-by: Dmitry Baryshkov Reviewed-by: Marijn Suijten Signed-off-by: Konrad Dybcio --- drivers/gpu/drm/msm/dsi/dsi.c | 5 +++-- drivers/gpu/drm/msm/dsi/dsi_cfg.c | 20 ++------------------ drivers/gpu/drm/msm/dsi/dsi_cfg.h | 3 --- 3 files changed, 5 insertions(+), 23 deletions(-) diff --git a/drivers/gpu/drm/msm/dsi/dsi.c b/drivers/gpu/drm/msm/dsi/dsi.c index 31fdee2052be..f761973e4cba 100644 --- a/drivers/gpu/drm/msm/dsi/dsi.c +++ b/drivers/gpu/drm/msm/dsi/dsi.c @@ -4,7 +4,6 @@ */ #include "dsi.h" -#include "dsi_cfg.h" bool msm_dsi_is_cmd_mode(struct msm_dsi *msm_dsi) { @@ -174,7 +173,9 @@ static int dsi_dev_remove(struct platform_device *pdev) static const struct of_device_id dt_match[] = { { .compatible = "qcom,mdss-dsi-ctrl", .data = NULL /* autodetect cfg */ }, - { .compatible = "qcom,dsi-ctrl-6g-qcm2290", .data = &qcm2290_dsi_cfg_handler }, + + /* Deprecated, don't use */ + { .compatible = "qcom,dsi-ctrl-6g-qcm2290", .data = NULL }, {} }; diff --git a/drivers/gpu/drm/msm/dsi/dsi_cfg.c b/drivers/gpu/drm/msm/dsi/dsi_cfg.c index 03d98cbcc978..29ccd755cc2e 100644 --- a/drivers/gpu/drm/msm/dsi/dsi_cfg.c +++ b/drivers/gpu/drm/msm/dsi/dsi_cfg.c @@ -169,7 +169,8 @@ 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 }, /* SDM845 / SDM670 / SC7180 */ + { 0xae94000, 0xae96000 }, /* SDM845 / SDM670 */ + { 0x5e94000 }, /* QCM2290 / SM6115 / SM6125 / SM6375 */ }, }; @@ -203,17 +204,6 @@ static const struct msm_dsi_config sc7280_dsi_cfg = { }, }; -static const struct msm_dsi_config qcm2290_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 = { - { 0x5e94000 }, - }, -}; - static const struct msm_dsi_host_cfg_ops msm_dsi_v2_host_ops = { .link_clk_set_rate = dsi_link_clk_set_rate_v2, .link_clk_enable = dsi_link_clk_enable_v2, @@ -304,9 +294,3 @@ const struct msm_dsi_cfg_handler *msm_dsi_cfg_get(u32 major, u32 minor) return cfg_hnd; } - -/* Non autodetect configs */ -const struct msm_dsi_cfg_handler qcm2290_dsi_cfg_handler = { - .cfg = &qcm2290_dsi_cfg, - .ops = &msm_dsi_6g_v2_host_ops, -}; diff --git a/drivers/gpu/drm/msm/dsi/dsi_cfg.h b/drivers/gpu/drm/msm/dsi/dsi_cfg.h index 8772a3631ac1..91bdaf50bb1a 100644 --- a/drivers/gpu/drm/msm/dsi/dsi_cfg.h +++ b/drivers/gpu/drm/msm/dsi/dsi_cfg.h @@ -65,8 +65,5 @@ struct msm_dsi_cfg_handler { const struct msm_dsi_cfg_handler *msm_dsi_cfg_get(u32 major, u32 minor); -/* Non autodetect configs */ -extern const struct msm_dsi_cfg_handler qcm2290_dsi_cfg_handler; - #endif /* __MSM_DSI_CFG_H__ */ From patchwork Sat Mar 18 13:42:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 71600 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:604a:0:0:0:0:0 with SMTP id j10csp297598wrt; Sat, 18 Mar 2023 06:49:44 -0700 (PDT) X-Google-Smtp-Source: AK7set/iypFKge3qSYKPav5+gQwqTFS3h6UqZ8x36Qsm6JQwclI0ZlyIzHZNh8rp2cja/BeCv6Uw X-Received: by 2002:a17:902:ec87:b0:1a1:a06c:48a5 with SMTP id x7-20020a170902ec8700b001a1a06c48a5mr10418396plg.33.1679147383775; Sat, 18 Mar 2023 06:49:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679147383; cv=none; d=google.com; s=arc-20160816; b=XK4DZ+hqgjsrz/HG+gxkFJFGxmgAh3CnMEJ5VaGaBFiyPVN/BBooiD78GxxV61KTuC Wj14fBa6K0m4R6NA7EKbTn5qwIuAHZe6ahSjytGaIK2dvzf94Wzyfv8x8SBzz2u1qUM3 TadVZ5VoIs+NvkH5qAeoHbjiDEtO07SAh4c02XFWyCwk1P4K6mUgKsPT/HxUDEv7+tUw GGydKwfponvhMJTeXSfrbLtIq9MIL5Eqss4dmqpRXukcE2NG+e/ziNTjr67Xx9Uvqy8k Lc3nRIltMX0+WqPB0DYJh2vb3KtQJUgRNDJ1DrbMT8CpLpmJ/huvSMZIIQzA7il09kjr 7WfA== 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=Vhpul7Rh3cRj+K0GuudZQvoFoP/xfXO3CkdZI/yylms=; b=Np72ZZCAQ8WAyqM3/7QZ2X/bhPw5hb3Ov31v1/tLPuOA+5QFn2bY7Q1KCdQpUvZdCm SuTQQ4VxYJKM53bjGL885mEnL8ff8z9L3xG/0TTWFddTghOEKC2tBVdyqQnPeWqLPw4A hMQZpPdRR3hTv+3PTwX242v5VIAmBDS8NZfxfGSD8y22mvECn3M+LuY8qz7XlZOfxQMF ype+TPKS/D368NAASWltQ1IUC8LB9hJG0SUnuMl4Yq4R/DUFmEPFTz3EqiFxKO4y0bly rHLoculHdzi/gHY/oRBDbEVkuypalHAJusQdIX5ZyrwtEvnDWtLRiBdi95Sd4MpZO/w3 MYeg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=j426X71m; 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 e17-20020a17090301d100b001a05a44093csi5945851plh.58.2023.03.18.06.49.29; Sat, 18 Mar 2023 06:49:43 -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=j426X71m; 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 S229960AbjCRNnY (ORCPT + 99 others); Sat, 18 Mar 2023 09:43:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34594 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229868AbjCRNnL (ORCPT ); Sat, 18 Mar 2023 09:43:11 -0400 Received: from mail-lj1-x234.google.com (mail-lj1-x234.google.com [IPv6:2a00:1450:4864:20::234]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 72A9732CEC for ; Sat, 18 Mar 2023 06:43:06 -0700 (PDT) Received: by mail-lj1-x234.google.com with SMTP id by8so6586663ljb.12 for ; Sat, 18 Mar 2023 06:43:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1679146984; 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=Vhpul7Rh3cRj+K0GuudZQvoFoP/xfXO3CkdZI/yylms=; b=j426X71mabGLe1BqLKd75IEf3x1OwnMZApw94sSoRjI9PIBDOgl5mmVj97uwADtRIo dPQ35g3OJujaMQjQn7viOa6Q7fmpMnQ/y5NCKb3hLvNau9VWW993qWBwOUW89sRwWHTB RrQQ/mhy3s7dFVDtwZap3HhE8vNBSXT72A3Y83fC026lvBC4bg3+0owmbu3Njq9nWxy7 oa3wwhpAO6vi9u2HQ0NWCRRlydJOKZTTYJ5UyqV5YvtAQIrDrAid7V4U2aonZQlZRE7I qZemPNvc/UJ3Ghjgfsa73cPc1ni3yCKnhp+/HHHAdVb4vHCtrBcIP8or9yXx0OdCkHCJ Idgg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679146984; 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=Vhpul7Rh3cRj+K0GuudZQvoFoP/xfXO3CkdZI/yylms=; b=cOSmgU9/SDRSaxPd10I2/RTCBwoK8TseeHmzabdXe653YIjxL/cclzfBdjtxi+AP2i OvBmhVTDClvQyo1+hyTWjfLefqkYUmm6m9z9W2OVSqmg1il/Y38CFxzAsnjM5uiuu3wd 3KuvK6fgdA/o6kxK8PgVTWBDca0Z4HLijz6E/Sn3pb9yD8dJELtjXV7PLR0KbkJS7pYh c8Tzd5zOg8f9VtIy0VmO+qoMwCYK4aw6dWtxQlAPoyc4SBVl8wb2Kh/IxjNU/wUkSF2t CLY++UC4Ty+ELj5AxiPbgG63FY4Ow//7BP4U1GkduhBtSThoRyFOihM/f5szi2T7bL3B DWzg== X-Gm-Message-State: AO0yUKXtiDmQx8gK4Jy6NDBrrdkCzYjoDQmqXz9+9CeOf5x47aPbvYfi k1h/x/6LTOq10v6GW0PC/wKKp5gbqeS7Bl9PxDk= X-Received: by 2002:a2e:9f44:0:b0:29b:767f:1421 with SMTP id v4-20020a2e9f44000000b0029b767f1421mr686870ljk.45.1679146984292; Sat, 18 Mar 2023 06:43:04 -0700 (PDT) Received: from [192.168.1.101] (abym238.neoplus.adsl.tpnet.pl. [83.9.32.238]) by smtp.gmail.com with ESMTPSA id c2-20020a2e9d82000000b0029a0b50a34asm888367ljj.36.2023.03.18.06.43.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 18 Mar 2023 06:43:03 -0700 (PDT) From: Konrad Dybcio Date: Sat, 18 Mar 2023 14:42:53 +0100 Subject: [PATCH v6 7/9] drm/msm/dsi: Remove custom DSI config handling MIME-Version: 1.0 Message-Id: <20230307-topic-dsi_qcm-v6-7-70e13b1214fa@linaro.org> References: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@linaro.org> In-Reply-To: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@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=1679146971; l=1730; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=F4fPirOHyMQPj35ost0pdi8esBWoDrjWNUljpExX+4U=; b=JQL4C8eZU9KdW70xgkVjmI9WYhpJRT9iemBV2gYY5kx+UgSGZNBtZXViYaamh9bBOeacUVPvECKx Hx3zj/elBCkSn/QqsBsTWvU8RPfp3CbFyjYsorJTAB5uakOYwph8 X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable 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?1760713646944083729?= X-GMAIL-MSGID: =?utf-8?q?1760713646944083729?= Now that the only user is handled by common code, remove the option to specify custom handlers through match data. This is effectively a revert of commit: 5ae15e76271 ("drm/msm/dsi: Allow to specify dsi config as pdata") Reviewed-by: Dmitry Baryshkov Reviewed-by: Marijn Suijten Signed-off-by: Konrad Dybcio --- drivers/gpu/drm/msm/dsi/dsi.c | 4 ++-- drivers/gpu/drm/msm/dsi/dsi_host.c | 4 ---- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/drivers/gpu/drm/msm/dsi/dsi.c b/drivers/gpu/drm/msm/dsi/dsi.c index f761973e4cba..baab79ab6e74 100644 --- a/drivers/gpu/drm/msm/dsi/dsi.c +++ b/drivers/gpu/drm/msm/dsi/dsi.c @@ -172,10 +172,10 @@ static int dsi_dev_remove(struct platform_device *pdev) } static const struct of_device_id dt_match[] = { - { .compatible = "qcom,mdss-dsi-ctrl", .data = NULL /* autodetect cfg */ }, + { .compatible = "qcom,mdss-dsi-ctrl" }, /* Deprecated, don't use */ - { .compatible = "qcom,dsi-ctrl-6g-qcm2290", .data = NULL }, + { .compatible = "qcom,dsi-ctrl-6g-qcm2290" }, {} }; diff --git a/drivers/gpu/drm/msm/dsi/dsi_host.c b/drivers/gpu/drm/msm/dsi/dsi_host.c index 9cfb9e91bfea..961689a255c4 100644 --- a/drivers/gpu/drm/msm/dsi/dsi_host.c +++ b/drivers/gpu/drm/msm/dsi/dsi_host.c @@ -214,10 +214,6 @@ static const struct msm_dsi_cfg_handler *dsi_get_config( int ret; u32 major = 0, minor = 0; - cfg_hnd = device_get_match_data(dev); - if (cfg_hnd) - return cfg_hnd; - ahb_clk = msm_clk_get(msm_host->pdev, "iface"); if (IS_ERR(ahb_clk)) { pr_err("%s: cannot get interface clock\n", __func__); From patchwork Sat Mar 18 13:42:54 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 71605 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:604a:0:0:0:0:0 with SMTP id j10csp299079wrt; Sat, 18 Mar 2023 06:54:01 -0700 (PDT) X-Google-Smtp-Source: AK7set95fdW9woOBHIxDquXnV/RC3s8paKInKp6OsSXIaZbqyOhFp/0YhMil44mdGANbRecH7ULV X-Received: by 2002:a17:90a:51:b0:23b:2f4a:57bb with SMTP id 17-20020a17090a005100b0023b2f4a57bbmr12335025pjb.10.1679147641476; Sat, 18 Mar 2023 06:54:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679147641; cv=none; d=google.com; s=arc-20160816; b=RKAO/1ZDKnkX4joENhcrgxZ1Td5p9f8RAeyIvMEv3MIjjfxNQWcdHkCZvJ2ohu5lmi 2FoHX6GBTmWEBCtw0Hub27DgKHOLFf05hdvDfGlIiw6g/w8+prXYp4sMiP92W7gJ988G DewtXxisUf62Wbln7miVGPfDAxLBxTuYVDB0ylg1TYJqRLDbqbPDKXxn8P5Tng7sX2J+ qNCECDIzx5HGxyg0aegUdk5eiHajFAR9sKulIzcSoEJ1TyP2WglskhV56BNqbiiun2+r 2G7X2Vg5XGsRBDw9xdXJ5vDM/bOpx9ph4JlUgqX8diB2JpbKQAmYRxwdKKlGhziu8CGL TGeQ== 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=U+jIZB+lOj7L713dwYSMYXhpa9ZO/qMAXKk3i/Uz2ak=; b=aqr3bOKAtEhzuV4xO9box/3BDZ43j9+QoITNawsx7x429LpqS+72kNkUMa8vBZd1fN 3kc+Y5/b4uP9ZIVfiFImMqY9Y/2S+8n9r0heEXerR/5U3Qmoke0FEEZPuGBBk/+pk81t 2p3mYFdngxV+ltI4iCIJKCmhIchuN8nrURbkUT7/5f8BmEQ1LKK29vN/wSMnixZBzvMy H3uWaPCAxV+F5MsLNHdEq5bAoGs+CVFFCDkpXJ/FPKRvIO6GDP2zYYL8VFyqP5iaS+We RxrYifCjtB7uDXZFj3DfzvYsWx2UA8ffKgS/5yX1Mq2cqc6JXoJY51Q8BTOWP/FJUQ9J fIzA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=FzWZrHP1; 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 c5-20020a6566c5000000b0050c10b43533si4592899pgw.60.2023.03.18.06.53.46; Sat, 18 Mar 2023 06:54:01 -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=FzWZrHP1; 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 S229924AbjCRNnk (ORCPT + 99 others); Sat, 18 Mar 2023 09:43:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35276 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229913AbjCRNnS (ORCPT ); Sat, 18 Mar 2023 09:43:18 -0400 Received: from mail-lf1-x12b.google.com (mail-lf1-x12b.google.com [IPv6:2a00:1450:4864:20::12b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2FCAE32CCC for ; Sat, 18 Mar 2023 06:43:08 -0700 (PDT) Received: by mail-lf1-x12b.google.com with SMTP id f18so9769576lfa.3 for ; Sat, 18 Mar 2023 06:43:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1679146986; 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=U+jIZB+lOj7L713dwYSMYXhpa9ZO/qMAXKk3i/Uz2ak=; b=FzWZrHP16xKM/suGeskGqhufuiGNrR+wjzdZUs2SRtC9Sn2k3/kRWqsRrv32g1VTTB SW1uYciJCL1aDUBl3hdgBl4qPS6woupjb/jjFDDO0ms9t8TOCvmgGxZRG4Lalb2XCVSj toQ9ndNWqqu/PsPDeHEJYod0QjUP2jz2Zhu2x0o42nU9V1cU6j3pL5xMv3Dzub0SHHwe K0brJpS4DaRA8wEO8n57+XamMquBtcDSEaaG9O3SkOIwJo0hXFHDU7VPXxXEA7GDecaI tYIDqgZIBVMwJA8991R3UynxsA62Ge130WDC3S0yv9hwILh7AdbUSxuGAJTCpuJq/Hko BUgw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679146986; 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=U+jIZB+lOj7L713dwYSMYXhpa9ZO/qMAXKk3i/Uz2ak=; b=OblqkR5kZCL3iaAUM1EC2eAjNCBd8jLs7h4hk+mo1jrZtySv4ji+jH7UYldVavq+FA UFRuPeWWMv+JF3mX4l3TtYXMTEhEARrbFzFqHBqTmSz9QM03HnQtHvZopifI9rvwrtJD XC038YlUYJ5BWiHPThQH9bYw94NQpkE8lpOY71WlF2CZ7tO3oOFbOWNMxvzcH4IpH+TS NHLhGtcPmgFHSdpo2+xM/FTCKFFHAgfAdDS1/CuvgEmn7CUtgk+gRHPWGyxLtMAokkoy mFBTfnkEtbFJ0cI2dLp5NbFtE5PbvPTlMEYvOUClo4nEmPg+JW129FAtGrm2s2KmN7gV epXA== X-Gm-Message-State: AO0yUKXCgqla1PGukg/1pr2hr2/UdRkCd0C8koGsk65TSuErBt/PPM6z RL5nnd93P/chG/tdwF6ErOJaEg== X-Received: by 2002:ac2:5deb:0:b0:4dc:81a3:c095 with SMTP id z11-20020ac25deb000000b004dc81a3c095mr5463529lfq.38.1679146985862; Sat, 18 Mar 2023 06:43:05 -0700 (PDT) Received: from [192.168.1.101] (abym238.neoplus.adsl.tpnet.pl. [83.9.32.238]) by smtp.gmail.com with ESMTPSA id c2-20020a2e9d82000000b0029a0b50a34asm888367ljj.36.2023.03.18.06.43.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 18 Mar 2023 06:43:05 -0700 (PDT) From: Konrad Dybcio Date: Sat, 18 Mar 2023 14:42:54 +0100 Subject: [PATCH v6 8/9] dt-bindings: display/msm: dsi-controller-main: Add SM6115 MIME-Version: 1.0 Message-Id: <20230307-topic-dsi_qcm-v6-8-70e13b1214fa@linaro.org> References: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@linaro.org> In-Reply-To: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@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=1679146971; l=2355; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=TH3q3Ed2aw6dX9xtVNq6VpDwcDDpJoS9emOd9LF1Zus=; b=IEzuk0TI7uwZ53rvy74C1k+EIg8nf+j85wwtz+eHnVKNv9VaL+M4qtd5rZNbcp2H8mBdNFMZytxd 4nwFN9n7A8b1HfuGX6eiPEKz2RT7s9x6z1fwf5FdJ5ss5B6lElud X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham 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?1760713917246988457?= X-GMAIL-MSGID: =?utf-8?q?1760713917246988457?= Add a compatible for the DSI on SM6115. Acked-by: Rob Herring Reviewed-by: Marijn Suijten Signed-off-by: Konrad Dybcio Reviewed-by: Krzysztof Kozlowski --- .../devicetree/bindings/display/msm/dsi-controller-main.yaml | 2 ++ .../devicetree/bindings/display/msm/qcom,sm6115-mdss.yaml | 10 ++++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml index ecc89011bec4..c8884a84e73d 100644 --- a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml +++ b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml @@ -25,6 +25,7 @@ properties: - qcom,sc7280-dsi-ctrl - qcom,sdm660-dsi-ctrl - qcom,sdm845-dsi-ctrl + - qcom,sm6115-dsi-ctrl - qcom,sm8150-dsi-ctrl - qcom,sm8250-dsi-ctrl - qcom,sm8350-dsi-ctrl @@ -350,6 +351,7 @@ allOf: contains: enum: - qcom,sdm845-dsi-ctrl + - qcom,sm6115-dsi-ctrl then: properties: clocks: diff --git a/Documentation/devicetree/bindings/display/msm/qcom,sm6115-mdss.yaml b/Documentation/devicetree/bindings/display/msm/qcom,sm6115-mdss.yaml index 2491cb100b33..b9f83088f370 100644 --- a/Documentation/devicetree/bindings/display/msm/qcom,sm6115-mdss.yaml +++ b/Documentation/devicetree/bindings/display/msm/qcom,sm6115-mdss.yaml @@ -40,7 +40,13 @@ patternProperties: type: object properties: compatible: - const: qcom,dsi-ctrl-6g-qcm2290 + oneOf: + - items: + - const: qcom,sm6115-dsi-ctrl + - const: qcom,mdss-dsi-ctrl + - description: Old binding, please don't use + deprecated: true + const: qcom,dsi-ctrl-6g-qcm2290 "^phy@[0-9a-f]+$": type: object @@ -114,7 +120,7 @@ examples: }; dsi@5e94000 { - compatible = "qcom,dsi-ctrl-6g-qcm2290"; + compatible = "qcom,sm6115-dsi-ctrl", "qcom,mdss-dsi-ctrl"; reg = <0x05e94000 0x400>; reg-names = "dsi_ctrl"; From patchwork Sat Mar 18 13:42:55 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 71596 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:604a:0:0:0:0:0 with SMTP id j10csp295954wrt; Sat, 18 Mar 2023 06:45:04 -0700 (PDT) X-Google-Smtp-Source: AK7set8qQvy2o+6o5KXqQlTAP+sN8IZtxKPzvOZRaD3wEdvjFpG02/dSjDB+bCq3ecG2FRV5pyqX X-Received: by 2002:a17:902:ecc7:b0:19e:2fb0:a5d9 with SMTP id a7-20020a170902ecc700b0019e2fb0a5d9mr6824262plh.32.1679147104050; Sat, 18 Mar 2023 06:45:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679147104; cv=none; d=google.com; s=arc-20160816; b=H0kA7LKwM9CTAhyFMKK40v2BdPzUVRPk6GdEntRByrunRjKlqbOjKF582KajZVVC3z ZyEAGcGOgGBNUZI8dT45fKMenoD4krubyO01yrbezlX20JCNJMhlOvqmIB2lYZDTmVH8 vl/WghupdaeEFk5hashDACnxCMbbimmTYC+j3iiMux5B84rs2DLEfdoQnG511s9VhLVB 8wWT4d8yev9ftUqVMTy62era3OWiTqM4I2MwM57zQoGh/S6j6vSgxA8Pxldd6vG4v0nW PXXHvATpWvRlsLPauKscZLPZyMNHJvSOwNwlw6O24fehzTgtOE3IFWncKrc5txo2KfnR /mzA== 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=CSwnb94Mzw2MbHXtm3N1Had+b6g5bP1qhG7RvTv6VYM=; b=kthNg6/EW6Zw7LrIv48KpFlYd1cSbYz0cs6x8qZLJ+NP/Wfac26RqM7iO4J5ezfeL9 rI+g2gbbn2DBYsOZF/jjwR+/1UMRk5D9eBcOiVom0DEz33bh7AsyQEEBR+Ua107KmWNN eCETBIgvo/ZtbVkuG0P6VLLOcAGCToT9V20WTBFh2n+EahmAr79Bx8sRWa8S9iIkLfvU CSDOGcnn76UwNMlO+OWflQjd56dBVTWSOSk7sE8GBaADOIAfrDfLLpu2h28JzZdALSSv ZHLvhlzlNc0yiH8RUcriBMjyjdXCvt0NX19o56inJCiGdw4+fWTzI59s30npPJf0jyKl z3eA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=mp00Cxlp; 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 j70-20020a638b49000000b0050c0c9d2916si5297600pge.870.2023.03.18.06.44.49; Sat, 18 Mar 2023 06:45:04 -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=mp00Cxlp; 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 S229842AbjCRNn2 (ORCPT + 99 others); Sat, 18 Mar 2023 09:43:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34692 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229826AbjCRNnM (ORCPT ); Sat, 18 Mar 2023 09:43:12 -0400 Received: from mail-lj1-x232.google.com (mail-lj1-x232.google.com [IPv6:2a00:1450:4864:20::232]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F26C832E55 for ; Sat, 18 Mar 2023 06:43:07 -0700 (PDT) Received: by mail-lj1-x232.google.com with SMTP id h9so7815084ljq.2 for ; Sat, 18 Mar 2023 06:43:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1679146987; 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=CSwnb94Mzw2MbHXtm3N1Had+b6g5bP1qhG7RvTv6VYM=; b=mp00CxlpC+bkTh9hYBnVlOXwYPkqGR9yuB8P+OvNJKo3xvEtWKUwHs4IbXFw2sX6la ToDNU237KBDMj6KmaIqeO9aslzfGjZ3LTNbygp4AfmbnKSJYP/59Li1NnlMKaVDCoN6o yuMqdUS24LTw5dsubgBUbhxgsjGZrBVBOnl+4JrLZevj8jTlfGpLWf68jaxhK9ZFWUpV 45M2iXZ+O7ra0hU/QFhKImpMFaivn7c/Hvn2oIBOTv0aSIszNwPWp4smKIJyL2v4XgEb eSWP3IULXLWZR9w2Rn9g/1ZhGCgkVuwZZMGGvzkrxGKGHiGtho0t6wiTdjt9lJ0zoJM1 QHfw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1679146987; 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=CSwnb94Mzw2MbHXtm3N1Had+b6g5bP1qhG7RvTv6VYM=; b=hAPPtPcGZMwyW14EeMEngjFDGH17OoHnqaoDBzVwD5zVLnE+dP47a8guRZREw/pRXn bXWlmzGe4ypeRFRsPDL9W21omf7sKLfIB+pC1JyzAkXTTXcVxNYEp+eLJMlgLYrt4LIW dHnruCnmBi6tiUZfOYyAWEgJygoXeCOijkHGNezK3dMMcN6sETt4bLS5gMHndLhGm1Fk NlfA0QxeT8lTq2pTMiY52zmb9ofssu9Bxl1t7ZLIiCoVofZ0Gl2yEgFz18dsLR161nTa dov77Nu+pIMkjc2xH2tQosXMszxmsu78whgOJNa+ghCs1ez6jhXMIVaf+pE9DTnaxify gyGg== X-Gm-Message-State: AO0yUKXR9zJWBSh1uu0bCIaBynhP/DZ7nlC4ZWhsfyi0/6lPeKcL2ruI YnHwDHXg6rLLip5y4k/EChd+5A== X-Received: by 2002:a05:651c:1a0a:b0:298:aada:99a4 with SMTP id by10-20020a05651c1a0a00b00298aada99a4mr5427625ljb.15.1679146987411; Sat, 18 Mar 2023 06:43:07 -0700 (PDT) Received: from [192.168.1.101] (abym238.neoplus.adsl.tpnet.pl. [83.9.32.238]) by smtp.gmail.com with ESMTPSA id c2-20020a2e9d82000000b0029a0b50a34asm888367ljj.36.2023.03.18.06.43.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 18 Mar 2023 06:43:07 -0700 (PDT) From: Konrad Dybcio Date: Sat, 18 Mar 2023 14:42:55 +0100 Subject: [PATCH v6 9/9] arm64: dts: qcom: sm6115: Use the correct DSI compatible MIME-Version: 1.0 Message-Id: <20230307-topic-dsi_qcm-v6-9-70e13b1214fa@linaro.org> References: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@linaro.org> In-Reply-To: <20230307-topic-dsi_qcm-v6-0-70e13b1214fa@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=1679146971; l=835; i=konrad.dybcio@linaro.org; s=20230215; h=from:subject:message-id; bh=TG72yG+FHoBCa8HzTOP2m4Zz/u5EM4iUM34Xg+mUMPo=; b=bzqbSxqJTBt3yGqTr/I3zYIXTWAXpQidX0CBQfgCGzZ+rFCB5HSPDbOq402ijR1rZFTBnYyMjPUz RjARwgnNAENPj7dkUeSVXV4dYPX1hCJeWkZ7aO/8yBaQyyXt59GZ X-Developer-Key: i=konrad.dybcio@linaro.org; a=ed25519; pk=iclgkYvtl2w05SSXO5EjjSYlhFKsJ+5OSZBjOkQuEms= X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham 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?1760713353905974262?= X-GMAIL-MSGID: =?utf-8?q?1760713353905974262?= Use the non-deprecated, SoC-specific DSI compatible. Reviewed-by: Dmitry Baryshkov Reviewed-by: Marijn Suijten Signed-off-by: Konrad Dybcio --- arch/arm64/boot/dts/qcom/sm6115.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm64/boot/dts/qcom/sm6115.dtsi b/arch/arm64/boot/dts/qcom/sm6115.dtsi index c56738633431..fcf7497e8a15 100644 --- a/arch/arm64/boot/dts/qcom/sm6115.dtsi +++ b/arch/arm64/boot/dts/qcom/sm6115.dtsi @@ -1227,7 +1227,7 @@ opp-384000000 { }; mdss_dsi0: dsi@5e94000 { - compatible = "qcom,dsi-ctrl-6g-qcm2290"; + compatible = "qcom,sm6115-dsi-ctrl", "qcom,mdss-dsi-ctrl"; reg = <0x0 0x05e94000 0x0 0x400>; reg-names = "dsi_ctrl";