Received: by 2002:a05:7412:251c:b0:e2:908c:2ebd with SMTP id w28csp782250rda; Sun, 22 Oct 2023 09:25:58 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEK0t14cdMg3yFgWBkpLOouWd45RGHRP0pjKq25bHTryzUCZWF+foejXdfrBaPToA+2fUvL X-Received: by 2002:a05:6a21:3b45:b0:17b:426f:829 with SMTP id zy5-20020a056a213b4500b0017b426f0829mr6730217pzb.37.1697991957824; Sun, 22 Oct 2023 09:25:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1697991957; cv=none; d=google.com; s=arc-20160816; b=Y0I4YImf0UhvRlOKL3QK9/1ANEQ1HymzMgTDFQxMHoUSY78LnKs9RliDHYJHEClCxV K6Gsto+5/pTjIOu907c7+70ui6eJ4GOm5umd65O65FAY17Zk8pmemGF9Vv2rI2oubokP LzOV6YY7Yk4kWYn/x5wkohs6+BF/HV9WX44nx3UJ8kkViqSmvRT55T+A7Rlm04mXd4sQ HZokqknCoomOixVtl1u7ebngK7ab1CkA3sj/n5onLA6V3l5ML8DIAXuze7dkzAPBTYcI xz6lxhqPPkCREcRm+XFNdVyRI+1sg+uq18BWF7bozKYAUF9djGg6yCbGdkcI7cRzDoM4 +bRw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=qDM/PkLHiTHspRfCYzT0Sz4PDLknRYMSlH9qkbTwPMs=; fh=NJezcqSAkqwAPzpirvwoYnRoFoo1ncJO2fUkNsTA8t8=; b=wvdZ+ifIWnyPBKZcbC5xK4cEInrVRIIZgVcXT8tP25+yVrgFdHW4gaTjgEYp/A+hTI fj0VDKlF3RKjIrG31Je8BI787VGuDn9ajiz0Co+6fOGUsQjcSKrfdCK5l7CEmYCmU2yT 7dUKNrLWcQ1t+JnEmzVB9oKiseVVCKyDR4x+0ySxXPMynX6j4Q9Pwbwt3TfbwjGFqcWQ w/VNf+F2F/8MwvciGLWAGVxtwSn3+obkIhqyD5mliUWBpUKpI+gFSV4dxB8g9h7HzKGj 4JyVZY7xl2ns0cDBKz6lGVw8HUPYPIDFzMysVvJhNwqva2wXVmT0ZhaBsJBjyNEqlmay MLsg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=GEHT2RuR; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from groat.vger.email (groat.vger.email. [2620:137:e000::3:5]) by mx.google.com with ESMTPS id p22-20020a056a000b5600b006be1fc3ee73si5141677pfo.358.2023.10.22.09.25.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 22 Oct 2023 09:25:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) client-ip=2620:137:e000::3:5; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=GEHT2RuR; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:5 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id D42718096FFC; Sun, 22 Oct 2023 09:25:54 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231972AbjJVQZn (ORCPT + 99 others); Sun, 22 Oct 2023 12:25:43 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51910 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229586AbjJVQZl (ORCPT ); Sun, 22 Oct 2023 12:25:41 -0400 Received: from mail-oa1-x2e.google.com (mail-oa1-x2e.google.com [IPv6:2001:4860:4864:20::2e]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C4400124; Sun, 22 Oct 2023 09:25:39 -0700 (PDT) Received: by mail-oa1-x2e.google.com with SMTP id 586e51a60fabf-1eb39505ba4so902929fac.0; Sun, 22 Oct 2023 09:25:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1697991939; x=1698596739; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=qDM/PkLHiTHspRfCYzT0Sz4PDLknRYMSlH9qkbTwPMs=; b=GEHT2RuRrkQ/8F9qJn4+KF+yszUDFIrI7vx0FjsaAlTwlrbenxQ+DRKUbBRutH8z3P q/8RzFAk5n9/N2cwqU+Tu8QisOh/O2OCpGlWJuWWUoSXhYMptZZQA0Uj4+D26a38QEcB 15rGqtXp0GfChVs6DqYHS1tuIbfGgF/x/EIWD3VRP9W4yTsSGOo+vufGpwkDoPAxMxMa 5wCLz6dfE/fnLvhQOZBmrV9RpKqhoR5zQO4RzvrOalaD/QKZKCJah9Y6BHUtiYeHBgcS EqJycBZSTENNgvljbqsMvsnwxgffbeRvyA/77SV4TYqJfllgsuLanXptjkOYnuWDsW38 gG2g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1697991939; x=1698596739; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=qDM/PkLHiTHspRfCYzT0Sz4PDLknRYMSlH9qkbTwPMs=; b=CmnKjWHWMihsmJuDJP72lwz0RKTStMxceChnBECY6UVKMqivXILw+Wa+OBC21jBXfN zgMSST/FSf4ev34NQPu3MpLuL/oA6zVoCaJVP6DA0JkRDdmizIozBm7EIbSYwxQWm9ub xa4Oveavejc5s0VDvjw/S32znLYf+MkBYgcr18KtbZAHEnZc1uhRFJ2BiwbjLGX/MV73 V2PHEJCK1cuGSI6PhQbcuHCPW0X+vFT3KjKle7+LFlfgRMvwxuHMnDkapa3Mt16IpeeT t1ITZ7ucVMNQuLukA904lx9d6W2BrnNREN3ieGUMwGfHM7WRtYgbk/dGJ9GWEzKGb1Wb r42g== X-Gm-Message-State: AOJu0YzvClYEfLQKPOGgup6dPuKAG6PvP3XmOJy7A+OCqnNFPKeL8l4X Riw1iMrfad+HSYiojnaxUgkCFC0ZXaM95WJTtWE= X-Received: by 2002:a05:6870:4c05:b0:1ea:2a:dc59 with SMTP id pk5-20020a0568704c0500b001ea002adc59mr9316873oab.51.1697991938916; Sun, 22 Oct 2023 09:25:38 -0700 (PDT) MIME-Version: 1.0 References: <20231022131252.801090-1-sergio.paracuellos@gmail.com> <0e6a3e08-4f66-4bc1-a8a0-a7bb40472136@linaro.org> In-Reply-To: <0e6a3e08-4f66-4bc1-a8a0-a7bb40472136@linaro.org> From: Sergio Paracuellos Date: Sun, 22 Oct 2023 18:25:28 +0200 Message-ID: Subject: Re: [PATCH v2] dt-bindings: phy: ralink-usb-phy: convert to dtschema To: Krzysztof Kozlowski Cc: devicetree@vger.kernel.org, vkoul@kernel.org, kishon@kernel.org, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, matthias.bgg@gmail.com, angelogioacchino.delregno@collabora.com, linux-kernel@vger.kernel.org, linux-phy@lists.infradead.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-0.6 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,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 groat.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (groat.vger.email [0.0.0.0]); Sun, 22 Oct 2023 09:25:55 -0700 (PDT) Hi Krysztof, On Sun, Oct 22, 2023 at 5:57=E2=80=AFPM Krzysztof Kozlowski wrote: > > On 22/10/2023 15:12, Sergio Paracuellos wrote: > > Convert the ralink-usb-phy bindings to DT schema. > > > > Signed-off-by: Sergio Paracuellos > > --- > > Changes in v2: > > - Add missing SPDX License Identifier > > > > .../bindings/phy/ralink-usb-phy.txt | 23 ------ > > .../bindings/phy/ralink-usb-phy.yaml | 70 +++++++++++++++++++ > > 2 files changed, 70 insertions(+), 23 deletions(-) > > delete mode 100644 Documentation/devicetree/bindings/phy/ralink-usb-ph= y.txt > > create mode 100644 Documentation/devicetree/bindings/phy/ralink-usb-ph= y.yaml > > > > diff --git a/Documentation/devicetree/bindings/phy/ralink-usb-phy.txt b= /Documentation/devicetree/bindings/phy/ralink-usb-phy.txt > > deleted file mode 100644 > > index 9d2868a437ab..000000000000 > > --- a/Documentation/devicetree/bindings/phy/ralink-usb-phy.txt > > +++ /dev/null > > @@ -1,23 +0,0 @@ > > -Mediatek/Ralink USB PHY > > - > > -Required properties: > > - - compatible: "ralink,rt3352-usbphy" > > - "mediatek,mt7620-usbphy" > > - "mediatek,mt7628-usbphy" > > - - reg: required for "mediatek,mt7628-usbphy", unused otherwise > > - - #phy-cells: should be 0 > > - - ralink,sysctl: a phandle to a ralink syscon register region > > - - resets: the two reset controllers for host and device > > - - reset-names: the names of the 2 reset controllers > > - > > -Example: > > - > > -usbphy: phy { > > - compatible =3D "mediatek,mt7628-usbphy"; > > - reg =3D <0x10120000 0x1000>; > > - #phy-cells =3D <0>; > > - > > - ralink,sysctl =3D <&sysc>; > > - resets =3D <&rstctrl 22 &rstctrl 25>; > > - reset-names =3D "host", "device"; > > -}; > > diff --git a/Documentation/devicetree/bindings/phy/ralink-usb-phy.yaml = b/Documentation/devicetree/bindings/phy/ralink-usb-phy.yaml > > new file mode 100644 > > index 000000000000..b05665f5b641 > > --- /dev/null > > +++ b/Documentation/devicetree/bindings/phy/ralink-usb-phy.yaml > > Filename matching compatible. Missing vendor prefix, comma. Sure, will use mediatek,mt7628-usbphy compatible, then. > > > > @@ -0,0 +1,70 @@ > > +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) > > +%YAML 1.2 > > +--- > > +$id: http://devicetree.org/schemas/phy/ralink-usb-phy.yaml# > > +$schema: http://devicetree.org/meta-schemas/core.yaml# > > + > > +title: Mediatek/Ralink USB PHY > > + > > +maintainers: > > + - Sergio Paracuellos > > + > > +properties: > > + compatible: > > + enum: > > + - ralink,rt3352-usbphy > > + - mediatek,mt7620-usbphy > > + - mediatek,mt7628-usbphy > > Keep them ordered alphabetically, please. Will do. > > Blank line here. True, thanks. > > > > + reg: > > + maxItems: 1 > > + > > + "#phy-cells": > > + const: 0 > > + > > + ralink,sysctl: > > + description: > > + phandle to a ralink syscon register region. > > + $ref: /schemas/types.yaml#/definitions/phandle > > + > > + resets: > > + items: > > + - description: USB Host reset controller > > + - description: USB Device reset controller > > + > > + reset-names: > > + items: > > + - const: host > > + - const: device > > + > > +allOf: > > + - if: > > + properties: > > + compatible: > > + contains: > > + const: mediatek,mt7628-usbphy > > + then: > > + required: > > + - reg > > else: > is it even valid? Will add else with reg to false for the rest since looking into driver code it looks like it is not using for other compatible at all. > > Anyway, please put allOf: block after required: block. Will do. > > > + > > +required: > > + - compatible > > + - "#phy-cells" > > + - ralink,sysctl > > + - resets > > + - reset-names > > + > > > Best regards, > Krzysztof > Thanks, Sergio Paracuellos