Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp1200757pxb; Wed, 4 Nov 2020 02:42:19 -0800 (PST) X-Google-Smtp-Source: ABdhPJwzOnLX+hA7wRG2LhJGfT0whoniXs2L+EbJqx+1qUUCuL+W3UUawHC66fnEWj2drjZkCH4L X-Received: by 2002:a50:e61a:: with SMTP id y26mr26762990edm.71.1604486538872; Wed, 04 Nov 2020 02:42:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1604486538; cv=none; d=google.com; s=arc-20160816; b=ikjYSntMRBK9e6hNQezBiZXW5vbZP2qM3ZA6nRGqWd8SUtCfzJ8GmvLbyInjU3e0BE EX2m5TSSaDIipKIA1p3naxDBCB8my0P35cpv0d+hgbLUvv02HkV4L9oh/L/5mr56pbOb Q7nlExtiyDbAamTlC68sI6xBhm0uDBzbQ+jDP+4F7LUQQ7SvFq/MnSKRiKP3tBkBvXxr B4qyJWpx4xoPwKdF6CQN/YflzOJRhMfwPLQho+JQPUeCFtWW8DrI7apG3ZbrkMlp+xHu jIp7wireXCvf76qYO45rAVyi6sJqXxTNja+4Ufzg/e1EL2yAI8bj5qvCsp34+5IdBPcS ei1Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=KCMVE5sU7/L068WwcGAz7fT+DI3RfrK837OuBw0Fpos=; b=cWFTChOyjzkX+5d1ZLHu6LejfI/Kc83W3TVE+ieYDCWJ5Ud0BkFAjT4x7i3pUv/G8B Z80VHmV5MX1Cr7UQvrPgH9XjCqisyIXAiiK65hAtx/aU6uYjXPCs/z+t8NwB8OTeqK6x dmwhc/V2lD/C7noYA+YosuIFpaO6iLl/WhPFMeXbaYnaB1g9wu2g1QvyZ0sAA9kIh6JK rGiYJr378zpjaQplaaxRuEahU6SA6TVbiLLo5QT9Xr2/xDYm793d5mfNn36kK0pNxL/e tKnpu2c2viam2NfnOntYAJPXSPape8bo1Aiky4+JzK9vlP2oPd/BYZ9OO4Gpm4GNaFee QldQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id dn20si1451761ejc.64.2020.11.04.02.41.56; Wed, 04 Nov 2020 02:42:18 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729870AbgKDKkK (ORCPT + 99 others); Wed, 4 Nov 2020 05:40:10 -0500 Received: from mx2.suse.de ([195.135.220.15]:58730 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729785AbgKDKkA (ORCPT ); Wed, 4 Nov 2020 05:40:00 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id F0319ACE5; Wed, 4 Nov 2020 10:39:58 +0000 (UTC) From: Nicolas Saenz Julienne To: u.kleine-koenig@pengutronix.de, linux-kernel@vger.kernel.org, Nicolas Saenz Julienne , Florian Fainelli , Ray Jui , Scott Branden , bcm-kernel-feedback-list@broadcom.com, Eric Anholt , Stefan Wahren Cc: linux-pwm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-input@vger.kernel.org, dmitry.torokhov@gmail.com, gregkh@linuxfoundation.org, devel@driverdev.osuosl.org, p.zabel@pengutronix.de, linux-gpio@vger.kernel.org, linus.walleij@linaro.org, linux-clk@vger.kernel.org, sboyd@kernel.org, linux-rpi-kernel@lists.infradead.org, bgolaszewski@baylibre.com, andy.shevchenko@gmail.com, Rob Herring , Rob Herring Subject: [PATCH v3 09/11] dt-bindings: pwm: Add binding for RPi firmware PWM bus Date: Wed, 4 Nov 2020 11:39:35 +0100 Message-Id: <20201104103938.1286-10-nsaenzjulienne@suse.de> X-Mailer: git-send-email 2.29.1 In-Reply-To: <20201104103938.1286-1-nsaenzjulienne@suse.de> References: <20201104103938.1286-1-nsaenzjulienne@suse.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The PWM bus controlling the fan in RPi's official PoE hat can only be controlled by the board's co-processor. Signed-off-by: Nicolas Saenz Julienne Reviewed-by: Rob Herring --- Changes since v1: - Update bindings to use 2 #pwm-cells .../arm/bcm/raspberrypi,bcm2835-firmware.yaml | 20 +++++++++++++++++++ .../pwm/raspberrypi,firmware-pwm.h | 13 ++++++++++++ 2 files changed, 33 insertions(+) create mode 100644 include/dt-bindings/pwm/raspberrypi,firmware-pwm.h diff --git a/Documentation/devicetree/bindings/arm/bcm/raspberrypi,bcm2835-firmware.yaml b/Documentation/devicetree/bindings/arm/bcm/raspberrypi,bcm2835-firmware.yaml index a2c63c8b1d10..8029ce958c48 100644 --- a/Documentation/devicetree/bindings/arm/bcm/raspberrypi,bcm2835-firmware.yaml +++ b/Documentation/devicetree/bindings/arm/bcm/raspberrypi,bcm2835-firmware.yaml @@ -64,6 +64,21 @@ properties: - compatible - "#reset-cells" + pwm: + type: object + + properties: + compatible: + const: raspberrypi,firmware-pwm + + "#pwm-cells": + # See pwm.yaml in this directory for a description of the cells format. + const: 2 + + required: + - compatible + - "#pwm-cells" + additionalProperties: false required: @@ -87,5 +102,10 @@ examples: compatible = "raspberrypi,firmware-reset"; #reset-cells = <1>; }; + + pwm: pwm { + compatible = "raspberrypi,firmware-pwm"; + #pwm-cells = <1>; + }; }; ... diff --git a/include/dt-bindings/pwm/raspberrypi,firmware-pwm.h b/include/dt-bindings/pwm/raspberrypi,firmware-pwm.h new file mode 100644 index 000000000000..27c5ce68847b --- /dev/null +++ b/include/dt-bindings/pwm/raspberrypi,firmware-pwm.h @@ -0,0 +1,13 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +/* + * Copyright (c) 2020 Nicolas Saenz Julienne + * Author: Nicolas Saenz Julienne + */ + +#ifndef _DT_BINDINGS_RASPBERRYPI_FIRMWARE_PWM_H +#define _DT_BINDINGS_RASPBERRYPI_FIRMWARE_PWM_H + +#define RASPBERRYPI_FIRMWARE_PWM_POE 0 +#define RASPBERRYPI_FIRMWARE_PWM_NUM 1 + +#endif -- 2.29.1