Skip to contentSkip to conversation

Please revert commit dc9372808412edbc653a675a526c2ee6c0c14a91

DISCUSSION Benjamin Herrenschmidt 3 participants 3 messages Nov 22, 2011 1 message not in the archive

lore
Share & tools
lore
#0 lore raw

Hi Linus !

Please, revert commit dc9372808412edbc653a675a526c2ee6c0c14a91

"of/irq: of_irq_find_parent: check for parent equal to child"

This breaks some powerpc platforms at least. The practice of having a node provide an explicit "interrupt-parent" property pointing to itself is an old trick that we've used in the past to allow a device-node to have interrupts routed to different controllers.

In that case, the node also contains an interrupt-map, so the node is its own parent, the interrupt resolution hits the map, which then can route each individual interrupt to a different parent.

Cheers,
Ben.

#1 lore raw
Quoted 6 lines · Benjamin Herrenschmidt

Hi Linus !

Please, revert commit dc9372808412edbc653a675a526c2ee6c0c14a91

"of/irq: of_irq_find_parent: check for parent equal to child"

Quoted 8 lines

This breaks some powerpc platforms at least. The practice of having a node provide an explicit "interrupt-parent" property pointing to itself is an old trick that we've used in the past to allow a device-node to have interrupts routed to different controllers.

In that case, the node also contains an interrupt-map, so the node is its own parent, the interrupt resolution hits the map, which then can route each individual interrupt to a different parent.

Ah, nuts, yes that is broken then. Yes, please revert the commit and Rob & I will come up with a better solution.

Rob, I think it can be done by explicitly checking for np == desc->interrupt_parent in of_irq_init() instead of relying on of_irq_find_parent() returning NULL.

g.

#3 lore raw
In reply to a message not in the archive
Quoted 17 lines · Grant Likely
Quoted 6 lines · Benjamin Herrenschmidt

Hi Linus !

Please, revert commit dc9372808412edbc653a675a526c2ee6c0c14a91

"of/irq: of_irq_find_parent: check for parent equal to child"

Quoted 8 lines

This breaks some powerpc platforms at least. The practice of having a node provide an explicit "interrupt-parent" property pointing to itself is an old trick that we've used in the past to allow a device-node to have interrupts routed to different controllers.

In that case, the node also contains an interrupt-map, so the node is its own parent, the interrupt resolution hits the map, which then can route each individual interrupt to a different parent.

Quoted 6 lines

Ah, nuts, yes that is broken then. Yes, please revert the commit and Rob & I will come up with a better solution.

Rob, I think it can be done by explicitly checking for np == desc->interrupt_parent in of_irq_init() instead of relying on of_irq_find_parent() returning NULL.

Okay. I'll prepare a patch to do that.

Rob