Port-i386 archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Interrupt routing patch for testing




To: port-i386%netbsd.org@localhost, port-amd64%netbsd.org@localhost

Subject: Re: Interrupt routing patch for testing

From: Joerg Sonnenberger <joerg%britannica.bec.de@localhost>

Date: Sat, 10 May 2008 00:13:53 +0200


On Fri, May 09, 2008 at 10:33:57PM +0100, Andrew Doran wrote:
> On Thu, May 08, 2008 at 11:12:19PM +0200, Joerg Sonnenberger wrote:
> 
> >  intr_allocate_slot_cpu(struct cpu_info *ci, struct pic *pic, int pin,
> >                    int *index)
> >  {
> > -   int start, slot, i;
> > +   int slot, i;
> >     struct intrsource *isp;
> >  
> > -   start = CPU_IS_PRIMARY(ci) ? NUM_LEGACY_IRQS : 0;
> > -   slot = -1;
> > +   if (pic == &i8259_pic) {
> > +           if (!CPU_IS_PRIMARY(ci))
> > +                   return EBUSY;
> 
> ENODEV is more accurate. I haven't checked the callers.

I think it just migrates up. I'll change it to ENODEV.

> FWIW, the locking in intr.c isn't very good. We'll also need to look at
> having an IPI or other mechanism like RCU's patent-free predecessor make the
> updates safe on a running system.

Yeah, I know. I'm thinking about dropping the linked list and just use a
dynamic array. If you give me something to lazily free it e.g. after a
roundtrip over all CPUs, we are done.

Joerg


Follow-Ups:

Re: Interrupt routing patch for testing
From: Andrew Doran


References:

Interrupt routing patch for testing
From: Joerg Sonnenberger

Re: Interrupt routing patch for testing
From: Andrew Doran




Prev by Date: Re: Interrupt routing patch for testing

Next by Date: Re: Interrupt routing patch for testing

Previous by Thread: Re: Interrupt routing patch for testing

Next by Thread: Re: Interrupt routing patch for testing

Indexes:

reverse Date

reverse Thread

Old Index



Home | Main Index | Thread Index | Old Index