linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "irqchip-bot for Greg Kroah-Hartman" <tip-bot2@linutronix.de>
To: linux-kernel@vger.kernel.org
Cc: Marc Zyngier <maz@kernel.org>,
	Thomas Gleixner <tglx@linutronix.de>,
	linux-kernel@vger.kernel.org,
	"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>
Subject: [irqchip: irq/irqchip-next] irqdomain: Remove debugfs_file from struct irq_domain
Date: Thu, 18 Feb 2021 11:43:24 -0000	[thread overview]
Message-ID: <161364860401.20312.8803941418073480334.tip-bot2@tip-bot2> (raw)
In-Reply-To: <YCvYV53ZdzQSWY6w@kroah.com>

The following commit has been merged into the irq/irqchip-next branch of irqchip:

Commit-ID:     c83fd57be3fefa1522e7381f044fe0b702cbc6ad
Gitweb:        https://git.kernel.org/pub/scm/linux/kernel/git/maz/arm-platforms/c83fd57be3fefa1522e7381f044fe0b702cbc6ad
Author:        Greg Kroah-Hartman <gregkh@linuxfoundation.org>
AuthorDate:    Tue, 16 Feb 2021 15:36:07 +01:00
Committer:     Marc Zyngier <maz@kernel.org>
CommitterDate: Thu, 18 Feb 2021 11:40:04 

irqdomain: Remove debugfs_file from struct irq_domain

There's no need to keep around a dentry pointer to a simple file that
debugfs itself can look up when we need to remove it from the system.
So simplify the code by deleting the variable and cleaning up the logic
around the debugfs file.

Cc: Marc Zyngier <maz@kernel.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/YCvYV53ZdzQSWY6w@kroah.com
---
 include/linux/irqdomain.h |  4 ----
 kernel/irq/irqdomain.c    |  9 ++++-----
 2 files changed, 4 insertions(+), 9 deletions(-)

diff --git a/include/linux/irqdomain.h b/include/linux/irqdomain.h
index 42d1968..33cacc8 100644
--- a/include/linux/irqdomain.h
+++ b/include/linux/irqdomain.h
@@ -150,7 +150,6 @@ struct irq_domain_chip_generic;
  *      setting up one or more generic chips for interrupt controllers
  *      drivers using the generic chip library which uses this pointer.
  * @parent: Pointer to parent irq_domain to support hierarchy irq_domains
- * @debugfs_file: dentry for the domain debugfs file
  *
  * Revmap data, used internally by irq_domain
  * @revmap_direct_max_irq: The largest hwirq that can be set for controllers that
@@ -174,9 +173,6 @@ struct irq_domain {
 #ifdef	CONFIG_IRQ_DOMAIN_HIERARCHY
 	struct irq_domain *parent;
 #endif
-#ifdef CONFIG_GENERIC_IRQ_DEBUGFS
-	struct dentry		*debugfs_file;
-#endif
 
 	/* reverse map data. The linear map gets appended to the irq_domain */
 	irq_hw_number_t hwirq_max;
diff --git a/kernel/irq/irqdomain.c b/kernel/irq/irqdomain.c
index 6aacd34..367ff1c 100644
--- a/kernel/irq/irqdomain.c
+++ b/kernel/irq/irqdomain.c
@@ -1896,16 +1896,15 @@ DEFINE_SHOW_ATTRIBUTE(irq_domain_debug);
 
 static void debugfs_add_domain_dir(struct irq_domain *d)
 {
-	if (!d->name || !domain_dir || d->debugfs_file)
+	if (!d->name || !domain_dir)
 		return;
-	d->debugfs_file = debugfs_create_file(d->name, 0444, domain_dir, d,
-					      &irq_domain_debug_fops);
+	debugfs_create_file(d->name, 0444, domain_dir, d,
+			    &irq_domain_debug_fops);
 }
 
 static void debugfs_remove_domain_dir(struct irq_domain *d)
 {
-	debugfs_remove(d->debugfs_file);
-	d->debugfs_file = NULL;
+	debugfs_remove(debugfs_lookup(d->name, domain_dir));
 }
 
 void __init irq_domain_debugfs_init(struct dentry *root)

  parent reply	other threads:[~2021-02-18 13:24 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-16 14:36 [PATCH] irqdomain: remove debugfs_file from struct irq_domain Greg Kroah-Hartman
2021-02-16 15:36 ` [irqchip: irq/irqchip-next] irqdomain: Remove " irqchip-bot for Greg Kroah-Hartman
2021-02-17 19:57 ` [PATCH] irqdomain: remove " Michael Walle
2021-02-17 20:02   ` Marc Zyngier
2021-02-17 20:10     ` Michael Walle
2021-02-17 21:50       ` Marc Zyngier
2021-02-17 22:21         ` Michael Walle
2021-02-18  7:16           ` Greg KH
2021-02-18  7:31         ` Greg KH
2021-02-18  8:27           ` Michael Walle
2021-02-18  8:38             ` Greg KH
2021-02-18  8:47               ` Marc Zyngier
2021-02-18  8:54                 ` Greg KH
2021-02-18  9:04                   ` Marc Zyngier
2021-02-18  9:38                     ` Greg KH
2021-02-18 10:39                       ` Marc Zyngier
2021-02-18  8:52             ` Greg KH
2021-02-18  9:04               ` Michael Walle
2021-02-18  9:08               ` Marc Zyngier
2021-02-18  8:40   ` Greg KH
2021-02-18  8:46     ` Michael Walle
2021-02-18 11:43 ` irqchip-bot for Greg Kroah-Hartman [this message]
2021-03-08 20:25 ` [irqchip: irq/irqchip-next] irqdomain: Remove " irqchip-bot for Greg Kroah-Hartman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=161364860401.20312.8803941418073480334.tip-bot2@tip-bot2 \
    --to=tip-bot2@linutronix.de \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maz@kernel.org \
    --cc=tglx@linutronix.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).