lkml.org 
[lkml]   [2011]   [Dec]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] ata: Don't use NO_IRQ in pata_of_platform driver
On Tue, 6 Dec 2011, Dave Martin wrote:

> On Mon, Dec 05, 2011 at 02:49:01PM -0500, Nicolas Pitre wrote:
>
> > No need to convert everything.
> >
> > First move is to make irq=0 meaning no IRQ. That means making things
> > like:
> >
> > if (irq < 0)
> > if (irq >= 0)
> >
> > into
> >
> > if (irq <= 0)
> > if (irq > 0)
> >
> > And replace NO_IRQ with 0.
> >
> > That change shouldn't break anything, except those drivers which are 1)
> > being passed an actual IRQ #0 and 2) testing for no IRQ. I suspect that
> > those conditions aren't very common together.
>
> To clarify, you're suggesting that the meanings of all other IRQ values
> would not change initially?

Initially, or even ever.

> (i.e., we remap HW irq 0, if there is one,
> to some other random number but have a 1:1 mapping for everything else).

Exact.

> That could make sense as an approach.

You might notice that a true IRQ #0 passed to generic drivers is not
really frequent.


Nicolas


\
 
 \ /
  Last update: 2011-12-06 20:13    [from the cache]
©2003-2011 Jasper Spaans