Received: by 2002:a05:6a10:9afc:0:0:0:0 with SMTP id t28csp693969pxm; Fri, 25 Feb 2022 17:28:12 -0800 (PST) X-Google-Smtp-Source: ABdhPJyB8ECDTPhaqJ/lt6yGzFXmH7PGKwBP+tf6/tATP15WfpvCTy3CDSQt5OlFUk5yZdaMh60A X-Received: by 2002:a63:224a:0:b0:368:e837:3262 with SMTP id t10-20020a63224a000000b00368e8373262mr8289925pgm.546.1645838892308; Fri, 25 Feb 2022 17:28:12 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1645838892; cv=none; d=google.com; s=arc-20160816; b=OB7aR13TN/MXGpE4bGvYro0Azcl87qpo7/LOnXJa1DJb82ev2pOoDJ/ofIMZF1iLuV bfOIhMtkYpOyzqucrPF0sFruB58wfNgAEDiUWUUWjAuAlUf6gavYzEdhvYlhWVVMD22J ROLa9b4aAtD9fDAGyddII0TDiFxHHUqV/d6Nz3r8JjdK5nn5TKzJ43n7WFgY09vO/Jy9 RmFy8HY9ThuLxJnLpX+zyjpjELa6M2wn+C3Il+7lnLTvFjZGT37hWIzARyIGQ+22C9lX raBjWGF8hMFaqsZttzpLb5GoNTy6YZsy8zKyoJNvpP5961WHpmXpyeiJjaCOOP+UWsfX gwzw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=8/RhmmvOE3ZBDv39xXLcWsX9wxG1z+5j6Nqh+tUlI0Q=; b=ZNNsetIQx5uBuNpkAJ5ULO4lb765DPiF13Q6tHyU0VYPQYHVj3pa+e0AHMldnvIKPF j8zJWJU7vlPHhrbB3xw4UwmotFaVfk8Yjm5IdwMiTdDsszoPzYfrvBjS1qbC5pnadXxi aWsdUQpF0p9DDUMPvyDMyOapYpy8DgLRSuFBYGFNLWTCPeoWMn9JZuvYNZATwj/NxuLl +HXM378hOgTkZHJVJx0A801u3sE4ovdnNX16EaghECnNYJEczhDWr6+AM+qAe4LnA7E8 XsCTRC24+bFoJVloccbRQJgjaOU0BSPfs/rtFp9ybCf1WdBCa4L49VJOfEITuSQHJjfj /v3A== 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:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id b9-20020a655789000000b0037476070f44si3148086pgr.12.2022.02.25.17.28.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Feb 2022 17:28:12 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 3F30D5523B; Fri, 25 Feb 2022 17:26:31 -0800 (PST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234650AbiBYT0z (ORCPT + 99 others); Fri, 25 Feb 2022 14:26:55 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34902 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234593AbiBYT0y (ORCPT ); Fri, 25 Feb 2022 14:26:54 -0500 Received: from mail-oo1-f50.google.com (mail-oo1-f50.google.com [209.85.161.50]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4D61C1EF36A; Fri, 25 Feb 2022 11:26:21 -0800 (PST) Received: by mail-oo1-f50.google.com with SMTP id w10-20020a4ae08a000000b0031bdf7a6d76so7545226oos.10; Fri, 25 Feb 2022 11:26:21 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=8/RhmmvOE3ZBDv39xXLcWsX9wxG1z+5j6Nqh+tUlI0Q=; b=ssD0SgsREbYVn5l3Iijp/6MHcAToGAlsbJ4Jy/yGogrufZuqTLRoqkuRJpxtur4oKl Qgbi4Z7Y88sHNpJLTkepjUt3XGuvodHrF+MhqiXc7jy4p8pTt8hRUPyTXmH0PWk+RFhr TFfPk4fuBAjDKoLtNXB08JgTAU2chmTGKeXs7+O220LoaVZ2LjODgjBFMFtJf6a+vkfj 29GBwtXOpgeO/2C+wx9567gMVc9sYmDX3AZwYDIyauHsoAJFnQfDV123OI3gT21sTC/z eZ1iBAoZ212zCVfnEXnPFDgRXpRUeIumLy6kDS+U4tZFcWoub1CPmb5kdp3VuVTeG+QH y3Xw== X-Gm-Message-State: AOAM531jwe2rUZRVGKu9Pdf9xbmrnyqjcRKgY0KKAeIwNrPciMSNYsDj SHf/RpejmwD8SNEXmKkcFQ== X-Received: by 2002:a05:6870:d917:b0:ce:c0c9:650 with SMTP id gq23-20020a056870d91700b000cec0c90650mr2073603oab.162.1645817180555; Fri, 25 Feb 2022 11:26:20 -0800 (PST) Received: from robh.at.kernel.org (66-90-148-213.dyn.grandenetworks.net. [66.90.148.213]) by smtp.gmail.com with ESMTPSA id x7-20020a4a8687000000b003191a2edc67sm1586401ooh.7.2022.02.25.11.26.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Feb 2022 11:26:19 -0800 (PST) Received: (nullmailer pid 1288039 invoked by uid 1000); Fri, 25 Feb 2022 19:26:18 -0000 Date: Fri, 25 Feb 2022 13:26:18 -0600 From: Rob Herring To: Krzysztof Kozlowski Cc: Alim Akhtar , Avri Altman , Andy Gross , Bjorn Andersson , Wei Xu , Nishanth Menon , Vignesh Raghavendra , Tero Kristo , "James E.J. Bottomley" , "Martin K. Petersen" , Jan Kotas , Li Wei , Stanley Chu , Yaniv Gardi , linux-scsi@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-mediatek@lists.infradead.org Subject: Re: [PATCH v2 01/15] dt-bindings: ufs: add common platform bindings Message-ID: References: <20220222145854.358646-1-krzysztof.kozlowski@canonical.com> <20220222145854.358646-2-krzysztof.kozlowski@canonical.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220222145854.358646-2-krzysztof.kozlowski@canonical.com> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no 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 On Tue, Feb 22, 2022 at 03:58:40PM +0100, Krzysztof Kozlowski wrote: > Add bindings for common parts (platform) of Universal Flash Storage > (UFS) Host Controllers in dtschema format. > > The 'freq-table-hz' is not correct in dtschema, because '-hz' suffix > defines uint32 type, not an array. Therefore deprecate 'freq-table-hz' > and use 'freq-table' instead. -hz is an array type. We can extend it to matrix if needed. I do think this property is a bit questionable. Do we really need a minimum in DT and if not, wouldn't assigned-clocks-rate work? Or an OPP table. > Include also the bindings directory in UFS maintainers entry. > > Signed-off-by: Krzysztof Kozlowski > --- > .../devicetree/bindings/ufs/ti,j721e-ufs.yaml | 2 +- > .../devicetree/bindings/ufs/ufs-common.yaml | 88 +++++++++++++++++++ > MAINTAINERS | 1 + > 3 files changed, 90 insertions(+), 1 deletion(-) > create mode 100644 Documentation/devicetree/bindings/ufs/ufs-common.yaml > > diff --git a/Documentation/devicetree/bindings/ufs/ti,j721e-ufs.yaml b/Documentation/devicetree/bindings/ufs/ti,j721e-ufs.yaml > index 4d13e6bc1c50..dc93fe2d3458 100644 > --- a/Documentation/devicetree/bindings/ufs/ti,j721e-ufs.yaml > +++ b/Documentation/devicetree/bindings/ufs/ti,j721e-ufs.yaml > @@ -80,7 +80,7 @@ examples: > compatible = "cdns,ufshc-m31-16nm", "jedec,ufs-2.0"; > reg = <0x0 0x4000 0x0 0x10000>; > interrupts = ; > - freq-table-hz = <19200000 19200000>; > + freq-table = <19200000 19200000>; > power-domains = <&k3_pds 277>; > clocks = <&k3_clks 277 1>; > assigned-clocks = <&k3_clks 277 1>; > diff --git a/Documentation/devicetree/bindings/ufs/ufs-common.yaml b/Documentation/devicetree/bindings/ufs/ufs-common.yaml > new file mode 100644 > index 000000000000..85c73d2853e9 > --- /dev/null > +++ b/Documentation/devicetree/bindings/ufs/ufs-common.yaml > @@ -0,0 +1,88 @@ > +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/ufs/ufs-common.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Common properties for Universal Flash Storage (UFS) Host Controllers > + > +maintainers: > + - Alim Akhtar > + - Avri Altman > + > +properties: > + clocks: true > + > + clock-names: true > + > + freq-table-hz: > + deprecated: true > + description: > + Use freq-table. > + > + freq-table: > + $ref: /schemas/types.yaml#/definitions/uint32-matrix > + items: > + items: > + - description: Minimum frequency for given clock > + - description: Maximum frequency for given clock > + description: | > + Array of operating frequencies in Hz stored in the same order > + as the clocks property. If this property is not defined or a value in the > + array is "0" then it is assumed that the frequency is set by the parent > + clock or a fixed rate clock source. > + > + interrupts: > + maxItems: 1 > + > + lanes-per-direction: > + $ref: /schemas/types.yaml#/definitions/uint32 > + enum: [1, 2] > + default: 2 > + description: > + Number of lanes available per direction. Note that it is assume same > + number of lanes is used both directions at once. > + > + vdd-hba-supply: > + description: > + Phandle to UFS host controller supply regulator node. > + > + vcc-supply: > + description: > + Phandle to VCC supply regulator node. > + > + vccq-supply: > + description: > + Phandle to VCCQ supply regulator node. > + > + vccq2-supply: > + description: > + Phandle to VCCQ2 supply regulator node. > + > + vcc-supply-1p8: > + type: boolean > + description: > + For embedded UFS devices, valid VCC range is 1.7-1.95V or 2.7-3.6V. This > + boolean property when set, specifies to use low voltage range of > + 1.7-1.95V. Note for external UFS cards this property is invalid and valid > + VCC range is always 2.7-3.6V. > + > + vcc-max-microamp: > + description: > + Specifies max. load that can be drawn from VCC supply. > + > + vccq-max-microamp: > + description: > + Specifies max. load that can be drawn from VCCQ supply. > + > + vccq2-max-microamp: > + description: > + Specifies max. load that can be drawn from VCCQ2 supply. > + > +dependencies: > + freq-table: [ 'clocks' ] > + > +required: > + - interrupts > + > +additionalProperties: true > diff --git a/MAINTAINERS b/MAINTAINERS > index aa0f6cbb634e..c2cff57d32f8 100644 > --- a/MAINTAINERS > +++ b/MAINTAINERS > @@ -20015,6 +20015,7 @@ R: Alim Akhtar > R: Avri Altman > L: linux-scsi@vger.kernel.org > S: Supported > +F: Documentation/devicetree/bindings/ufs/ > F: Documentation/scsi/ufs.rst > F: drivers/scsi/ufs/ > > -- > 2.32.0 > >