From patchwork Fri Mar 3 09:14:48 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Carlo Caione X-Patchwork-Id: 9602459 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 6856A60453 for ; Fri, 3 Mar 2017 10:08:04 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5A82D285ED for ; Fri, 3 Mar 2017 10:08:04 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 4F1D1285FF; Fri, 3 Mar 2017 10:08: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=-6.3 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A459B285ED for ; Fri, 3 Mar 2017 10:08:03 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751568AbdCCKHu (ORCPT ); Fri, 3 Mar 2017 05:07:50 -0500 Received: from mail-wm0-f67.google.com ([74.125.82.67]:36676 "EHLO mail-wm0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751463AbdCCKHr (ORCPT ); Fri, 3 Mar 2017 05:07:47 -0500 Received: by mail-wm0-f67.google.com with SMTP id v190so2314304wme.3 for ; Fri, 03 Mar 2017 02:07:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=PLkhC9arvMFV9pLbYMPm8h33LE4xb6YWV3p2f1YIMz4=; b=FDwLMoCAicgxfCRU2UqDHZdS02v0uESE+ZlHwVeX7M7kEPez9cv66nVlYe8ZI3TAGa 3STam309nZIVjSpIxy6x/n0L8/d4afsfKjbteIXR7gFUJw7sS/dMs1704QblgE123Mtw oC67pnatLSpmHaS+GeUNPxJk0J7CZDW3+2AkE90sU1HnMAhUB2m4pC7cpowsv79/aziQ IpzRm8c1qlc5WJ2Y5D9jc2wENpcwDDz+bab5tBM49LFtWkGOgKa6QlxTnzPqwBRgukBZ 8IyWI3Zu0Mq9zluZUnrf3gfoMRU8D9hkJVQVomv3GOLBmPIENigjBNBvnU4D2xZs4Azo 9Mmg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=PLkhC9arvMFV9pLbYMPm8h33LE4xb6YWV3p2f1YIMz4=; b=d3tOVKXak1oyBcw9uJ84nwt2pkuAZWGJD/vIOmV6ZVEZsjP5SMKNzExwqG0gSA/+ux iDQbJDjwd+YGkIXbBctEcZCoIkdRsGhqqtnVKyrFVJodPrctb+42Ve+OgGSGj0rQhWlw HlczNHDJ++86RvGZvKYA6UwNGwsmaSvcEjDwZc7d9Ld3jnKEIhupuxZGNhPb7NJTp/Hd EuTKb4+DkWb4Ko6eHG0tZTnMYBcnY8S8Bz5nh/Ci6+Vli5s14+l4AXt+V4qebfPSPJSW 9/cu1ExA8ALETePj627gKPfIDXwDuJJfe/bDjWZRCfMPBh1gKiCOrSDSMRsfl9PB9gzq BEmg== X-Gm-Message-State: AMke39kxLR65z9V89o2WIS5ucC4XadgwC8bmqs9c+2jn8vRFMYmqnHSK/kcjUbooLT4tKQ== X-Received: by 10.28.111.3 with SMTP id k3mr1624494wmc.39.1488531905597; Fri, 03 Mar 2017 01:05:05 -0800 (PST) Received: from satan.homestation.setup ([151.45.79.45]) by smtp.gmail.com with ESMTPSA id z198sm2189747wmz.24.2017.03.03.01.05.04 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 03 Mar 2017 01:05:05 -0800 (PST) From: Carlo Caione To: jdelvare@suse.com, linux@roeck-us.net, linux-hwmon@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-amlogic@lists.infradead.org, linux@endlessm.com, punit.agrawal@arm.com, sudeep.holla@arm.com, robh+dt@kernel.org Cc: Carlo Caione Subject: [PATCH v2 1/2] Documentation: bindings: Introduce scpi, sensors-scale Date: Fri, 3 Mar 2017 10:14:48 +0100 Message-Id: <20170303091449.3512-2-carlo@caione.org> X-Mailer: git-send-email 2.12.0 In-Reply-To: <20170303091449.3512-1-carlo@caione.org> References: <20170303091449.3512-1-carlo@caione.org> Sender: linux-hwmon-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-hwmon@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Carlo Caione Document the new property `scpi,sensors-scale` used by the hwmon-scpi driver to convert the sensor readings to the correct / expected scale. Signed-off-by: Carlo Caione --- Documentation/devicetree/bindings/arm/arm,scpi.txt | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/Documentation/devicetree/bindings/arm/arm,scpi.txt b/Documentation/devicetree/bindings/arm/arm,scpi.txt index 401831973638..35c621ce52c5 100644 --- a/Documentation/devicetree/bindings/arm/arm,scpi.txt +++ b/Documentation/devicetree/bindings/arm/arm,scpi.txt @@ -84,6 +84,24 @@ Required properties: as used by the firmware. Refer to platform details for your implementation for the IDs to use. +Optional properties: +- scpi,sensors-scale: array of 5 elements defining the unit scale used by the + SCP for the 5 different sensor classes (temperature, + voltage, current, power, energy) such that 1 == unit, + 1000 == milli, 1000000 == micro, ... + + Example: + scpi,sensors-scale = <1 1000 1000 1000000 1000000> + In this case the values reported by SCP are: + -> temperature in degree Celsius + -> voltage in millivolts + -> current in milliamperes + -> power in microwatts + -> energy in microjoules + + The default value is: + scpi,sensors-scale = <1000 1000 1000 1000000 1000000> + Power domain bindings for the power domains based on SCPI Message Protocol ------------------------------------------------------------