Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp1043044ybl; Wed, 4 Dec 2019 15:46:48 -0800 (PST) X-Google-Smtp-Source: APXvYqysNg7hMPxsDupkdSygjck6gYXvRxLRk7osI7/El9Da/3tUFjo+/8AFOK6hc3AkO7RG0Ff1 X-Received: by 2002:aca:5117:: with SMTP id f23mr3638259oib.50.1575503208185; Wed, 04 Dec 2019 15:46:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1575503208; cv=none; d=google.com; s=arc-20160816; b=oHS47W2k1S/FPaRg+3lP5AA5+9w5UEGh+XebhHTOwfMIFduN1MVJog8mfEFQdePF9u CDNFYQkeKMMjkPRJpywk3+GHkvgXnE0z0FyLpSEYU/JrdiUPPe/SkWrUuF/fL4uIPWJd skuAaVZdRz0wvaQYKf3xaZwDqbH0rb2p0B65qHl2p6SXC5kwF/OW/v+1OI2Kq5abJvue O04Mfw/3D1ECbh9dmjCUEGnIR7NYuZ+GGZNnlGI6peB5VPsfvuBsHOMZaJvzYZdqbXBZ TXJu9JrKtoGsj4InGWZjEN9iEjKqQ7F7EfarSAOOnmiPxCJLRUrD/qeE5ce53YH6R0LF yDLw== 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=1oLuXTqP88AIJllnfUv70RaPKExVa3V8VYnwKFzXr90=; b=YZ2vhVD1cs1ptXgXUjzGDkvcZOmSfBxO6AfqDeDRKry0T2wBk169ecZzued8dZr2nj cThL1uYdVSO4MH8YuiwhzfNyoiwLQ3FpuTRo67auulCNo4cPnkNVcjZuWCcU0ipcUV3g qVl3Bq5njuequOV1hp7YO5ESrctJTJNX1k5Nzti/mqdCUDupI3fS7PvrsH+OEwi8DJXP I5vmGO5HhYQuLuzkLnG5mdTXjmfpOY/qJtkp8+p6yiXw/6NzkwT6JUXfg1tmwOYdGjWn ++R2PLycdM+AES42eujKcHDwTg6AsZrEpKIpm7N8UoFdWMhFUWYPgMxkLdDDH3qc/m/x 39MQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=uQsVwqfR; 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=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 2si3766441oii.67.2019.12.04.15.46.33; Wed, 04 Dec 2019 15:46:48 -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=@linaro.org header.s=google header.b=uQsVwqfR; 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=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728132AbfLDXqG (ORCPT + 99 others); Wed, 4 Dec 2019 18:46:06 -0500 Received: from mail-lf1-f66.google.com ([209.85.167.66]:36469 "EHLO mail-lf1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728053AbfLDXqF (ORCPT ); Wed, 4 Dec 2019 18:46:05 -0500 Received: by mail-lf1-f66.google.com with SMTP id n12so970883lfe.3 for ; Wed, 04 Dec 2019 15:46:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=1oLuXTqP88AIJllnfUv70RaPKExVa3V8VYnwKFzXr90=; b=uQsVwqfRLCAJ44cXxreDwyi2t/pF9+6ktyX482qqhirs8nOUetXz3CJa6gX0d+StLI 4hrMtR2KUPZJw5V9yHYkuSxlHVrR0NcTxV66wok3kLyVEuiOdQ+87ZkDHjo1SaVe3qUt ExxMY9tZrB37RkXAXo4+S8vuXV0/TIiZ+XYFCBFZcfDXc3VafGj58nQzO9kGCJoKepaQ 45rWBnslFVJvwRITTvab0lm9wGC+o0gvis1jyeSwupr14EAS+0r5nhMkr0FKXIXS8wql EzUis/tSIFpQC3T4HIAyyWycETuiTV5ec3iLux8doePS9L+H9xv35IDJsOa4ul4uNfwO BGxg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=1oLuXTqP88AIJllnfUv70RaPKExVa3V8VYnwKFzXr90=; b=hWNlvjEKN61rjTd8KduXO2Ko2SGnnyOVaIJ7e+LQlKaQ4770H9xtXeOl5STq1I20FO kN31ZYmTg6ntIwAAcYG7xDJZ1fkthnERUX9e3U+MESY1zqJIz+u9ih11Go3h2k0dlH72 sUyteEYDrD+tyUtlcBL+hE1FQGoz184pbg88JFZjhyFeG90mFYZJ7lbH1gcTik8lL1ZP oDzUy11xO660zHPC0Fc/btalV7+PZBRGt5udBgXYOmBQzps5mggYIlRnftIXMPDJ4ywv yizaDEsUUDSWAA1Rdq1+EJ42Ua75d9tC4YxxN29leY/ccTaTUe/jDBflI9o3ZkhPjTC2 qS+Q== X-Gm-Message-State: APjAAAWllzJFu7O15+6dYkzTNvmglpOHAbJYS7v4ymkIPCDPL9y2V/N6 TjGoiPCnKQy4GmHaauZ/fJzCRaIj3sCUvRMPa37/+w== X-Received: by 2002:ac2:5b86:: with SMTP id o6mr3552742lfn.44.1575503163840; Wed, 04 Dec 2019 15:46:03 -0800 (PST) MIME-Version: 1.0 References: <20191204110219.GV25745@shell.armlinux.org.uk> In-Reply-To: From: Linus Walleij Date: Thu, 5 Dec 2019 00:45:51 +0100 Message-ID: Subject: Re: "leds: gpio: Use generic support for composing LED names" breaks gpio debugfs To: Jacek Anaszewski Cc: Russell King - ARM Linux admin , Pavel Machek , Linux ARM , Linux LED Subsystem , "linux-kernel@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 Wed, Dec 4, 2019 at 9:52 PM Jacek Anaszewski wrote: > It seem that the only proper solution would be introducing a new > pre_register_cdev(const char *name) op to the LED core, that would allow > drivers to come up with their implementation thereof. In this particular > case leds-gpio driver would need to put there gpiod initialization. I don't know the particulars but if it helps you can at any point call: int gpiod_set_consumer_name(struct gpio_desc *desc, const char *name); For any successfully obtained descriptor, to set the consumer name, i.e. the text appearing in debugfs and the GPIO character device. Yours, Linus Walleij