Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp3998150ybp; Mon, 7 Oct 2019 01:16:11 -0700 (PDT) X-Google-Smtp-Source: APXvYqxyD79muPIAsubFmPaqZs6SEgMvmMB5ut8bOOE68/5CciWS5NnpdYT8RacKtoHAdG1jgoP3 X-Received: by 2002:a17:906:3294:: with SMTP id 20mr22601977ejw.19.1570436171412; Mon, 07 Oct 2019 01:16:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570436171; cv=none; d=google.com; s=arc-20160816; b=A9RrnbNBI6qByzfOKAgRsUPLxw+ekYrbIToJGkjs+Af2CxmoIWs2vkeKAbmFpuCsXR /iuCH393mt86V9zol10kVvu2F7/s7mPDe25nScKMrQBU4Z3KW1SRxFbFpQQ6ms7RXfCJ pxUCK5FCEw0BQM1NbRDbkP4TrZcbuKB8cM4Rh55AjvOFfKzzMwg6jd2l9V1tEPLe+1F9 p1ToGby+bfl1qbLSKMNEe1H0Nwtico9kjebKSXLam7VO0ZVK1kFiKRKFB2w68pTKU/5Y E8uuoj5m82sdF9fV5A1IlNqxmfzGrFnDy+LQUT0ekUZ8xFfKpXuG4sTT+qE0k4vbIeJo EVyg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:subject:cc:to:from:message-id:date; bh=GwRimVwwgvRs+JSpIZwlTp1JCFdQu1IjcUObl6nYrUU=; b=BEJnYfdKXjw6MDQUalD93gm10lPqd4VBy7RH0soM0UKlpLNmggUGMXEhH+Y/7w/hIX 5cCwZD5WXG/C6h3wUhuOOCuIEPzMwkjOjxPvaPCKcSjPcnOfpNi2DneC0H0tnCG9UG7d ++/EgeEgzxErLlLR3bHCmb4CdIuJhPu4TVJFFbjc8nU0KPOhuME9NWdl86bSEe6n1pL0 T683XvYPpQLqEcowIVR9H9jDvShhnWzxs3dHtNHR+hWdLgF38qe+69fFDnl1WclHhU72 Eekf0DJU3e14zlxfDIf5LBhPLtCTh5kac/HLT+dqlOfio50xxV1xFOuPfKZrg54bCpnc ufIw== ARC-Authentication-Results: i=1; mx.google.com; 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=fail (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 b1si8246652edm.271.2019.10.07.01.15.47; Mon, 07 Oct 2019 01:16:11 -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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727312AbfJGIOp (ORCPT + 99 others); Mon, 7 Oct 2019 04:14:45 -0400 Received: from inca-roads.misterjones.org ([213.251.177.50]:39373 "EHLO inca-roads.misterjones.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726889AbfJGIOo (ORCPT ); Mon, 7 Oct 2019 04:14:44 -0400 Received: from [82.98.7.229] (helo=big-swifty.misterjones.org) by cheepnis.misterjones.org with esmtpsa (TLSv1.2:AES256-GCM-SHA384:256) (Exim 4.80) (envelope-from ) id 1iHOAB-00052F-KV; Mon, 07 Oct 2019 10:14:39 +0200 Date: Mon, 07 Oct 2019 09:14:38 +0100 Message-ID: <86blutdlap.wl-maz@kernel.org> From: Marc Zyngier To: Geert Uytterhoeven Cc: Chris Packham , Linus Walleij , Ray Jui , Scott Branden , bcm-kernel-feedback-list@broadcom.com, rayagonda.kokatanur@broadcom.com, li.jin@broadcom.com, "open list:GPIO SUBSYSTEM" , Linux Kernel Mailing List , Linux ARM Subject: Re: [PATCH v2 2/2] pinctrl: iproc: use unique name for irq chip In-Reply-To: References: <20191003000310.17099-1-chris.packham@alliedtelesis.co.nz> <20191003000310.17099-3-chris.packham@alliedtelesis.co.nz> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI-EPG/1.14.7 (Harue) FLIM/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL/10.8 EasyPG/1.0.0 Emacs/26 (aarch64-unknown-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII X-SA-Exim-Connect-IP: 82.98.7.229 X-SA-Exim-Rcpt-To: geert@linux-m68k.org, chris.packham@alliedtelesis.co.nz, linus.walleij@linaro.org, rjui@broadcom.com, sbranden@broadcom.com, bcm-kernel-feedback-list@broadcom.com, rayagonda.kokatanur@broadcom.com, li.jin@broadcom.com, linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org X-SA-Exim-Mail-From: maz@kernel.org X-SA-Exim-Scanned: No (on cheepnis.misterjones.org); SAEximRunCond expanded to false Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 07 Oct 2019 08:30:50 +0100, Geert Uytterhoeven wrote: > > Hi Chris, > > CC MarcZ > > On Thu, Oct 3, 2019 at 2:03 AM Chris Packham > wrote: > > Use the dev_name(dev) for the irqc->name so that we get unique names > > when we have multiple instances of this driver. > > > > Signed-off-by: Chris Packham > > A while ago, Marc Zyngier pointed out that the irq_chip .name field > should contain the device's class name, not the instance's name. > Hence the current code is correct? Thanks Geert for looping me in. The main reasons why I oppose this kind of "let's show as much information as we can in /proc/interrupts" are: - It clutters the output badly: the formatting of this file, which is bad enough when you have a small number of CPUs, becomes unreadable when you have a large number of them *and* stupidly long strings that only make sense on a given platform. - Like it or not, /proc is ABI. We don't change things randomly there without a good reason, and debugging isn't one of them. - Debug information belongs to debugfs, where we already have plenty of stuff (see CONFIG_GENERIC_IRQ_DEBUGFS). I'd rather we improve this infrastructure if needed, rather than add platform specific hacks. Thanks, M. > > See also "[PATCH 0/4] irqchip: renesas: Use proper irq_chip name and parent" > (https://lore.kernel.org/lkml/20190607095858.10028-1-geert+renesas@glider.be/) > Note that the irqchip patches in that series have been applied; the gpio > patches haven't been applied yet. > > > --- a/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c > > +++ b/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c > > @@ -858,7 +858,7 @@ static int iproc_gpio_probe(struct platform_device *pdev) > > struct gpio_irq_chip *girq; > > > > irqc = &chip->irqchip; > > - irqc->name = "bcm-iproc-gpio"; > > + irqc->name = dev_name(dev); > > irqc->irq_ack = iproc_gpio_irq_ack; > > irqc->irq_mask = iproc_gpio_irq_mask; > > irqc->irq_unmask = iproc_gpio_irq_unmask; > > Gr{oetje,eeting}s, > > Geert > > -- > Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org > > In personal conversations with technical people, I call myself a hacker. But > when I'm talking to journalists I just say "programmer" or something like that. > -- Linus Torvalds > -- Jazz is not dead, it just smells funny.