Received: by 2002:a25:824b:0:0:0:0:0 with SMTP id d11csp6922776ybn; Mon, 30 Sep 2019 06:04:02 -0700 (PDT) X-Google-Smtp-Source: APXvYqwPkWX2a8xDDBvJlyfxS5dymYClDdhUfa43AQjiK1/jy9m+6aCegp1OBNn4sfvUJZhS6YYe X-Received: by 2002:a05:600c:22d9:: with SMTP id 25mr16148977wmg.133.1569848642494; Mon, 30 Sep 2019 06:04:02 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1569848642; cv=none; d=google.com; s=arc-20160816; b=CVlNAnYB23/sjZ6naI5TjlKbfgvYl/d7IH0EN4qtkXNPGXkHTZ1ti0hkqITvUZH8qx 16PDWIXubDNBTn0ZRCpirwq5emtD+i3j1axJahj//CeFNxfXufnh42qkGQsOiNnrVoF3 hBEkd/OHX6vRg26S86rvPZ4SqkXeByPFt/KnzQinIeG1IK9jnC0O3qgdvNypiL84YlZ5 kFae6rbqjcrxNy/pjAvnkpm4m8oM83i650osmkBnk5KrRKk4pKS0tnpEZ0UF/KERArxN E0v7oSeZENcbkJkGTf+6gBdRdnp8H9iYUey2s6O13Y+2baHpuX/eNhm0ojDM0wS2Pni+ c09w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=zCXYF953/vPYwz7eiQFUSs/AEguNESyV96474n4IASY=; b=hFLRtfrmr0jtX1Zjjdk/UDS0bhPVYEhAkHZ2ID0fh/PloL5sHv0Z66YpCVYSwUMpoH gRXmc90mG+AcRke673IHV5YpSd3sQKIDCeO3M9u27AUxfryZEzcTjA5x8Wdn+Ygl9JMn /fqtDtptjg+vnrl8hZ6YLgR0YfUi50nSGidroJ5VWubmoCH2PwFaA/pBlHrydiKlmuCw kKoiQlRa0bbWbJrqpFdrvwKmxSylOdjfW5hJ0A1fRlWci2iZb5ZuMCFv/ir8VlMKQoYx Oew6gZ49RNZOHcKIrpv+vdhY+DSskd1zGzmJw/1aHIe3FAt+uAXTGizWOUV9i6/ErOp+ tiyA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bgdev-pl.20150623.gappssmtp.com header.s=20150623 header.b=Nf+gaIXC; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s7si7338395edd.290.2019.09.30.06.03.37; Mon, 30 Sep 2019 06:04:02 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@bgdev-pl.20150623.gappssmtp.com header.s=20150623 header.b=Nf+gaIXC; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731143AbfI3NDQ (ORCPT + 99 others); Mon, 30 Sep 2019 09:03:16 -0400 Received: from mail-wm1-f66.google.com ([209.85.128.66]:36427 "EHLO mail-wm1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731104AbfI3NDH (ORCPT ); Mon, 30 Sep 2019 09:03:07 -0400 Received: by mail-wm1-f66.google.com with SMTP id m18so12663692wmc.1 for ; Mon, 30 Sep 2019 06:03:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bgdev-pl.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=zCXYF953/vPYwz7eiQFUSs/AEguNESyV96474n4IASY=; b=Nf+gaIXC0Ge/0BwRg9S/STvB6+9x02OEyJfwicPnb2ADufpdrmo1vfw+tYoQLsxxJ5 5J4EjdPlP0rFxxFSexrYwZzTo5oXdX5EwgyQfHg9F21ZI9v8b1j4wtWm6C0VIUNaVB7f z2hYt7MBqAbNQkf+phMS5i3LywrehGo3y8a5z1RaPZ82gsF/Bx2JD+DMo6vou7CPXzQN sya1shbs/pjzjbzKs/nJ488uwxA1KCYAeLAuoz6h+eKPxL+q+fvymMKKxpOJ5LcM2xQ5 3lSJJtz8j500+wft6PJYCtXXQ0QVa7CIuyQJOBbLKodGskE+BYV1vVN5uBLG3an/yC6E C99Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=zCXYF953/vPYwz7eiQFUSs/AEguNESyV96474n4IASY=; b=OJHbI5ChAVAK1A5unTYkBBaCpxos4+ABFPCJm8kxP9qBW7pHA2Ul2kGV7fgBOMTqy4 mhj3CHt0ka1D+ap1cvq67o9eNc9V+cCeUZP2lHGFrDRX7bJXeH9jLbnI05kxq5AFlgRB D4JfIGq9NHJkmbRaQMvhAvYdPdgr2+B3Vr/jCLuDhc3X21RX4gLy29JSupb4M2QPFytq lr9EoBVJVPbvgAqY9zYd7u6j56WHMDUwgRQBYTPfErBTxz47zpO1Co+gymcQZZpaP7rk D/CTMDM3ALOXvlEK1PMdG60A9ncvCKrusg/KA4LdSJ0BuvXS/ybW3AjzKhkpwdhM+gke DF6w== X-Gm-Message-State: APjAAAWQ1/C67lKvrZ8oWLUNehDUYujlrbQGwssz3cRuAJpeic/aOmlm iZoKN7ajig613ZqKr/6e/i/okg== X-Received: by 2002:a05:600c:238a:: with SMTP id m10mr18382086wma.51.1569848583334; Mon, 30 Sep 2019 06:03:03 -0700 (PDT) Received: from localhost.localdomain (amontpellier-652-1-281-69.w109-210.abo.wanadoo.fr. [109.210.96.69]) by smtp.gmail.com with ESMTPSA id e6sm10654756wrp.91.2019.09.30.06.03.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 30 Sep 2019 06:03:02 -0700 (PDT) From: Bartosz Golaszewski To: Rob Herring , Mark Rutland , Dmitry Torokhov , Jacek Anaszewski , Pavel Machek , Dan Murphy , Lee Jones , Sebastian Reichel , Liam Girdwood , Mark Brown Cc: linux-input@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-leds@vger.kernel.org, linux-pm@vger.kernel.org, Bartosz Golaszewski Subject: [PATCH 5/6] dt-bindings: leds: max77650: convert the binding document to yaml Date: Mon, 30 Sep 2019 15:02:45 +0200 Message-Id: <20190930130246.4860-6-brgl@bgdev.pl> X-Mailer: git-send-email 2.23.0 In-Reply-To: <20190930130246.4860-1-brgl@bgdev.pl> References: <20190930130246.4860-1-brgl@bgdev.pl> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Bartosz Golaszewski Convert the binding document for max77650 LED module to yaml. Signed-off-by: Bartosz Golaszewski --- .../bindings/leds/leds-max77650.txt | 58 +------------ .../bindings/leds/leds-max77650.yaml | 82 +++++++++++++++++++ 2 files changed, 83 insertions(+), 57 deletions(-) create mode 100644 Documentation/devicetree/bindings/leds/leds-max77650.yaml diff --git a/Documentation/devicetree/bindings/leds/leds-max77650.txt b/Documentation/devicetree/bindings/leds/leds-max77650.txt index 3a67115cc1da..33d6ff23f0ef 100644 --- a/Documentation/devicetree/bindings/leds/leds-max77650.txt +++ b/Documentation/devicetree/bindings/leds/leds-max77650.txt @@ -1,57 +1 @@ -LED driver for MAX77650 PMIC from Maxim Integrated. - -This module is part of the MAX77650 MFD device. For more details -see Documentation/devicetree/bindings/mfd/max77650.txt. - -The LED controller is represented as a sub-node of the PMIC node on -the device tree. - -This device has three current sinks. - -Required properties: --------------------- -- compatible: Must be "maxim,max77650-led" -- #address-cells: Must be <1>. -- #size-cells: Must be <0>. - -Each LED is represented as a sub-node of the LED-controller node. Up to -three sub-nodes can be defined. - -Required properties of the sub-node: ------------------------------------- - -- reg: Must be <0>, <1> or <2>. - -Optional properties of the sub-node: ------------------------------------- - -- label: See Documentation/devicetree/bindings/leds/common.txt -- linux,default-trigger: See Documentation/devicetree/bindings/leds/common.txt - -For more details, please refer to the generic GPIO DT binding document -. - -Example: --------- - - leds { - compatible = "maxim,max77650-led"; - #address-cells = <1>; - #size-cells = <0>; - - led@0 { - reg = <0>; - label = "blue:usr0"; - }; - - led@1 { - reg = <1>; - label = "red:usr1"; - linux,default-trigger = "heartbeat"; - }; - - led@2 { - reg = <2>; - label = "green:usr2"; - }; - }; +This file has been moved to leds-max77650.yaml. diff --git a/Documentation/devicetree/bindings/leds/leds-max77650.yaml b/Documentation/devicetree/bindings/leds/leds-max77650.yaml new file mode 100644 index 000000000000..bb541ff67f80 --- /dev/null +++ b/Documentation/devicetree/bindings/leds/leds-max77650.yaml @@ -0,0 +1,82 @@ +# SPDX-License-Identifier: GPL-2.0 +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/leds/leds-max77650.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: LED driver for MAX77650 PMIC from Maxim Integrated. + +maintainers: + - Bartosz Golaszewski + +description: | + This module is part of the MAX77650 MFD device. For more details + see Documentation/devicetree/bindings/mfd/max77650.txt. + + The LED controller is represented as a sub-node of the PMIC node on + the device tree. + + This device has three current sinks. + +properties: + compatible: + const: maxim,max77650-led + + "#address-cells": + const: 1 + + "#size-cells": + const: 0 + +patternProperties: + "^led@[0-2]$": + type: object + description: | + Properties for a single LED. + + properties: + reg: + description: + Index of the LED. + maxItems: 1 + minimum: 0 + maximum: 2 + + label: + $ref: "/schemas/types.yaml#/definitions/string" + description: + The label of this LED. + + linux,default-trigger: + $ref: "/schemas/types.yaml#/definitions/string" + description: + String defining the default trigger assigned to this LED. + +required: + - compatible + - "#address-cells" + - "#size-cells" + +examples: + - | + leds { + compatible = "maxim,max77650-led"; + #address-cells = <1>; + #size-cells = <0>; + + led@0 { + reg = <0>; + label = "blue:usr0"; + }; + + led@1 { + reg = <1>; + label = "red:usr1"; + linux,default-trigger = "heartbeat"; + }; + + led@2 { + reg = <2>; + label = "green:usr2"; + }; + }; -- 2.23.0