From patchwork Thu Mar 16 03:05:11 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Xingyu Wu X-Patchwork-Id: 70553 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:604a:0:0:0:0:0 with SMTP id j10csp257543wrt; Wed, 15 Mar 2023 20:10:59 -0700 (PDT) X-Google-Smtp-Source: AK7set/VrBOr286KjceZOZwj5Rv/FEE48SU8tgucqOLo1jrKBLUm6rW7Ek2WoCHOCQPcSzA0t9LV X-Received: by 2002:a05:6102:f86:b0:425:d18f:5771 with SMTP id e6-20020a0561020f8600b00425d18f5771mr2496301vsv.5.1678936259495; Wed, 15 Mar 2023 20:10:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1678936259; cv=none; d=google.com; s=arc-20160816; b=OTJzsPLAmsL4f5aHZNOAcmU/QV7mZBY21aV/j/2gKWoGUgRfZZ0LGW/EbL401qV9zx CVvbPsdhBxrzqTBwuZUD3lnmW2Lz1DffGGWu0S2LrlzZwquL/GrLpoMJ23jLPMg75hUm sGvu4A6scYYvm7zoTOyNXxpd1B+3qTVizMLMVGBRztTQEzAoaXSdordvmcGAA/lgRfrd WORsj5xRzS5XJwsseAog81XGdHR44K3JlklrKYB1JwCfyoxtP8QMFP86YPnXDSbDX42s j/OKW03VQl9lD93Nfg7KqushBrmJQkPRATHo89AAdVD2xkyeCUFapNKXxYM0f+jRfswQ 0FrA== 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 :references:in-reply-to:message-id:date:subject:cc:to:from; bh=l8zBD3HfHpO9b8ZvjnoF1WOvMpsxtV4xsTTqEgicbAY=; b=nvKnU9y/tIPB+gxLI8+tl3lefP0nOeHRIW6veGldQsTPFcDvo/w7Bym5/aszKYivAp 4G5j0olfyQ41KibH/e+Eg/8to+CC6xikCwrUge+hQh0VoOSfv5fxZHsKS879JkkXOYHi L07xeliakMDQ04zIAXIVgKphCW0R7+uoIXs5beVWr8gFM9t0+lUtyB/mwcJce+Xl6IG6 a6mlg4tGjrWBHV4igab3hCqGmxuW7n1NLvT/wrMSR2/FZPVoHd+A9Fyo1V2OITjZh25S RYz5wq/8yl1GfbxBFVyGVlQqTeOG0hxePrUqdkGyqHnIMmYZOApC8Kk6SoDL+XjoN2mV lr5w== ARC-Authentication-Results: i=1; mx.google.com; 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 Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id p2-20020ab03b82000000b00753be25739fsi3350573uaw.32.2023.03.15.20.10.43; Wed, 15 Mar 2023 20:10:59 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229872AbjCPDFf convert rfc822-to-8bit (ORCPT + 99 others); Wed, 15 Mar 2023 23:05:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39190 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229816AbjCPDFW (ORCPT ); Wed, 15 Mar 2023 23:05:22 -0400 Received: from ex01.ufhost.com (ex01.ufhost.com [61.152.239.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 88B2640E6; Wed, 15 Mar 2023 20:05:20 -0700 (PDT) Received: from EXMBX166.cuchost.com (unknown [175.102.18.54]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "EXMBX166", Issuer "EXMBX166" (not verified)) by ex01.ufhost.com (Postfix) with ESMTP id 4142324E207; Thu, 16 Mar 2023 11:05:19 +0800 (CST) Received: from EXMBX061.cuchost.com (172.16.6.61) by EXMBX166.cuchost.com (172.16.6.76) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Thu, 16 Mar 2023 11:05:19 +0800 Received: from localhost.localdomain (113.72.145.194) by EXMBX061.cuchost.com (172.16.6.61) with Microsoft SMTP Server (TLS) id 15.0.1497.42; Thu, 16 Mar 2023 11:05:17 +0800 From: Xingyu Wu To: , , "Michael Turquette" , Stephen Boyd , Krzysztof Kozlowski , Philipp Zabel , Conor Dooley , "Emil Renner Berthing" CC: Rob Herring , Paul Walmsley , Palmer Dabbelt , Albert Ou , Hal Feng , Xingyu Wu , William Qiu , , Subject: [PATCH v2 3/6] dt-bindings: soc: starfive: syscon: Add optional patternProperties Date: Thu, 16 Mar 2023 11:05:11 +0800 Message-ID: <20230316030514.137427-4-xingyu.wu@starfivetech.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230316030514.137427-1-xingyu.wu@starfivetech.com> References: <20230316030514.137427-1-xingyu.wu@starfivetech.com> MIME-Version: 1.0 X-Originating-IP: [113.72.145.194] X-ClientProxiedBy: EXCAS064.cuchost.com (172.16.6.24) To EXMBX061.cuchost.com (172.16.6.61) X-YovoleRuleAgent: yovoleflag X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_PASS 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?1760492266812084519?= X-GMAIL-MSGID: =?utf-8?q?1760492266812084519?= Add optional compatible and patternProperties. Signed-off-by: Xingyu Wu --- .../soc/starfive/starfive,jh7110-syscon.yaml | 39 ++++++++++++++++--- 1 file changed, 33 insertions(+), 6 deletions(-) diff --git a/Documentation/devicetree/bindings/soc/starfive/starfive,jh7110-syscon.yaml b/Documentation/devicetree/bindings/soc/starfive/starfive,jh7110-syscon.yaml index ae7f1d6916af..b61d8921ef42 100644 --- a/Documentation/devicetree/bindings/soc/starfive/starfive,jh7110-syscon.yaml +++ b/Documentation/devicetree/bindings/soc/starfive/starfive,jh7110-syscon.yaml @@ -15,16 +15,31 @@ description: | properties: compatible: - items: - - enum: - - starfive,jh7110-aon-syscon - - starfive,jh7110-stg-syscon - - starfive,jh7110-sys-syscon - - const: syscon + oneOf: + - items: + - enum: + - starfive,jh7110-aon-syscon + - starfive,jh7110-stg-syscon + - starfive,jh7110-sys-syscon + - const: syscon + - items: + - enum: + - starfive,jh7110-aon-syscon + - starfive,jh7110-stg-syscon + - starfive,jh7110-sys-syscon + - const: syscon + - const: simple-mfd reg: maxItems: 1 +patternProperties: + # Optional children + "pll-clock-controller": + type: object + $ref: /schemas/clock/starfive,jh7110-pll.yaml# + description: Clock provider for PLL. + required: - compatible - reg @@ -38,4 +53,16 @@ examples: reg = <0x10240000 0x1000>; }; + - | + syscon@13030000 { + compatible = "starfive,jh7110-sys-syscon", "syscon", "simple-mfd"; + reg = <0x13030000 0x1000>; + + pll-clock-controller { + compatible = "starfive,jh7110-pll"; + clocks = <&osc>; + #clock-cells = <1>; + }; + }; + ...