Received: by 2002:a05:7412:3784:b0:e2:908c:2ebd with SMTP id jk4csp1406673rdb; Mon, 2 Oct 2023 08:36:52 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHgWU4Na7Ha6STya9q6/xuXqRpyw5nDrQaoq9VT2YNGDWUF/a67aH8KrmcIf2JTW49nz3rT X-Received: by 2002:a92:c26a:0:b0:350:e9c6:e765 with SMTP id h10-20020a92c26a000000b00350e9c6e765mr15122016ild.11.1696261011804; Mon, 02 Oct 2023 08:36:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1696261011; cv=none; d=google.com; s=arc-20160816; b=RSlfMbmMPE4/lWQb6R6Nt4C5s8MrIrYdeuAqoVpRxS927lS8nDgea72yrZWn6S8g++ py+mEKe+aVxUSIjVzqPy3FWTJhBFLGcRHtL90SvrXZdDqXqi2lheNmktzlKIn12oAo8Z ZVb7QK6RvL0OJYL0KXUF/0sif/h5JJe2GX/IRq6W0Tk1lYNQB0+ksW/kTtjVncPTmTSS xgyV7NKf8qeT1+r+q7oS6E244c6BRyptg5FfgRUhYskBokxt/XJwg/mOz+DUNmYUxK/c 3bEYaJCZF6ZqkbeUMDPEMkkhqi5I5Ie/SI8JaVCF5RI6hZe1rKGtc1InT2MQ47HaHa4b YL2Q== 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:dkim-signature; bh=cfvvMqZE3jNDUca628dGeLTog+NID/yKRuDWds7v6uc=; fh=6AangfxU43vUa0ZZxVC0a6nWPgsYpVdF3gzht5tCK9Q=; b=VTWP/wFMt3DQc7/dLiEct0vW/z5pZPtbWKAPHbxDRnzp6+6/Q7gcgzXBFWO95URN5o sgaVZNZox0urIVklwQdlo2CkkkS7N2UjIjRTX2Ak4Dq3r3u/EPfT8gFa94ggg9dxuLzg 6s/wasV+hdJaLyMpv24cU715/6qNBkP29phDb1kWAcg5TQRGn0ZpkXQbQETTqotOhNjW syBwVlPNtwCw74tIvEOwR3YF5H5sNeoF428y/w1omQf+/csiVFUX0KQo48xdhf++Lf6D skuO5JJj7bbDK9qaRC00RNVr1dENr0R2p0BafJLDNpEHCV0EVV3/wUFaAcaz7mM0Q0e+ 3+zA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=hPStttAf; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 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 groat.vger.email (groat.vger.email. [23.128.96.35]) by mx.google.com with ESMTPS id a18-20020a63d412000000b00569561773a6si27340953pgh.549.2023.10.02.08.36.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 02 Oct 2023 08:36:51 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) client-ip=23.128.96.35; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=hPStttAf; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 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 out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id EEBA6809F3A0; Mon, 2 Oct 2023 08:24:06 -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 S238073AbjJBPXv (ORCPT + 99 others); Mon, 2 Oct 2023 11:23:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50328 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237877AbjJBPXt (ORCPT ); Mon, 2 Oct 2023 11:23:49 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 880E4D8; Mon, 2 Oct 2023 08:23:46 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 5D0BCC433C7; Mon, 2 Oct 2023 15:23:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1696260226; bh=J31MH8/2r2BMfbJUBh+R459Cp6pdTI0Bsk+3NWVzrsE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=hPStttAfTWc+lyohHbX38wiESvCZgMH8ITKZQzHcHdm8G7UCp7Q5ImGYlldQGDmwi JIh2c8/pTqJ9a5pQ3NhFY5MyAysWRzFmSLK7X6uevHewo8kIHvFqKI3FTqgCgMsYXe tsrNuodOO+IXVlt+OKJEsk+m2tAC3V5suY4SDpR6BRTAfxHVR4q3imCOiGoVS5Lh5G yl9Gr2QCptI3ctd6eYSpy9H/998tREUU18ydMG1t2acp89rKMAtxzSXe5yZ8IFFyMG SK15YA+ffl5SMze3JNikC4t3pYswRTXVrWrQ9z/bqAf/vDpvm3RhKRBW+PJ319123s w4RiwFX/fxsdw== Received: (nullmailer pid 1752918 invoked by uid 1000); Mon, 02 Oct 2023 15:23:43 -0000 Date: Mon, 2 Oct 2023 10:23:43 -0500 From: Rob Herring To: Billy Tsai Cc: jdelvare@suse.com, linux@roeck-us.net, krzysztof.kozlowski+dt@linaro.org, joel@jms.id.au, andrew@aj.id.au, corbet@lwn.net, thierry.reding@gmail.com, u.kleine-koenig@pengutronix.de, p.zabel@pengutronix.de, naresh.solanki@9elements.com, linux-hwmon@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-aspeed@lists.ozlabs.org, linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, linux-pwm@vger.kernel.org, BMC-SW@aspeedtech.com, patrick@stwcx.xyz Subject: Re: [PATCH v9 1/3] dt-bindings: hwmon: fan: Add fan binding to schema Message-ID: <20231002152343.GA1747496-robh@kernel.org> References: <20230918064111.2221594-1-billy_tsai@aspeedtech.com> <20230918064111.2221594-2-billy_tsai@aspeedtech.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230918064111.2221594-2-billy_tsai@aspeedtech.com> X-Spam-Status: No, score=-1.2 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,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]); Mon, 02 Oct 2023 08:24:07 -0700 (PDT) On Mon, Sep 18, 2023 at 02:41:09PM +0800, Billy Tsai wrote: > From: Naresh Solanki > > Add common fan properties bindings to a schema. > > Bindings for fan controllers can reference the common schema for the > fan > > child nodes: > > patternProperties: > "^fan@[0-2]": > type: object > $ref: fan-common.yaml# > unevaluatedProperties: false > > Signed-off-by: Naresh Solanki > Signed-off-by: Billy Tsai > --- > .../devicetree/bindings/hwmon/fan-common.yaml | 78 +++++++++++++++++++ > 1 file changed, 78 insertions(+) > create mode 100644 Documentation/devicetree/bindings/hwmon/fan-common.yaml > > diff --git a/Documentation/devicetree/bindings/hwmon/fan-common.yaml b/Documentation/devicetree/bindings/hwmon/fan-common.yaml > new file mode 100644 > index 000000000000..2bd2f57fc9d9 > --- /dev/null > +++ b/Documentation/devicetree/bindings/hwmon/fan-common.yaml > @@ -0,0 +1,78 @@ > +# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause > +%YAML 1.2 > +--- > +$id: http://devicetree.org/schemas/hwmon/fan-common.yaml# > +$schema: http://devicetree.org/meta-schemas/core.yaml# > + > +title: Common Fan Properties > + > +maintainers: > + - Naresh Solanki > + - Billy Tsai > + > +properties: > + max-rpm: > + description: > + Max RPM supported by fan. > + $ref: /schemas/types.yaml#/definitions/uint32 > + maximum: 100000 > + > + min-rpm: > + description: > + Min RPM supported by fan. > + $ref: /schemas/types.yaml#/definitions/uint32 > + maximum: 1000 > + > + pulses-per-revolution: > + description: > + The number of pulse from fan sensor per revolution. > + $ref: /schemas/types.yaml#/definitions/uint32 > + maximum: 4 > + > + tach-div: > + description: > + Divisor for the tach sampling clock, which determines the sensitivity of the tach pin. > + $ref: /schemas/types.yaml#/definitions/uint32 > + > + target-rpm: > + description: > + The default desired fan speed in RPM. > + $ref: /schemas/types.yaml#/definitions/uint32 > + > + fan-driving-mode: > + description: > + Select the driving mode of the fan.(DC, PWM and so on) > + $ref: /schemas/types.yaml#/definitions/uint32 What value corresponds to what mode? I'd do strings instead. 'dc', 'pwm', etc. > + > + pwms: > + description: > + PWM provider. > + maxItems: 1 > + > + "#cooling-cells": > + const: 2 > + > + cooling-levels: > + description: | Don't need '|' > + The control value which correspond to thermal cooling states. > + $ref: /schemas/types.yaml#/definitions/uint32-array > + > + tach-ch: > + description: > + The tach channel used for the fan. > + $ref: /schemas/types.yaml#/definitions/uint8-array > + > + label: > + description: > + Optional fan label > + > + fan-supply: > + description: > + Power supply for fan. > + > + reg: > + maxItems: 1 > + > +additionalProperties: true > + > +... > -- > 2.25.1 >