From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,PDS_BTC_ID, SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id B1F29C43603 for ; Wed, 4 Dec 2019 11:02:39 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 6724E20803 for ; Wed, 4 Dec 2019 11:02:39 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="nmKl6Glg"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=armlinux.org.uk header.i=@armlinux.org.uk header.b="tMB/Rov2" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 6724E20803 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=armlinux.org.uk Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-ID:Subject:To:From :Date:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=PsZ7Ev8AxluhHYSKVoIJYy4kNNJWFy6aSBmWGQzu4PE=; b=nmKl6Glg0nXraN FhDcXQWSUmXp0dEIQ7HhLChwucBgXtBwSLv7NlQpUkq7HoOepqq4+7DR4a/mXW5viMGCBa9Cke8Uw hxrHBONJOotVP1x/gtt1T2iM7fG8uRrL+po6H/BLNjTCOFV2IQNN+Zbc5HXFUDendFDy1VjIgBY13 oGzykJwCMUqMgoO8fLtnlEGEKKfvfPpujoINNcJwvf7sMeM/VITPnZz8iHfXhEdg5y2Cg024JR1ot rQJDHTDKVM6pXR2vYyZV6FUfQ8vXZsKsjORr8QHvRQW4lvsIlo5zlcB2o0fRmN3ZVQM2svwi0j8VA BQMu0yROTlEZ31w55okw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1icSQY-0001wq-SW; Wed, 04 Dec 2019 11:02:38 +0000 Received: from pandora.armlinux.org.uk ([2001:4d48:ad52:3201:214:fdff:fe10:1be6]) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1icSQV-0001vL-03 for linux-arm-kernel@lists.infradead.org; Wed, 04 Dec 2019 11:02:36 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=armlinux.org.uk; s=pandora-2019; h=Sender:Content-Type:MIME-Version: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=FERLaxZUxyP72Jvm9tSRCjsYA68i6+0dGt84HtQCKYc=; b=tMB/Rov2jut9SYIQWR2KinbOy 2s5FbXddNAOcEZDNnZVJ7bQT/Sw0ZiWWjZWYNQbzFU0vbKRWpK0Q3OSrXeBB3qT9iDHo4GUPuUOpd F6ELFzYkyoSgGBU2Xs6cBoRmoDMf0Rhw9ZBHu/vy9Bn6v6vk8ROEkVG4onNAgsDkUavi0NHKIxxG9 THZJyCJFm7qwYomcwmaljlnhkGVr2q5A2e3dRrGVg9ECbA/xEMJiHWyiRpLF1dM00C+r5QcpSGCw5 MvcytmyZkk6Eiot+0r2BrqsFEpwqG879jioPn6cOdkDQOgMSCFzbyCb3Tih0knyn6Sta54+xn4a3w O+r3gliXg==; Received: from shell.armlinux.org.uk ([fd8f:7570:feb6:1:5054:ff:fe00:4ec]:48382) by pandora.armlinux.org.uk with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.90_1) (envelope-from ) id 1icSQI-00049b-HR; Wed, 04 Dec 2019 11:02:22 +0000 Received: from linux by shell.armlinux.org.uk with local (Exim 4.92) (envelope-from ) id 1icSQF-00071j-NR; Wed, 04 Dec 2019 11:02:19 +0000 Date: Wed, 4 Dec 2019 11:02:19 +0000 From: Russell King - ARM Linux admin To: Jacek Anaszewski , Linus Walleij , Pavel Machek Subject: "leds: gpio: Use generic support for composing LED names" breaks gpio debugfs Message-ID: <20191204110219.GV25745@shell.armlinux.org.uk> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.10.1 (2018-07-13) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191204_030235_395351_B790C23D X-CRM114-Status: UNSURE ( 7.24 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-leds@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org Hi, Patch d7235f5feaa0 ("leds: gpio: Use generic support for composing LED names") changed the way labels are used. devm_fwnode_get_gpiod_from_child() is passed led.name, which used to be set to the label or node name, resulting in /sys/kernel/debug/gpio containing useful information. For example: gpio-487 ( |udpu:green:power ) out lo gpio-488 ( |udpu:red:power ) out hi gpio-489 ( |udpu:green:network ) out hi gpio-490 ( |udpu:red:network ) out hi gpio-491 ( |udpu:green:alarm ) out hi gpio-492 ( |udpu:red:alarm ) out hi After this commit, it now contains a rather less useful: gpio-487 ( |? ) out hi ACTIVE LOW gpio-488 ( |? ) out hi ACTIVE LOW gpio-489 ( |? ) out hi ACTIVE LOW gpio-490 ( |? ) out hi ACTIVE LOW gpio-491 ( |? ) out hi ACTIVE LOW gpio-492 ( |? ) out hi ACTIVE LOW This is because led.name is now NULL prior to the call to devm_fwnode_get_gpiod_from_child(). While this is not an API, it is useful for debugging, and given the dynamic allocation of GPIOs to physical GPIOs, having the labels present is an advantage. Can this be fixed / old behaviour restored? Thanks. -- RMK's Patch system: https://www.armlinux.org.uk/developer/patches/ FTTC broadband for 0.8mile line in suburbia: sync at 12.1Mbps down 622kbps up According to speedtest.net: 11.9Mbps down 500kbps up _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel