Received: by 2002:a25:ad19:0:0:0:0:0 with SMTP id y25csp6726557ybi; Mon, 8 Jul 2019 07:40:44 -0700 (PDT) X-Google-Smtp-Source: APXvYqwvqIx8fjf7uDYS0ZI7zLkanAdYX6Vtj/OeupXrgaBvyM+VrPD13aypq6JnEfQyX8yCZaRu X-Received: by 2002:a17:902:26c:: with SMTP id 99mr26169475plc.215.1562596843939; Mon, 08 Jul 2019 07:40:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562596843; cv=none; d=google.com; s=arc-20160816; b=FbVpmMpbB/Rl3rlzYWTvUhUdEc/zUUVdJHDjXLyPN1cXMHTEe579AZyCatjYK4ZKOg +BxZZGbF3Tt0GffkPtau8RZz5UGVhKf0JSJOp95zyhBqLlwjqT5yMFW+DbM66zZ9jVY+ 2/YS8mzm/e8tb35YUErtAMbCFt+YQIp1ERyIBsLIfIXoys5qrWugKUA79M6bF0squ/6+ dlIFEGLGVEQVsXKJZcFCRLBeJkzjmUQVotldFXcGdJrtJt60g4APWGBUx4c3vNPEAPkJ JYPzk3NilBX8HuM7x1uyu245sqgki3jUJKmMupdO2A+8D0UnQ3OLU3vnbTw48TKWBgyz u0GQ== 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; bh=4hFShXBEewLwhXK6VD3Owlrh0+FXTvSoOIUdw/wVZQA=; b=QTgwrx5eM//dqqYpH2TOTMK5QUxZqHpjvgOSTj4T6MVUj8RImZzUXKUyDwIUODX/eP 4vfQVEI2bmyQdWJbkS8szsHzteHLKfAdF0nvkBpQkO99vO1U1EmPyzCUd03Zviox7zhG WpufmjowHdDi7f+Mc8Pqj/qiCcZRDPLjka0+kK6i4vF9CDgUkcROCB1zveCEFvnECc20 1b4ziMZPjNulOA3yOF6E2KILTpKjunPoY0MjuDjV+6d/UtTFfJULnwg044iB7DjX+jhf elqUiwVymp+DuBl/Tknqv1hgCd/wNYStNObVaAYInmWZceTYsQufMvlBigoGoqRo3wi7 N1WQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@ti.com header.s=ti-com-17Q1 header.b="qfoDhx/a"; 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 w21si1310410pff.263.2019.07.08.07.40.29; Mon, 08 Jul 2019 07:40:43 -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=@ti.com header.s=ti-com-17Q1 header.b="qfoDhx/a"; 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 S1730037AbfGHKGk (ORCPT + 99 others); Mon, 8 Jul 2019 06:06:40 -0400 Received: from lelv0143.ext.ti.com ([198.47.23.248]:56552 "EHLO lelv0143.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729324AbfGHKGd (ORCPT ); Mon, 8 Jul 2019 06:06:33 -0400 Received: from fllv0035.itg.ti.com ([10.64.41.0]) by lelv0143.ext.ti.com (8.15.2/8.15.2) with ESMTP id x68A6T9j041416; Mon, 8 Jul 2019 05:06:29 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1562580389; bh=4hFShXBEewLwhXK6VD3Owlrh0+FXTvSoOIUdw/wVZQA=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=qfoDhx/aKditTQq3vGh0YuCFAML2QV0U8RLudPVA8igS4mFS/d7vVh+neVzttM7pc rkDDVqDXqLID09VmoIAiNT0PAZreNoGI9lxJE9s9deq9wwOY7qrg4Fkxh+47bar4W/ r20kvXfJg5yGbmM14wnBVLX7gfg0VUdH5yDZq9tU= Received: from DFLE108.ent.ti.com (dfle108.ent.ti.com [10.64.6.29]) by fllv0035.itg.ti.com (8.15.2/8.15.2) with ESMTPS id x68A6TgK045289 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 8 Jul 2019 05:06:29 -0500 Received: from DFLE105.ent.ti.com (10.64.6.26) by DFLE108.ent.ti.com (10.64.6.29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1713.5; Mon, 8 Jul 2019 05:06:29 -0500 Received: from fllv0039.itg.ti.com (10.64.41.19) by DFLE105.ent.ti.com (10.64.6.26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1713.5 via Frontend Transport; Mon, 8 Jul 2019 05:06:29 -0500 Received: from localhost (ileax41-snat.itg.ti.com [10.172.224.153]) by fllv0039.itg.ti.com (8.15.2/8.15.2) with ESMTP id x68A6StD042780; Mon, 8 Jul 2019 05:06:28 -0500 From: Jean-Jacques Hiblot To: , , CC: , , , Jean-Jacques Hiblot Subject: [PATCH v2 2/2] leds: tlc591xx: Use the OF version of the LED registration function Date: Mon, 8 Jul 2019 12:06:20 +0200 Message-ID: <20190708100620.22388-3-jjhiblot@ti.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190708100620.22388-1-jjhiblot@ti.com> References: <20190708100620.22388-1-jjhiblot@ti.com> MIME-Version: 1.0 Content-Type: text/plain 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 The driver parses the device-tree to identify which LED should be handled. Since the information about the device node is known at this time, we can provide the LED core with it. It may be useful later. Signed-off-by: Jean-Jacques Hiblot Acked-by: Pavel Machek --- drivers/leds/leds-tlc591xx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/leds/leds-tlc591xx.c b/drivers/leds/leds-tlc591xx.c index 3d5a4b92f016..10764a62cb71 100644 --- a/drivers/leds/leds-tlc591xx.c +++ b/drivers/leds/leds-tlc591xx.c @@ -207,7 +207,7 @@ tlc591xx_probe(struct i2c_client *client, led->led_no = reg; led->ldev.brightness_set_blocking = tlc591xx_brightness_set; led->ldev.max_brightness = LED_FULL; - err = devm_led_classdev_register(dev, &led->ldev); + err = devm_of_led_classdev_register(dev, child, &led->ldev); if (err < 0) { dev_err(dev, "couldn't register LED %s\n", led->ldev.name); -- 2.17.1