From patchwork Sun Sep 2 11:20:50 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Wahren X-Patchwork-Id: 10585101 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 20129112B for ; Sun, 2 Sep 2018 11:23:05 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0DC3029B12 for ; Sun, 2 Sep 2018 11:23:05 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 00FC229B17; Sun, 2 Sep 2018 11:23:04 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 9A4D829B12 for ; Sun, 2 Sep 2018 11:23:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=iVBLl2Q5eYnS322IIlVHjFl+II90juwAdJfFKv6oMbo=; b=uyvez+UCpSN6Mxz2n+0GEmmdh+ 8Lkc567rEHu8iKs3h4sCUP7xofhwT5TBk0ex8XdNbeliJIPcRa2Pkl/8MM41mFSuj8Q3TW2ybJ/B6 4Wdw/+xezhts3CEv6crLPPZTE/OqYhVZsOGiu3P2KJ9R3PB7VE8J+Qt1RpUj7Exn4ygaxUh5StOJq j7WiLgb8qSPVXeGwfQuB+taz34bu4MKpNcdT7lnPdaFjHe+95kWZo6K5xl8qVSCh+/vSwIV+cRsLc U1ZkaB4ekdO+wioHwNmkOboeSDX0WMDOa2j4hHAHTnXvY+glYEQNP1KQ9vSv0rj6zKj9dyHBQT2V/ 67n6yZEQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1fwQSz-0007oB-I1; Sun, 02 Sep 2018 11:22:53 +0000 Received: from mout.kundenserver.de ([212.227.17.13]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1fwQSv-0007mN-S7; Sun, 02 Sep 2018 11:22:51 +0000 Received: from localhost.localdomain ([37.4.249.97]) by mrelayeu.kundenserver.de (mreue101 [212.227.15.183]) with ESMTPSA (Nemesis) id 0Lto9d-1foGzV4Bin-011CkK; Sun, 02 Sep 2018 13:22:09 +0200 From: Stefan Wahren To: Jean Delvare , Guenter Roeck , Rob Herring , Mark Rutland Subject: [PATCH RFC 1/2] dt-bindings: hwmon: Add RPi PoE HAT documentation Date: Sun, 2 Sep 2018 13:20:50 +0200 Message-Id: <1535887251-29515-2-git-send-email-stefan.wahren@i2se.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1535887251-29515-1-git-send-email-stefan.wahren@i2se.com> References: <1535887251-29515-1-git-send-email-stefan.wahren@i2se.com> X-Provags-ID: V03:K1:Ku1nXBUEdOGG1UKn5ilmpK5YyJcJ6n2Hc1c/XEItZkVmCDRfl6M U3hkWviUQwLQ1PSS9/5ZZ30R2T/QcLK+2Mbk7cVjfR+Ymetu32LRYKyOEnC8QfnVY9zcARI rr2vL79LxzPR3mUQCOxjQJKxv1+mjhbN+tgIhxxgO2c/Zlbx+XwfBrEdlV8DD0qvl7aGveP 32EY8Bz0EqypGTTI4sqFA== X-UI-Out-Filterresults: notjunk:1;V01:K0:LSzvHORPa3Y=:X9dY7x8IgEfx4+R2si96BS /lIisIrvETvEpHpJgMnCVpbgO0iRNwD6U7sz+DAqMfz/Dt3WzO/1LN1YyAsC6+pg4pAZu+k5m GOttbF+ow+KEaFev/npqDoj/YPaknLC7yVDzdAsi676EceGa3rx+ZfbREbm7GkEAV7+TU2FpK 4aUDrqAhNa0tBd38HJ2LQWxlWZrZP9mK6/NYEkiBEwzV9wJhvTVwFJyYvcLzDA8SiIP7xGuEq I5vO8K3CoEUhhIa2GlHBbOG7dtpfWXLYlvHmWQRmy6PeO1IXSTmhJsbxb2SkkzEd5JsWvIogv gK3RGo1DSIplcCnwikSa7KQ1ON9cMKXX5w7woi8+kTiY7dx+a//MkWApzYxVZNTd6tdp5k6mT 3Aj5UCV78pLdPC3F3NtSBG2PpTg0DwQRFxkLuuj4KMAPIyip+cR/LJ2viqsup/e1co3z9qwii OhOVe1JdsF4BHWPc02lVuAvQ7IgG7QsY6uXfDqb7NuBbTK4fMJ2IttmuuZ2CNySvO9L9CpHRG K+yDPawBQADRs08CKHrW6kfjVfpC7CRmKPcTEnda3CQHA9Z5BMfLIqzPuBpy7f3oFKg+0L1PM H45gw/9HlAhgR06YTLEB2WRnrH9NtobLRaIEnRS2/Q51tz8zONcbMU0TzZolZ6Wy5HX/aQ3gi rVeU3/yo709xBzluPGfqafU92mpjS2+A4k2Baa76ORuwCmhKkNruva5hFSgyMQkOxwa0= X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180902_042250_216365_A3631A5D X-CRM114-Status: GOOD ( 16.92 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-hwmon@vger.kernel.org, devicetree@vger.kernel.org, Florian Fainelli , Serge Schneider , Stefan Wahren , Phil Elwell , linux-kernel@vger.kernel.org, Eric Anholt , bcm-kernel-feedback-list@broadcom.com, linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP From: Serge Schneider This patch adds the binding for the fan on the Raspberry Pi Power over Ethernet HAT. Signed-off-by: Serge Schneider Signed-off-by: Stefan Wahren --- .../devicetree/bindings/hwmon/rpi-poe-fan.txt | 55 ++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 Documentation/devicetree/bindings/hwmon/rpi-poe-fan.txt diff --git a/Documentation/devicetree/bindings/hwmon/rpi-poe-fan.txt b/Documentation/devicetree/bindings/hwmon/rpi-poe-fan.txt new file mode 100644 index 0000000..c71f856 --- /dev/null +++ b/Documentation/devicetree/bindings/hwmon/rpi-poe-fan.txt @@ -0,0 +1,55 @@ +Bindings for the Raspberry Pi PoE HAT fan + +Required properties: +- compatible : "raspberrypi,rpi-poe-fan" +- firmware : Reference to the RPi firmware device node +- pwms : the PWM that is used to control the PWM fan +- cooling-levels : PWM duty cycle values in a range from 0 to 255 + which correspond to thermal cooling states + +Example: + fan0: rpi-poe-fan@0 { + compatible = "raspberrypi,rpi-poe-fan"; + firmware = <&firmware>; + cooling-min-state = <0>; + cooling-max-state = <3>; + #cooling-cells = <2>; + cooling-levels = <0 50 150 255>; + status = "okay"; + }; + + thermal-zones { + cpu_thermal: cpu-thermal { + trips { + threshold: trip-point@0 { + temperature = <45000>; + hysteresis = <5000>; + type = "active"; + }; + target: trip-point@1 { + temperature = <50000>; + hysteresis = <2000>; + type = "active"; + }; + cpu_hot: cpu_hot@0 { + temperature = <55000>; + hysteresis = <2000>; + type = "active"; + }; + }; + cooling-maps { + map0 { + trip = <&threshold>; + cooling-device = <&fan0 0 1>; + }; + map1 { + trip = <&target>; + cooling-device = <&fan0 1 2>; + }; + map2 { + trip = <&cpu_hot>; + cooling-device = <&fan0 2 3>; + }; + }; + }; + };