linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: [PATCH] generic irq subsystem: ppc64 port
       [not found] <200410190714.i9J7Elnx027734@hera.kernel.org>
@ 2004-10-19  8:28 ` Benjamin Herrenschmidt
  2004-10-19  8:41   ` Christoph Hellwig
  2004-10-19  9:15   ` Ingo Molnar
  0 siblings, 2 replies; 4+ messages in thread
From: Benjamin Herrenschmidt @ 2004-10-19  8:28 UTC (permalink / raw)
  To: mingo; +Cc: Linux Kernel list, linuxppc64-dev, Linus Torvalds, Paul Mackerras

Hi !

That patch will unfortunately break a load of ppc64 boxes.

If you look closely at the ppc64 code, you'll notice we don't
use the irq_desc array directly but go through a get_irq_desc()
accessor. This is because our interrupt numbers can be very
large and scattered, and thus we have a remapping tree.

I still like the idea of the patch, so it would be useful if
you added the possibility for us to just change that behaviour,
that is replace all occursences of irq_descs + i with get_irq_desc()
and provide a generic one that just does that, with a #ifndef so
that the architecture can provide it's own. 

If you agree with the principle, though, I suppose I can do it
and send a proposed patch tomorrow.

Ben.




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] generic irq subsystem: ppc64 port
  2004-10-19  8:28 ` [PATCH] generic irq subsystem: ppc64 port Benjamin Herrenschmidt
@ 2004-10-19  8:41   ` Christoph Hellwig
  2004-10-19  9:15   ` Ingo Molnar
  1 sibling, 0 replies; 4+ messages in thread
From: Christoph Hellwig @ 2004-10-19  8:41 UTC (permalink / raw)
  To: Benjamin Herrenschmidt
  Cc: mingo, Linux Kernel list, linuxppc64-dev, Linus Torvalds, Paul Mackerras

On Tue, Oct 19, 2004 at 06:28:20PM +1000, Benjamin Herrenschmidt wrote:
> Hi !
> 
> That patch will unfortunately break a load of ppc64 boxes.
> 
> If you look closely at the ppc64 code, you'll notice we don't
> use the irq_desc array directly but go through a get_irq_desc()
> accessor. This is because our interrupt numbers can be very
> large and scattered, and thus we have a remapping tree.
> 
> I still like the idea of the patch, so it would be useful if
> you added the possibility for us to just change that behaviour,
> that is replace all occursences of irq_descs + i with get_irq_desc()
> and provide a generic one that just does that, with a #ifndef so
> that the architecture can provide it's own. 
> 
> If you agree with the principle, though, I suppose I can do it
> and send a proposed patch tomorrow.

The PPC64 changes were actually my fault.  I think get_irq_desc() is okay.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] generic irq subsystem: ppc64 port
  2004-10-19  8:28 ` [PATCH] generic irq subsystem: ppc64 port Benjamin Herrenschmidt
  2004-10-19  8:41   ` Christoph Hellwig
@ 2004-10-19  9:15   ` Ingo Molnar
  2004-10-20  1:24     ` Benjamin Herrenschmidt
  1 sibling, 1 reply; 4+ messages in thread
From: Ingo Molnar @ 2004-10-19  9:15 UTC (permalink / raw)
  To: Benjamin Herrenschmidt
  Cc: Linux Kernel list, linuxppc64-dev, Linus Torvalds,
	Paul Mackerras, Christoph Hellwig


* Benjamin Herrenschmidt <benh@kernel.crashing.org> wrote:

> I still like the idea of the patch, so it would be useful if you added
> the possibility for us to just change that behaviour, that is replace
> all occursences of irq_descs + i with get_irq_desc() and provide a
> generic one that just does that, with a #ifndef so that the
> architecture can provide it's own. 

sure, we could do that. But since there are other architectures with
large irq-vector spaces too, you might want to try to move it into the
generic IRQ code and just provide a way to switch between 1:1 mapped and
sparse-mapped variants.

(of course this still means all of the direct indexing in kernel/irq/*.c
would have to change.)

	Ingo

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] generic irq subsystem: ppc64 port
  2004-10-19  9:15   ` Ingo Molnar
@ 2004-10-20  1:24     ` Benjamin Herrenschmidt
  0 siblings, 0 replies; 4+ messages in thread
From: Benjamin Herrenschmidt @ 2004-10-20  1:24 UTC (permalink / raw)
  To: Ingo Molnar
  Cc: Linux Kernel list, linuxppc64-dev, Linus Torvalds,
	Paul Mackerras, Christoph Hellwig

On Tue, 2004-10-19 at 19:15, Ingo Molnar wrote:
> * Benjamin Herrenschmidt <benh@kernel.crashing.org> wrote:
> 
> > I still like the idea of the patch, so it would be useful if you added
> > the possibility for us to just change that behaviour, that is replace
> > all occursences of irq_descs + i with get_irq_desc() and provide a
> > generic one that just does that, with a #ifndef so that the
> > architecture can provide it's own. 
> 
> sure, we could do that. But since there are other architectures with
> large irq-vector spaces too, you might want to try to move it into the
> generic IRQ code and just provide a way to switch between 1:1 mapped and
> sparse-mapped variants.

False alert ! In fact, Paulus rewrote that stuff a while ago and I
totally forgot about it. We no longer do that, our get_irq_desc()
is nowadays just doing (&irq_desc[(irq)]). We map the large
physical interrupt numbers to "virtual" numbers that are the only
thing the generic code sees, so it's fine. 

Ben.



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2004-10-20  1:37 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <200410190714.i9J7Elnx027734@hera.kernel.org>
2004-10-19  8:28 ` [PATCH] generic irq subsystem: ppc64 port Benjamin Herrenschmidt
2004-10-19  8:41   ` Christoph Hellwig
2004-10-19  9:15   ` Ingo Molnar
2004-10-20  1:24     ` Benjamin Herrenschmidt

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).