All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Lezcano <daniel.lezcano@linaro.org>
To: Thomas Gleixner <tglx@linutronix.de>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: [RFC] add a WARN in setup_irq function for the IRQF_DISABLED flag
Date: Sat, 08 Jun 2013 00:17:16 +0200	[thread overview]
Message-ID: <51B25BEC.5050003@linaro.org> (raw)


Hi,

we are still seeing drivers with the irq flag IRQF_DISABLED present and
*new* drivers submitted with this flag set.

I am wondering if we can add a WARN in the setup_irq function about this
flag. May be it is a bit rough but people will pay attention.

Thanks

  -- Daniel

Index: clockevents/kernel/irq/manage.c
===================================================================
--- clockevents.orig/kernel/irq/manage.c        2013-06-05
23:57:22.723446115 +0200
+++ clockevents/kernel/irq/manage.c     2013-06-08 00:12:19.985035465 +0200
@@ -1212,6 +1212,9 @@ int setup_irq(unsigned int irq, struct i

        if (WARN_ON(irq_settings_is_per_cpu_devid(desc)))
                return -EINVAL;
+
+       WARN(act->flags & IRQF_DISABLED, "IRQF_DISABLED flag is disabled");
+
        chip_bus_lock(desc);
        retval = __setup_irq(irq, desc, act);
        chip_bus_sync_unlock(desc);

-- 
 <http://www.linaro.org/> Linaro.org │ Open source software for ARM SoCs

Follow Linaro:  <http://www.facebook.com/pages/Linaro> Facebook |
<http://twitter.com/#!/linaroorg> Twitter |
<http://www.linaro.org/linaro-blog/> Blog


             reply	other threads:[~2013-06-07 22:17 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-07 22:17 Daniel Lezcano [this message]
2013-06-07 22:19 ` [RFC] add a WARN in setup_irq function for the IRQF_DISABLED flag Daniel Lezcano

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=51B25BEC.5050003@linaro.org \
    --to=daniel.lezcano@linaro.org \
    --cc=linux-kernel@vger.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.