Port-i386 archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: Interrupt routing patch for testing
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
Home |
Main Index |
Thread Index |
Old Index