summaryrefslogtreecommitdiff
path: root/kernel/irq/internals.h
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2017-06-24 11:05:59 +0200
committerThomas Gleixner <tglx@linutronix.de>2017-06-24 11:43:53 +0200
commitc2ce34c0a0e5187195ecade872be950d2611ba68 (patch)
treeb0953c50658cc35611efa5486fc984e5f7f3fbbe /kernel/irq/internals.h
parent8d9d51b62e8558bbc11c6b978acad001f9ea7a42 (diff)
genirq/debugfs: Remove pointless NULL pointer check
debugfs_remove() has it's own NULL pointer check. Remove the conditional and make irq_remove_debugfs_entry() an inline helper Reported-by: kbuild test robot <fengguang.wu@intel.com> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'kernel/irq/internals.h')
-rw-r--r--kernel/irq/internals.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/kernel/irq/internals.h b/kernel/irq/internals.h
index 5fd105e252c3..a573e0771baf 100644
--- a/kernel/irq/internals.h
+++ b/kernel/irq/internals.h
@@ -318,8 +318,13 @@ static inline bool irq_fixup_move_pending(struct irq_desc *desc, bool fclear)
#endif /* !CONFIG_GENERIC_PENDING_IRQ */
#ifdef CONFIG_GENERIC_IRQ_DEBUGFS
+#include <linux/debugfs.h>
+
void irq_add_debugfs_entry(unsigned int irq, struct irq_desc *desc);
-void irq_remove_debugfs_entry(struct irq_desc *desc);
+static inline void irq_remove_debugfs_entry(struct irq_desc *desc)
+{
+ debugfs_remove(desc->debugfs_file);
+}
# ifdef CONFIG_IRQ_DOMAIN
void irq_domain_debugfs_init(struct dentry *root);
# else