Subject: Re: [PATCH] Fix Maple PATA IRQ assignment.

From: Segher Boessenkool <[email-masked]>
Date: Mon, 1 Jan 2007 23:17:57 +0100

>>> Or does it have
>>> the ide strapped to native mode ?
>>
>> It's not a strapping, it's a purely software thing -- see the PCIIDE
>> specification.
>
> I know the PCI IDE spec, but there are a number of chips out there that
> cannot be changed without a strap.

Sure, but not the 8111.

> In this case, it's easy to test
> though we'll need fixups in the device-tree to indicate the change in
> routing, or a quirk.
>
> The thing is, there -is- a cascaded 8259 in there,

But it's disabled, the HT APIC is used instead.

> and that's where the
> IRQ14 and IRQ15 end up in legacy mode (edge sensitive even) iirc, 
> unless
> they are aslo routed to the APIC directly, but in anyway it's hidden by
> the firmware.
>
> So we can have a quirk in the Maple code to reconfigure that all in
> native mode.

It's probably best to trust the OF device tree, and only do
quirks if that turns out to be wrong.  David says that's exactly
what his patch does, so...  :-)

> Or keep the hook and use it in libata. It makes sense I think in
> general. I reckon other platforms might have good use of being able to
> "remap" those IRQs 14 and 15 from IDE controllers in legacy mode.

Yeah.

> I've
> seen plenty of cases where  they are kept in that mode just to keep the
> IRQs non-shared.

Bad idea IMHO, but hey, can't fix the hardware in software ;-)

Segher