Received: by 2002:ab2:6991:0:b0:1f2:fff1:ace7 with SMTP id v17csp261756lqo; Wed, 27 Mar 2024 12:12:27 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCX75fa3XYqzFMkaAUvA3FaAjuSUCArfe4eEIoX0vvtZJnmgYUVLxTw2cAARLJyOdmR+6bXONDd9hXV6hjNTOhNcPf4FnTIxrQnxgdXP+w== X-Google-Smtp-Source: AGHT+IFhrIe2ba322UYVEfv4m02nNWA6KG+VVjLOqCc8f6yRH9h1QdZJnGbWTgF2ObcFCD18R15B X-Received: by 2002:a17:902:e845:b0:1e0:c5cc:8f1c with SMTP id t5-20020a170902e84500b001e0c5cc8f1cmr566415plg.26.1711566747325; Wed, 27 Mar 2024 12:12:27 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1711566747; cv=pass; d=google.com; s=arc-20160816; b=FF1efaEJT5qgAyfZL7J4ak6Sb8eIn0sobIflCO76b4YHj+yDCigYzG+cCEOibVHwiU GEtCa4lvsexIWm5UzMjAIngHv5h7L7mQna7nZlcOoPgPirSEdPBpRe01tRTF9KPIOQ5J 8GCuoOFKzTqZ/ycHaBAAeBkSk7pkaOBRJAZH3sufyB9UjgCne4AySEdmqOM56oEEue4X JDmqF18GQWiA5mnfNhwAB70IMyGshDD1FzyXsQIH1qBxHgMsrlTz2HIp8yoyqe5RV7Ts y4tO0eDCwfShgPMQJpcCewTmkCAp4dNCcwl60cCZFZZZ0I9UyURDtZQSIPOQ5OH3Vw94 pqdA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :subject:date:from; bh=ypxS5dnJc/2ei5bp8/cJgIy1vG3lbxxnD2t2ITYNNKo=; fh=Ea2+IA2/2u6hP3WCjiC2o4wRlqRTAAWj2jvdj6NTkDs=; b=md0g5AYuquBFG1AF390X7/lQOFlWgpYTmazOQYVvuXpoXtz4zRopKl/TqUOOIb/l5b hJG5u7NQSWhBiX+1sSFeCQoLRMAY9iPpPTy3swrxkYCFfyVYSnuLphBvpYniaemv4jht t8FuaRgnrbacUmF4/9lBIg69TAqDBUp2twO+gGnC/rKLidQnEhEQX8YxdNDOEvH4jn5A roA/d4IGaQWT3Cp8YpojPphg7zIcerDFnPtCMQjF7+GoPTl9UMdKsHB/EY69KGKwZIKn kQxqwipPbBsHq9gx62vYmNJUSGdFjNO6A25VoYWQ8RoXMgtbs9ne5nzSwrVhfk8QkftI YeOg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel+bounces-121889-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-121889-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id i11-20020a17090332cb00b001deed3f8f6csi9927453plr.548.2024.03.27.12.12.27 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 27 Mar 2024 12:12:27 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-121889-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel+bounces-121889-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-121889-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id EDA1C29E891 for ; Wed, 27 Mar 2024 19:12:26 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id A9939152533; Wed, 27 Mar 2024 19:11:51 +0000 (UTC) Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D6BFA152187; Wed, 27 Mar 2024 19:11:50 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711566710; cv=none; b=cf3jpDlWZOYPHULPhr3ux6ARWFsBdauTJv1HuMaJwsbV6az1I0yXYge8qCuduxeXOR6SaXYBVhyHqhmWFmNG/yusGc19D963zl5sUEa126eBdigkCF6yrWSyMGaYRrLJH+EreNwUCTLpIcnNETY9EHLH8XfaN2oo5HZjI9ae4EM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1711566710; c=relaxed/simple; bh=tIFCfgf+3D7TdIVE0ZdE2tSE7iH4jRinyIvff5gv8yI=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=SbM+Ltj5QyYlzdFuBj9d70OZCxdlAGpzEhOnm7leiCQsZHTZkeujWbOdOyDDjfmkp+A7+/CPwP+safe8j+X8FS8rfQVo88SW0PF2z7Df7A9Z6zhUiwVshIsDU5l/1Xe+/nsbcuc4FKA6ZGNBrNiOOEAq5Z8zCE6UnsuEk8EeOoI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 48E9AC43601; Wed, 27 Mar 2024 19:11:50 +0000 (UTC) Received: by mercury (Postfix, from userid 1000) id AB94A1060992; Wed, 27 Mar 2024 20:11:47 +0100 (CET) From: Sebastian Reichel Date: Wed, 27 Mar 2024 20:11:33 +0100 Subject: [PATCH v2 2/7] dt-bindings: hsi: nokia-modem: convert to YAML Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20240327-hsi-dt-binding-v2-2-110fab4c32ae@collabora.com> References: <20240327-hsi-dt-binding-v2-0-110fab4c32ae@collabora.com> In-Reply-To: <20240327-hsi-dt-binding-v2-0-110fab4c32ae@collabora.com> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Sebastian Reichel Cc: Tony Lindgren , devicetree@vger.kernel.org, linux-omap@vger.kernel.org, linux-kernel@vger.kernel.org, Sebastian Reichel X-Mailer: b4 0.13.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=5307; i=sebastian.reichel@collabora.com; h=from:subject:message-id; bh=tIFCfgf+3D7TdIVE0ZdE2tSE7iH4jRinyIvff5gv8yI=; b=owEBbQKS/ZANAwAKAdju1/PIO/qaAcsmYgBmBG9xESFLsmU9PrlmwWaBhkW2IWl5iC4Fx4xWa BAk/X+EN3uJAjMEAAEKAB0WIQTvZg0HRj+Lcmp5VBPY7tfzyDv6mgUCZgRvcQAKCRDY7tfzyDv6 ms/0D/9PM/pXIrq5uR+J+47qLOAobSWIVB4frfxUJB+0Ej5YCe0AyDv7zCUHM8znJZCB04xrwwW /AF/+6gcgOqBWSY+jgHecpyw3teLyR6r10dCEP48oOwDHJVzS47VXdI9jx1P98PIHpZyHegv9dX iTiCDd3tR3GOkWd6WktrW4U5IW8pia6MFT22PlNncCsz7bv1YoUnujod9dnSECOlGmZ1FBTcOlP Xj63u2HfqKyi/c9jzwda/mIrfRSylybCYs3N766lfs23PAbGUXphMwEXU+6X0EWK8PSiO3oY1QI w6yjeXEuvI+Ot1sSyCeNboZpjSGppEwKYEnGRxKg0mTlA1jbnmIRn/oHmA7/FVEaCkQCE0OcnCp UTotJ6U/5MB3mCExcQByBaSg2gLIEGcpixYOAXjUTw2P7fBgTe9PLp4Cbru54L49qEsFfWlBMew TuLhLAzQ5MXxB0ELSCNlrYVZUP1NWZ0sSS7WPn6qcvwOb7pnAaF54x7CU6MFM/ASGneNHn1jKjx VZmi1Yl/0cD53FZGnQrRd8hbjnj0vfLT64UNEEXBozAd5ge2JdWifWKuO9jw6dNGgaOlmchbo82 dYGM93WS1QqxzjLCtwKQ62bTf1fr2FfWOdzE54b7uU3gnvSnk+IbTO2QqP2rmqhGaIPBu9xQl2v dXWiSb9gYKwf8Zw== X-Developer-Key: i=sebastian.reichel@collabora.com; a=openpgp; fpr=EF660D07463F8B726A795413D8EED7F3C83BFA9A Convert the legacy txt binding to modern YAML. No semantic change. Signed-off-by: Sebastian Reichel --- .../devicetree/bindings/hsi/nokia,modem.yaml | 106 +++++++++++++++++++++ .../devicetree/bindings/hsi/nokia-modem.txt | 59 ------------ 2 files changed, 106 insertions(+), 59 deletions(-) diff --git a/Documentation/devicetree/bindings/hsi/nokia,modem.yaml b/Documentation/devicetree/bindings/hsi/nokia,modem.yaml new file mode 100644 index 000000000000..f6d5e2c14329 --- /dev/null +++ b/Documentation/devicetree/bindings/hsi/nokia,modem.yaml @@ -0,0 +1,106 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/hsi/nokia,modem.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Nokia modem + +maintainers: + - Sebastian Reichel + +properties: + compatible: + enum: + - nokia,n900-modem + - nokia,n950-modem + - nokia,n9-modem + + hsi-channel-ids: + $ref: /schemas/types.yaml#/definitions/uint32-array + minItems: 4 + maxItems: 4 + + hsi-channel-names: + items: + - const: mcsaab-control + - const: speech-control + - const: speech-data + - const: mcsaab-data + + interrupts: + items: + - description: modem reset indication + + gpios: + minItems: 3 + maxItems: 5 + + gpio-names: + items: + - const: cmt_apeslpx + - const: cmt_rst_rq + - const: cmt_en + - const: cmt_rst + - const: cmt_bsi + minItems: 3 + +required: + - gpios + - gpio-names + - interrupts + +allOf: + - $ref: hsi-client.yaml# + - if: + properties: + compatible: + contains: + enum: + - nokia,n950-modem + - nokia,n9-modem + then: + properties: + gpios: + maxItems: 3 + gpio-names: + maxItems: 3 + else: + properties: + gpios: + minItems: 5 + gpio-names: + minItems: 5 + +unevaluatedProperties: false + +examples: + - | + #include + #include + modem { + compatible = "nokia,n900-modem"; + + hsi-channel-ids = <0>, <1>, <2>, <3>; + hsi-channel-names = "mcsaab-control", + "speech-control", + "speech-data", + "mcsaab-data"; + hsi-speed-kbps = <55000>; + hsi-mode = "frame"; + hsi-flow = "synchronized"; + hsi-arb-mode = "round-robin"; + + interrupts-extended = <&gpio3 8 IRQ_TYPE_EDGE_FALLING>; + + gpios = <&gpio3 6 GPIO_ACTIVE_HIGH>, + <&gpio3 9 GPIO_ACTIVE_HIGH>, + <&gpio3 10 GPIO_ACTIVE_HIGH>, + <&gpio3 11 GPIO_ACTIVE_HIGH>, + <&gpio5 29 GPIO_ACTIVE_HIGH>; + gpio-names = "cmt_apeslpx", + "cmt_rst_rq", + "cmt_en", + "cmt_rst", + "cmt_bsi"; + }; diff --git a/Documentation/devicetree/bindings/hsi/nokia-modem.txt b/Documentation/devicetree/bindings/hsi/nokia-modem.txt deleted file mode 100644 index 53de1d9d0b95..000000000000 --- a/Documentation/devicetree/bindings/hsi/nokia-modem.txt +++ /dev/null @@ -1,59 +0,0 @@ -Nokia modem client bindings - -The Nokia modem HSI client follows the common HSI client binding -and inherits all required properties. The following additional -properties are needed by the Nokia modem HSI client: - -Required properties: -- compatible: Should be one of - "nokia,n900-modem" - "nokia,n950-modem" - "nokia,n9-modem" -- hsi-channel-names: Should contain the following strings - "mcsaab-control" - "speech-control" - "speech-data" - "mcsaab-data" -- gpios: Should provide a GPIO handler for each GPIO listed in - gpio-names -- gpio-names: Should contain the following strings - "cmt_apeslpx" (for n900, n950, n9) - "cmt_rst_rq" (for n900, n950, n9) - "cmt_en" (for n900, n950, n9) - "cmt_rst" (for n900) - "cmt_bsi" (for n900) -- interrupts: Should be IRQ handle for modem's reset indication - -Example: - -&ssi_port { - modem: hsi-client { - compatible = "nokia,n900-modem"; - - pinctrl-names = "default"; - pinctrl-0 = <&modem_pins>; - - hsi-channel-ids = <0>, <1>, <2>, <3>; - hsi-channel-names = "mcsaab-control", - "speech-control", - "speech-data", - "mcsaab-data"; - hsi-speed-kbps = <55000>; - hsi-mode = "frame"; - hsi-flow = "synchronized"; - hsi-arb-mode = "round-robin"; - - interrupts-extended = <&gpio3 8 IRQ_TYPE_EDGE_FALLING>; /* 72 */ - - gpios = <&gpio3 6 GPIO_ACTIVE_HIGH>, /* 70 */ - <&gpio3 9 GPIO_ACTIVE_HIGH>, /* 73 */ - <&gpio3 10 GPIO_ACTIVE_HIGH>, /* 74 */ - <&gpio3 11 GPIO_ACTIVE_HIGH>, /* 75 */ - <&gpio5 29 GPIO_ACTIVE_HIGH>; /* 157 */ - gpio-names = "cmt_apeslpx", - "cmt_rst_rq", - "cmt_en", - "cmt_rst", - "cmt_bsi"; - }; -}; -- 2.43.0