From patchwork Tue Dec 12 22:01:39 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dan Murphy X-Patchwork-Id: 121663 Delivered-To: patch@linaro.org Received: by 10.140.22.227 with SMTP id 90csp4682362qgn; Tue, 12 Dec 2017 14:03:14 -0800 (PST) X-Google-Smtp-Source: ACJfBos3SCIUBT+E9SyDgTnY8f0c1v2cVQGXSQwx5XQwFxiFsDdbGuIVcn94/H85kcY5qNuCHsVx X-Received: by 10.99.62.10 with SMTP id l10mr3271500pga.376.1513116194459; Tue, 12 Dec 2017 14:03:14 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1513116194; cv=none; d=google.com; s=arc-20160816; b=IM+7bREFCQI0QOtJTgPlIsZOMza6eStb23ewaHK3qaxZt+He/DdYL4OWRgOMa53lJy 09pUHxrLwsgjmb+eDCKv80VOYPfPSFeOhCAgn/+cPB28REbWrFzGQ5XhdcsduFWJy91r Sz0ziy8hMb3tfENWlx/X7Tkk+bTJpHk6iRIsKUAe015gaLIMVMossTxiV+z9pXOsU5VS Hfc+NHm2kPNRmxbUd4RiIf60NxM2sfpAM6+BYX8HxQrjmJiC+qWSvgyHsfFk4WS8jZVv al2Sw6h79dIosr7cXM5FTOMJqbxhOGsPHuw9BEalfeXwGM5uQYOjj8fT9PG8ivWOX4U0 Kr5Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=VlbxDPq3Xuu2/T8IQW02++jT0kLsfJtmo4BP2vNKSkY=; b=n4aq69evVbD95v0gQeQbsVwEGntbQ7/UPxMDSzkCKRuW2IyXmJwJEZrhOzE4HptiBy WiSAfFanFG07hG+oduN6qCuDaaXDOiGSGTBJPHsnzsmSL9GyiNQs9uVj73iissOT/vH8 YdXP20ZFpE8rWm2arMn7Ju89DlC0iDI273efMBsWHJD2Iy7m+tXOeBzMvysSp4lHXUaI Jz8Li1zffPrhT1W4Z/gOrIWU2BGGwpCTgaZKGswumhpoE7Grwu2FOXmOlYSuU+wLx+Qj J/Z7BJPtA7tVtO4Vtr88e1WfOzqzYyWQQzBehGKqjvkYdkRW0I0mpjCjY0rUGEiJd4dz AwqQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=mWIcEV6L; 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=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g9si126670plk.420.2017.12.12.14.03.14; Tue, 12 Dec 2017 14:03:14 -0800 (PST) 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=@ti.com header.s=ti-com-17Q1 header.b=mWIcEV6L; 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=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752987AbdLLWDM (ORCPT + 10 others); Tue, 12 Dec 2017 17:03:12 -0500 Received: from fllnx209.ext.ti.com ([198.47.19.16]:56076 "EHLO fllnx209.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752951AbdLLWDH (ORCPT ); Tue, 12 Dec 2017 17:03:07 -0500 Received: from dlelxv90.itg.ti.com ([172.17.2.17]) by fllnx209.ext.ti.com (8.15.1/8.15.1) with ESMTP id vBCM1rZV013824; Tue, 12 Dec 2017 16:01:53 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ti.com; s=ti-com-17Q1; t=1513116113; bh=eGAWVI7cMebQY3HRFbf3H0NAqPV4WurAUBfdirUfsUE=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=mWIcEV6LtaSc7wP193nOFa1dyelLm8SB+/NHLYgKYXykwMwDbGTIR/URdEvqhW6U8 DxEMPgPZ76tdsgKusO+pzcLxjM1PbZ9AEYVg2mC43vxy9+/UwL0uxzoX76kDBi1WJz VNsrKFVDsUNH3rdD8FMRf+xOrXrib/veIFlTlBjQ= Received: from DFLE111.ent.ti.com (dfle111.ent.ti.com [10.64.6.32]) by dlelxv90.itg.ti.com (8.14.3/8.13.8) with ESMTP id vBCM1mlc022625; Tue, 12 Dec 2017 16:01:48 -0600 Received: from DFLE114.ent.ti.com (10.64.6.35) by DFLE111.ent.ti.com (10.64.6.32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.1.845.34; Tue, 12 Dec 2017 16:01:47 -0600 Received: from dflp33.itg.ti.com (10.64.6.16) by DFLE114.ent.ti.com (10.64.6.35) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.1.845.34 via Frontend Transport; Tue, 12 Dec 2017 16:01:47 -0600 Received: from legion.dal.design.ti.com (legion.dal.design.ti.com [128.247.22.53]) by dflp33.itg.ti.com (8.14.3/8.13.8) with ESMTP id vBCM1lDJ026233; Tue, 12 Dec 2017 16:01:47 -0600 Received: from localhost (a0272616local-lt.dhcp.ti.com [172.22.69.253]) by legion.dal.design.ti.com (8.11.7p1+Sun/8.11.7) with ESMTP id vBCM1lx11337; Tue, 12 Dec 2017 16:01:47 -0600 (CST) From: Dan Murphy To: , , , , CC: , , , Dan Murphy Subject: [PATCH v4 2/6] dt: bindings: lp8860: Update DT label binding Date: Tue, 12 Dec 2017 16:01:39 -0600 Message-ID: <20171212220143.31210-3-dmurphy@ti.com> X-Mailer: git-send-email 2.12.2 In-Reply-To: <20171212220143.31210-1-dmurphy@ti.com> References: <20171212220143.31210-1-dmurphy@ti.com> MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Update the lp8860 label binding to the LED standard as documented in Documentation/devicetree/bindings/leds/common.txt Signed-off-by: Dan Murphy --- v4 - No changes v3 - Added address and size cells, updated label with color and inserted spaces around the reg node - https://patchwork.kernel.org/patch/10093749/ v2 - Added reg to child node and made it required Documentation/devicetree/bindings/leds/leds-lp8860.txt | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) -- 2.15.0.124.g7668cbc60 diff --git a/Documentation/devicetree/bindings/leds/leds-lp8860.txt b/Documentation/devicetree/bindings/leds/leds-lp8860.txt index b9d09acbaa73..c3d64ade1e26 100644 --- a/Documentation/devicetree/bindings/leds/leds-lp8860.txt +++ b/Documentation/devicetree/bindings/leds/leds-lp8860.txt @@ -9,20 +9,33 @@ Required properties: - compatible : "ti,lp8860" - reg : I2C slave address - - label : Used for naming LEDs + - #address-cells : 1 + - #size-cells : 0 Optional properties: - enable-gpios : gpio pin to enable (active high)/disable the device. - vled-supply : LED supply +Required child properties: + - reg : 0 + +Optional child properties: + - label : see Documentation/devicetree/bindings/leds/common.txt + Example: led-controller@2d { compatible = "ti,lp8860"; + #address-cells = <1>; + #size-cells = <0>; reg = <0x2d>; - label = "display_cluster"; enable-gpios = <&gpio1 28 GPIO_ACTIVE_HIGH>; vled-supply = <&vbatt>; + + led@0 { + reg = <0>; + label = "white:display_cluster"; + }; } For more product information please see the link below: From patchwork Tue Dec 12 22:01:42 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dan Murphy X-Patchwork-Id: 121662 Delivered-To: patch@linaro.org Received: by 10.140.22.227 with SMTP id 90csp4681393qgn; Tue, 12 Dec 2017 14:02:30 -0800 (PST) X-Google-Smtp-Source: ACJfBov2FlpIui8p3SwY7JujPdDhNRfHspvcXIXeoncIYSw9/P3yqI/wLJnPSCUqvBVJ5Kuwwd+G X-Received: by 10.98.157.219 with SMTP id a88mr3713067pfk.126.1513116150333; Tue, 12 Dec 2017 14:02:30 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1513116150; cv=none; d=google.com; s=arc-20160816; b=QPcWTDvEXlRI7IhiVOyqtXm6ksvsg3zZYXh7BlTTRO5th5UuGGMIV2Jh8ypgDz2jkx f2cSaY+JQN7WWom6hjjXxmfuI1ryygMeft7G/39L63IvlBqTYs0j+tgn/TfFB2AglNYn qaX+tOd/5YudnhPLtOt+Y0oPzJ3Eohr8yu0vWjnlJBBVvh5oHhk1HV0RHJFZ5D2i6BbI NhOn6q5H90GtTp8miJyHjT+aIlsDx3y0wZ3bRSNWGv8sFuDVFPebyIzkgc8yLn395MAw lT46g2xXV7QCvLtEJwkj9Rb4qbPAC05OZv98TYnr23cjmD0ZVqxAC3GKqYUG/vDHcTSw DsVg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=imlroXeKLHrDvLRDqQiDWQ/QtYJcqCZjj5htjGUNNL0=; b=nTp3beQn4dbru8lOXK+9+xk5g7FxJcn2uCigPWiIRi3S+rypEnakLSDLUqIzs+PB4g ZmdQcTh4tfiVk7TfZHbd99f4NlC3xlFNOvRbRqa1qy1b/6l2p8ZjnwTRzvK1H6GzDZbJ rdv5gE49X5WBIC2Eo6XfOg1H7xAEwfqJP2KcbekksHSwiFR3cmJWlTMHdLKIhtMl0FVO d/YYj3cg4Cp4g4yY23ERYTScwZLGj+gVmx5L5nSSs0BLrTlI0dmX6uv8KmzAKLqhTZvI tS4H6CZvwc+eGbddXsCdaBTZr8DhnFIQzTpPkM2Docb7+eSFuuNqSGaLNfCaBE4rcgrx jAqA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b=Az/lLt1g; 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=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a13si119375pgd.252.2017.12.12.14.02.30; Tue, 12 Dec 2017 14:02:30 -0800 (PST) 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=@ti.com header.s=ti-com-17Q1 header.b=Az/lLt1g; 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=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752931AbdLLWC0 (ORCPT + 10 others); Tue, 12 Dec 2017 17:02:26 -0500 Received: from lelnx193.ext.ti.com ([198.47.27.77]:9240 "EHLO lelnx193.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752748AbdLLWCG (ORCPT ); Tue, 12 Dec 2017 17:02:06 -0500 Received: from dlelxv90.itg.ti.com ([172.17.2.17]) by lelnx193.ext.ti.com (8.15.1/8.15.1) with ESMTP id vBCM1onm031923; Tue, 12 Dec 2017 16:01:50 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ti.com; s=ti-com-17Q1; t=1513116110; bh=AhRKHuJUaUySLKxqMgIbUfaAvpHVGsqdcBhdKpz7eB4=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=Az/lLt1gqVXNdo+4AYBUlwqOQZe5ZY/ITwCigw1DuXCJXfxRBCiCV/xcjOKgT8wYe mp19h5VMExqOilPTTzr12uvcr5d3Z/auxsipVVT5M/Fm811oxrDS9EhHcTnEa8Hz+E VHzNpWgfTo+eaHUAv8GtebDhVjsOtY578EQDUQRU= Received: from DLEE108.ent.ti.com (dlee108.ent.ti.com [157.170.170.38]) by dlelxv90.itg.ti.com (8.14.3/8.13.8) with ESMTP id vBCM1o1t022670; Tue, 12 Dec 2017 16:01:50 -0600 Received: from DLEE114.ent.ti.com (157.170.170.25) by DLEE108.ent.ti.com (157.170.170.38) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.1.845.34; Tue, 12 Dec 2017 16:01:49 -0600 Received: from dlep32.itg.ti.com (157.170.170.100) by DLEE114.ent.ti.com (157.170.170.25) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.1.845.34 via Frontend Transport; Tue, 12 Dec 2017 16:01:50 -0600 Received: from legion.dal.design.ti.com (legion.dal.design.ti.com [128.247.22.53]) by dlep32.itg.ti.com (8.14.3/8.13.8) with ESMTP id vBCM1nPe014077; Tue, 12 Dec 2017 16:01:49 -0600 Received: from localhost (a0272616local-lt.dhcp.ti.com [172.22.69.253]) by legion.dal.design.ti.com (8.11.7p1+Sun/8.11.7) with ESMTP id vBCM1mx11352; Tue, 12 Dec 2017 16:01:49 -0600 (CST) From: Dan Murphy To: , , , , CC: , , , Dan Murphy Subject: [PATCH v4 5/6] leds: lp8860: Add DT parsing to retrieve the trigger node Date: Tue, 12 Dec 2017 16:01:42 -0600 Message-ID: <20171212220143.31210-6-dmurphy@ti.com> X-Mailer: git-send-email 2.12.2 In-Reply-To: <20171212220143.31210-1-dmurphy@ti.com> References: <20171212220143.31210-1-dmurphy@ti.com> MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add the ability to parse the DT and set the default trigger mode for the LED. Signed-off-by: Dan Murphy --- v4 - No changes v3 - no changes - https://patchwork.kernel.org/patch/10093751/ v2 - no changes drivers/leds/leds-lp8860.c | 4 ++++ 1 file changed, 4 insertions(+) -- 2.15.0.124.g7668cbc60 diff --git a/drivers/leds/leds-lp8860.c b/drivers/leds/leds-lp8860.c index 46578fbc36be..bb1d7bbc928c 100644 --- a/drivers/leds/leds-lp8860.c +++ b/drivers/leds/leds-lp8860.c @@ -372,6 +372,10 @@ static int lp8860_probe(struct i2c_client *client, return -ENOMEM; for_each_available_child_of_node(np, child_node) { + led->led_dev.default_trigger = of_get_property(child_node, + "linux,default-trigger", + NULL); + ret = of_property_read_string(child_node, "label", &name); if (!ret) snprintf(led->label, sizeof(led->label), "%s:%s",