Skip to content

Commit

Permalink
pcmcia: irq probe can be done without risking an IRQ storm
Browse files Browse the repository at this point in the history
Nowdays you can ask for an IRQ to be allocated but not enabled, when PCMCIA
was written this was not true and this feature is thus not used

[linux@dominikbrodowski.net: add comment and ifdef to avoid compilation
 breakage at least on alpha]
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
  • Loading branch information
Alan Cox authored and Dominik Brodowski committed Jun 24, 2008
1 parent 05f43d4 commit 635416e
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions drivers/pcmcia/pcmcia_resource.c
Original file line number Diff line number Diff line change
Expand Up @@ -812,6 +812,15 @@ int pcmcia_request_irq(struct pcmcia_device *p_dev, irq_req_t *req)
type = IRQF_SHARED;

#ifdef CONFIG_PCMCIA_PROBE

#ifdef IRQ_NOAUTOEN
/* if the underlying IRQ infrastructure allows for it, only allocate
* the IRQ, but do not enable it
*/
if (!(req->Attributes & IRQ_HANDLE_PRESENT))
type |= IRQ_NOAUTOEN;
#endif /* IRQ_NOAUTOEN */

if (s->irq.AssignedIRQ != 0) {
/* If the interrupt is already assigned, it must be the same */
irq = s->irq.AssignedIRQ;
Expand Down

0 comments on commit 635416e

Please sign in to comment.