Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754050AbcLKWW6 (ORCPT ); Sun, 11 Dec 2016 17:22:58 -0500 Received: from mail-wj0-f169.google.com ([209.85.210.169]:34162 "EHLO mail-wj0-f169.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754023AbcLKWWx (ORCPT ); Sun, 11 Dec 2016 17:22:53 -0500 From: Bartosz Golaszewski To: Jonathan Cameron , Hartmut Knaack , Lars-Peter Clausen , Peter Meerwald-Stadler , Rob Herring , Mark Rutland Cc: linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Kevin Hilman , Patrick Titiano , Neil Armstrong , Linus Walleij , Alexandre Courbot , linux-gpio@vger.kernel.org, Sebastian Reichel , linux-pm@vger.kernel.org, Mark Brown , Liam Girdwood , Bartosz Golaszewski Subject: [PATCH 1/2] devicetree: power: add bindings for GPIO-driven power switches Date: Sun, 11 Dec 2016 23:21:44 +0100 Message-Id: <1481494905-18037-2-git-send-email-bgolaszewski@baylibre.com> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1481494905-18037-1-git-send-email-bgolaszewski@baylibre.com> References: <1481494905-18037-1-git-send-email-bgolaszewski@baylibre.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1415 Lines: 44 Some boards are equipped with simple, GPIO-driven power load switches. An example of such ICs is the TI tps229* series. Add device tree bindings allowing to describe them. Signed-off-by: Bartosz Golaszewski --- .../bindings/power/gpio-power-switch.txt | 25 ++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 Documentation/devicetree/bindings/power/gpio-power-switch.txt diff --git a/Documentation/devicetree/bindings/power/gpio-power-switch.txt b/Documentation/devicetree/bindings/power/gpio-power-switch.txt new file mode 100644 index 0000000..21420ed --- /dev/null +++ b/Documentation/devicetree/bindings/power/gpio-power-switch.txt @@ -0,0 +1,25 @@ +GPIO Power Switch +----------------- + +This is the device tree binding for simple, GPIO-driven power load switches +that do not have any control signals. + +Required properties: + +- compatible: must be "gpio-power-switch" +- power-gpios: phandle for the GPIO driving the power load switch + +Optional properties: + +- power-switch-name: the name of the power switch +- power-switch-on: the power switch GPIO is driven high by default + +Example +------- + +acme_probe0_power_switch: gpio_power_switch@0 { + compatible = "gpio-power-switch"; + power-switch-name = "acme_probe0_switch"; + power-gpios = <&pca9535 1 GPIO_ACTIVE_HIGH>; + power-switch-on; +}; -- 2.9.3