From patchwork Fri Oct 6 08:22:48 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Martin Kaiser X-Patchwork-Id: 13411130 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 44ED8E92FF8 for ; Fri, 6 Oct 2023 08:28:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=AY9+EXGQk8BP11DIxhVt90sEaU7D+gsMk05BP15dkXs=; b=Su3vLeAFQZZvkt 4wrAVxeBntwWvZQqS8eetM0dwM68KEp+JyMAlHYM09M//EPfVhnH3GVEkQlmMxiv7jp/1Y6oZQ5M/ /eEpdaMAFeS/SgaeeH2oQIcBHXyS4QK03lObm8vfN9ATLeHk0zDs0O1aI4sKY5Jj6BBlHN3OdwMky 33p/H5n/M/52KnoZslvJtmvypEnsQx938ChAra6Fq/sdhTZKWDyJ4L2OejRpBVmQQIVsYtfD0UNKi aQVox26udVSQIgq8ElJ2LhsgSq68DGyRIDz/O5rKoER1jP4HA6FiN5gouKUFVm9gPvkMkFyYswFTD /k7nxW2+Dv4sfhQmbumw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qogBn-005I2C-0e; Fri, 06 Oct 2023 08:28:03 +0000 Received: from viti.kaiser.cx ([2a01:238:43fe:e600:cd0c:bd4a:7a3:8e9f]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qogBk-005I0e-0c for linux-arm-kernel@lists.infradead.org; Fri, 06 Oct 2023 08:28:01 +0000 Received: from dslb-188-097-209-100.188.097.pools.vodafone-ip.de ([188.97.209.100] helo=martin-debian-2.paytec.ch) by viti.kaiser.cx with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1qogBR-0007T2-IT; Fri, 06 Oct 2023 10:27:41 +0200 From: Martin Kaiser To: Linus Walleij , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Maxime Coquelin , Alexandre Torgue , Geert Uytterhoeven , Magnus Damm Cc: Martin Kaiser , linux-gpio@vger.kernel.org, devicetree@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-renesas-soc@vger.kernel.org Subject: [PATCH] dt-bindings: pinctrl: st,stm32: fix phandle-array warning Date: Fri, 6 Oct 2023 10:22:48 +0200 Message-Id: <20231006082247.3830719-1-martin@kaiser.cx> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20231006_012800_403617_93B682F4 X-CRM114-Status: GOOD ( 10.80 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org make CHECK_DTBS=y st/stm32f469-disco.dtb brings up a warning about a missing argument: stm32f469-disco.dtb: pinctrl@40020000: st,syscfg:0: [21, 8] is too short The description of the third entry indicates that this entry is optional. The code in stm32_pctrl_dt_setup_irq parses st,syscfg and treats the third entry as optional. It defaults to 0xf if not present in the devicetree. Update the schema to require at least two entries, use the same syntax as the description of renesas,ipmmu-main in Documentation/devicetree/bindings/iommu/renesas,ipmmu-vmsa.yaml. Signed-off-by: Martin Kaiser Acked-by: Rob Herring --- I tested the following cases, all of them returned the expected result: st,syscfg = <&syscfg>; (too short) st,syscfg = <&syscfg 0x8>; (ok) st,syscfg = <&syscfg 0x8 0x0>; (ok) st,syscfg = <&syscfg 0x8 0x0 0x0>; (too long) .../devicetree/bindings/pinctrl/st,stm32-pinctrl.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/pinctrl/st,stm32-pinctrl.yaml b/Documentation/devicetree/bindings/pinctrl/st,stm32-pinctrl.yaml index 2120ef71a78d..e1eb45a9eda4 100644 --- a/Documentation/devicetree/bindings/pinctrl/st,stm32-pinctrl.yaml +++ b/Documentation/devicetree/bindings/pinctrl/st,stm32-pinctrl.yaml @@ -48,7 +48,8 @@ properties: description: Phandle+args to the syscon node which includes IRQ mux selection. $ref: /schemas/types.yaml#/definitions/phandle-array items: - - items: + - minItems: 2 + items: - description: syscon node which includes IRQ mux selection - description: The offset of the IRQ mux selection register - description: The field mask of IRQ mux, needed if different of 0xf