Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp628607ybi; Fri, 26 Jul 2019 16:19:44 -0700 (PDT) X-Google-Smtp-Source: APXvYqwlDG+iba8qQSJCThehXNr+OFbV6m3JAavpsmkpSCDEpxe6A9sRm6vxz93auebnOLbQna5V X-Received: by 2002:a63:f357:: with SMTP id t23mr40923883pgj.421.1564183184561; Fri, 26 Jul 2019 16:19:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1564183184; cv=none; d=google.com; s=arc-20160816; b=P2jtcNNk/OgTnAW7mZ5YeuoaQ7BGcReBCtE8ssK5Cm9Bjzfzxoiv/Cu2cpUTRRS8jz 81vkcBOqBx79jANVqF6IqnblvTtOluhbJY75VP/ygRqrN3zb+gEkGnCJHH4WqTYpyML9 g1PqPs3ZOC8e5dNYrTX+rkcSRcMjwDDlx64K6aI1NL6pgILXRn9LYWpbcBe1oFQcXNpj IibZvlL3/Vq34IIAncPMeBY6cNHbhXKGqFWYV6lN6tQnLyYvfBIWo3GV/H/aVVYPUIpX rf/CDuI0UKT0pmq3HyfmpGhRhXuafHvWWQaqZK/d5D9HNDp6vM+uowu2SacSaq0uNPYa LlrA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=fvblglzKUkRQdPO0Yb7i2Y0PJEPJNg4TUOo5jaX/DnE=; b=RrJhm+gE+K8taCzelVSOod8cRt+OYo6BUTVBbQErEvjcM8+KuMQBC00c7MkmCYE309 Bd9pdx6T5SPs6KUIanmUFtUSC+pPqF6rvJTCUtOdQb83ShS7LLlF9Jo+oBJnPmfnPwOT Hovk/VXhOZFzfx590+MPPY+qztwsV7Ofa+3k9jW3YK8ueckFMBjSMwAO5BloMwIV45CE Mpmb1/Gn6PEQ2dc13uZ+aD/vsQV9PsVQde10HcD0a2FB4N+7Ebaf8QKp0M2JRD7lbIrO JQdEoooBPH2QqrXCkxPj4FHGmYvagM15d0SPoymxQZC1giiq/etoD7SMh+eTPPYOIFDR IC9A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=DCGy87YJ; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 186si21948106pgc.248.2019.07.26.16.19.29; Fri, 26 Jul 2019 16:19:44 -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=@kernel.org header.s=default header.b=DCGy87YJ; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728380AbfGZWo1 (ORCPT + 99 others); Fri, 26 Jul 2019 18:44:27 -0400 Received: from mail.kernel.org ([198.145.29.99]:51630 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726581AbfGZWo0 (ORCPT ); Fri, 26 Jul 2019 18:44:26 -0400 Received: from mail-qt1-f179.google.com (mail-qt1-f179.google.com [209.85.160.179]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 264E8218B0; Fri, 26 Jul 2019 22:44:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1564181065; bh=CLc5TFw3wuFbBkx7QqcwcsboybeIIIr82PaiAeaZURI=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=DCGy87YJbkmZsb/Ha+fHYv9YEbPpbBeaKdIN7CHFAiY7iURJALNMUHRxFYjpzIEdb EhGTU7wxeglgJy+I+sAcB11TFt0kwbVG3ZeO58yNk0sO27h6TM+2KgnGTDnbUHRYVM MGtBHxJ0Y9PapbGqKUv7fXI2uwDnzi0UTNXpdDfM= Received: by mail-qt1-f179.google.com with SMTP id z4so54247907qtc.3; Fri, 26 Jul 2019 15:44:25 -0700 (PDT) X-Gm-Message-State: APjAAAX/Bw5i27y/pf4ZKI9XrL4HJ/QE+9cPFCaDoaI3o9Jl0H2/hiGw fNNi26i2aoSxWpLvtYfgYY2G9iYuARPMn18tBw== X-Received: by 2002:a0c:8a43:: with SMTP id 3mr71794002qvu.138.1564181064285; Fri, 26 Jul 2019 15:44:24 -0700 (PDT) MIME-Version: 1.0 References: <20190708103547.23528-1-jjhiblot@ti.com> <20190708103547.23528-3-jjhiblot@ti.com> <20190724164757.GA3723@bogus> <753b2c8d-e8fc-ec6e-f372-a84d4452fd33@ti.com> <20190726100607.j5bdmuuk33zpwa2r@holly.lan> In-Reply-To: <20190726100607.j5bdmuuk33zpwa2r@holly.lan> From: Rob Herring Date: Fri, 26 Jul 2019 16:44:13 -0600 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 2/2] dt-bindings: leds: document new "power-supply" property To: Daniel Thompson , Jean-Jacques Hiblot Cc: Jacek Anaszewski , Pavel Machek , Mark Rutland , Dan Murphy , Linux LED Subsystem , "linux-kernel@vger.kernel.org" , devicetree@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jul 26, 2019 at 4:06 AM Daniel Thompson wrote: > > On Thu, Jul 25, 2019 at 01:08:46PM +0200, Jean-Jacques Hiblot wrote: > > Hi Rob, > > > > On 24/07/2019 18:47, Rob Herring wrote: > > > On Mon, Jul 08, 2019 at 12:35:47PM +0200, Jean-Jacques Hiblot wrote: > > > > Most of the LEDs are powered by a voltage/current regulator. describing in > > > > the device-tree makes it possible for the LED core to enable/disable it > > > > when needed. > > > > > > > > Signed-off-by: Jean-Jacques Hiblot > > > > --- > > > > Documentation/devicetree/bindings/leds/common.txt | 5 +++++ > > > > 1 file changed, 5 insertions(+) > > > > > > > > diff --git a/Documentation/devicetree/bindings/leds/common.txt b/Documentation/devicetree/bindings/leds/common.txt > > > > index 70876ac11367..e093a2b7eb90 100644 > > > > --- a/Documentation/devicetree/bindings/leds/common.txt > > > > +++ b/Documentation/devicetree/bindings/leds/common.txt > > > > @@ -61,6 +61,11 @@ Optional properties for child nodes: > > > > - panic-indicator : This property specifies that the LED should be used, > > > > if at all possible, as a panic indicator. > > > > +- power-supply : A voltage/current regulator used to to power the LED. When a > > > > + LED is turned off, the LED core disable its regulator. The > > > > + same regulator can power many LED (or other) devices. It is > > > > + turned off only when all of its users disabled it. > > > Not sure this should be common. It wouldn't apply to cases where we have > > > an LED controller parent nor gpio and pwm LEDs and those are most cases. > > > > It does make sense for GPIO and PWM bindings if the anode of LED is tied to > > a regulated voltage and the cathod to the control line. Okay. Is one of those your case, or you only have regulator control? The latter would need a new binding. If you want to use power-supply with either GPIO and PWM LED bindings, then it should still be listed in those as an applicable property. > > The same is true for a certain class of true LED controller that do not > > deliver power but act like current sinks. > > > > JJ > > > > > > > > Perhaps what makes sense here is an regulator-led binding. > > You didn't comment on this alternative... and I confess I'm not quite > sure what Rob means by a regulator-led binding so I can't really comment > either. > > Rob, is there any analogous example for a regulator- binding > to compare with? regulator-haptic is the only one I found in a quick search. Rob