From patchwork Tue Dec 13 18:33:00 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 32915 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:e747:0:0:0:0:0 with SMTP id c7csp293595wrn; Tue, 13 Dec 2022 10:34:02 -0800 (PST) X-Google-Smtp-Source: AA0mqf6MhSuHlJp1ioo8hx5twVAXFY0C56oyK147oD41uJYk3Rd6UlbWrab877cFz3WAnr7nYK2M X-Received: by 2002:a17:906:3702:b0:7ad:a797:5bbb with SMTP id d2-20020a170906370200b007ada7975bbbmr16527147ejc.63.1670956442780; Tue, 13 Dec 2022 10:34:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1670956442; cv=none; d=google.com; s=arc-20160816; b=vNe6tEdDKz7mOJSKPkfMSWr5wK6TmatRSK+H+1jRXjJfHOcEasUfhceLkBFLzxnJkQ B5Q0tfmxqPwXr7pcAEfsTcAmUJ0tTZ3+bfYlHSh8jXnXE1e201QcOR+S972w3QFVq1KA o7DLArsyYmDM6/75ePSh3jgxREfVLSWYOwlUbMSLhDpX8TUtJLFHsixJPMEe+8BYUIww HE6KSJ0Or3vHsbc2TQMxeXNjdxyt5liX9Bc4x8ukE4EDrfbJ3Cw+mL8M4dapMfwgl0s2 PRxD4HmZ1BJzapGZUA5PCWIOeaAi16edzCYXrwLx5RATl7GuI+GQQvXcL5QYi0APNzi9 QrUw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=GJ5jI0G4hX1A08XO49d5+/bf9foafrkt0On/sCJEiuI=; b=BEDyMtD1PiNh0WX1diBUnLMGEkLoWkzkr4EyQlDiSlqYIQ1jSgyoeubqPDwcY1Z7El 47jIxVlTjhgmTgFiqn9PUvpfS2b3TFFe/93xB+gbR0hhsiryifsoJXCiTLt2RjFoEz3J 2hXSbtAoHNCZgUONDKLjcRl23dKCpqPAG1AnlMmtPDBqpbR2dN1fdRv/u+GdA6OkR1Bp MymA351FMc+7yHxO3fsnLDnjdbiBxyQbUZacDFw/f70f/9PnF7stgtD4buRYUDIUbs5B UY8xgw0asVM28I0aAlN58anVo8AvJ4aTP3/0CZYYV0kyQ/aQR8Fvlj0QLWpkMifvjB0N o7Sw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=NfSwsj6X; 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 a13-20020a170906684d00b007add150c78asi6727392ejs.503.2022.12.13.10.33.40; Tue, 13 Dec 2022 10:34:02 -0800 (PST) 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=NfSwsj6X; 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 S236495AbiLMSdR (ORCPT + 99 others); Tue, 13 Dec 2022 13:33:17 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60074 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236398AbiLMSdN (ORCPT ); Tue, 13 Dec 2022 13:33:13 -0500 Received: from mail-lf1-x12f.google.com (mail-lf1-x12f.google.com [IPv6:2a00:1450:4864:20::12f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C10B422BE7 for ; Tue, 13 Dec 2022 10:33:11 -0800 (PST) Received: by mail-lf1-x12f.google.com with SMTP id q6so6327646lfm.10 for ; Tue, 13 Dec 2022 10:33:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=GJ5jI0G4hX1A08XO49d5+/bf9foafrkt0On/sCJEiuI=; b=NfSwsj6XvoFxdC/s4diqxFkK2YNi3BX95XD5jRwysWJvH3h/5IIZ84QEa4LZH6Mqbr 6JIw81N3A94mZD4zT2VhIjKbm1ieNnS+klB525lr7jc5yT4BpboI+nUCAkbaUdS2OpeK 1igp3rHVAzAbwCcL8bZTu3Q07hvB5odntYLjjMZF4Zx0S1b3IjDxqaQake8666uyoDdP TXwoUrZklmyxluTZ9z4gOcWGLDhQgvOFenPo4A3GaT2hwM1keV4mDZM80FoHYG28Ebj6 GU71MghU2XMUGgjGg4qQ+SZkcs6iPwlfuiKUVdLCdHzJ97Mfkd0bWhPCLsvZbaQIylAb qxGA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=GJ5jI0G4hX1A08XO49d5+/bf9foafrkt0On/sCJEiuI=; b=5swPJRZxXVCjDu1H21FDsP/JUcDbwnNh41BuaHcbskc28Q7G094NCajoqKLeo3yg64 rJEtQwUCtHMJkr2YRDGKL/MEUNMCgDZynDLjRrIfwgNrjulKmiKM0Gyj4+HWQL50oiFD DUaOxK2CPtZRk+EF6rpXviSgZXwsyNXEpW8oJ4BUdzFy5XBH/HAzKwQbo6QXGg93DQFT X5XdyUof4VJdjyNHsl3pZ0HgB/BHgpoTjg1bfpezQXb+Ts2GrQfB5Y8JzySHaBDQP6D9 pafpslLOrlOj01opKUS0FWPUroxe2rIIRE4T1SN1rrCgT7bmjrlvs2HVVQF6631yM6zl ZpEw== X-Gm-Message-State: ANoB5plRrW53+O89MWFNkCnPfiVXx5eUHUIoFDMJ2WFbkErKquWrjL7V CAa7scGdcVsu4mHhQ75GheEQkA== X-Received: by 2002:ac2:52b9:0:b0:4b5:83ba:8c55 with SMTP id r25-20020ac252b9000000b004b583ba8c55mr5363905lfm.8.1670956390178; Tue, 13 Dec 2022 10:33:10 -0800 (PST) Received: from localhost.localdomain (abxh44.neoplus.adsl.tpnet.pl. [83.9.1.44]) by smtp.gmail.com with ESMTPSA id t10-20020a056512208a00b004b501497b6fsm465963lfr.148.2022.12.13.10.33.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 13 Dec 2022 10:33:08 -0800 (PST) From: Konrad Dybcio To: linux-arm-msm@vger.kernel.org, andersson@kernel.org, agross@kernel.org, krzysztof.kozlowski@linaro.org Cc: marijn.suijten@somainline.org, Konrad Dybcio , Loic Poulain , Robert Foss , Rob Herring , Krzysztof Kozlowski , linux-i2c@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2 1/6] dt-bindings: i2c: qcom,i2c-cci: Fall back to common compatibles Date: Tue, 13 Dec 2022 19:33:00 +0100 Message-Id: <20221213183305.544644-1-konrad.dybcio@linaro.org> X-Mailer: git-send-email 2.39.0 MIME-Version: 1.0 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 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?1752100324652299170?= X-GMAIL-MSGID: =?utf-8?q?1752124823252252855?= Almost every compatible string in the CCI driver is a duplicate. Adjust the bindings to include a common (first-soc-implementing-vX) compatible to remove the need to keep adding superfluous compatible strings. Signed-off-by: Konrad Dybcio Reviewed-by: Krzysztof Kozlowski --- Changes in v2: - make sure the actual patch contests are tested.. - resolve errors .../devicetree/bindings/i2c/qcom,i2c-cci.yaml | 47 ++++++++++++------- 1 file changed, 30 insertions(+), 17 deletions(-) diff --git a/Documentation/devicetree/bindings/i2c/qcom,i2c-cci.yaml b/Documentation/devicetree/bindings/i2c/qcom,i2c-cci.yaml index cf9f8fda595f..87e414f0c39c 100644 --- a/Documentation/devicetree/bindings/i2c/qcom,i2c-cci.yaml +++ b/Documentation/devicetree/bindings/i2c/qcom,i2c-cci.yaml @@ -12,14 +12,23 @@ maintainers: properties: compatible: - enum: - - qcom,msm8226-cci - - qcom,msm8916-cci - - qcom,msm8974-cci - - qcom,msm8996-cci - - qcom,sdm845-cci - - qcom,sm8250-cci - - qcom,sm8450-cci + oneOf: + - enum: + - qcom,msm8226-cci + - qcom,msm8974-cci + - qcom,msm8996-cci + + - items: + - enum: + - qcom,msm8916-cci + - const: qcom,msm8226-cci # CCI v1 + + - items: + - enum: + - qcom,sdm845-cci + - qcom,sm8250-cci + - qcom,sm8450-cci + - const: qcom,msm8996-cci # CCI v2 "#address-cells": const: 1 @@ -88,10 +97,12 @@ allOf: - if: properties: compatible: - contains: - enum: - - qcom,msm8226-cci - - qcom,msm8974-cci + oneOf: + - contains: + enum: + - qcom,msm8974-cci + + - const: qcom,msm8226-cci then: properties: clocks: @@ -105,10 +116,12 @@ allOf: - if: properties: compatible: - contains: - enum: - - qcom,msm8916-cci - - qcom,msm8996-cci + oneOf: + - contains: + enum: + - qcom,msm8916-cci + + - const: qcom,msm8996-cci then: properties: clocks: @@ -169,7 +182,7 @@ examples: cci@ac4a000 { reg = <0x0ac4a000 0x4000>; - compatible = "qcom,sdm845-cci"; + compatible = "qcom,sdm845-cci", "qcom,msm8996-cci"; #address-cells = <1>; #size-cells = <0>;