On Thu, Jun 06, 2019 at 07:17:13AM -0500, Kumar Gala wrote: > In section 2.4.1 Properties for Interrupt Generating Devices, we’ve had the following statement in the 'interrupt-parent’ section: > > If this property is missing from a device, its interrupt parent is assumed to be its devicetree parent. > > I believe we inherited this from 'Open Firmware Recommended > Practice: Interrupt Mapping, Version 0.9’. The way this reads seems > to differ from how we’ve actually implemented things for years. It's not, but I'll agree it could be clearer. > > This reads to me to mean that if a node does NOT have a > `interrupt-parent` property that the parent node is the interrupt > parent it one should expect the parent to have properties like > `interrupt-controller` or `interrupt-map`. However the behavior > we’ve used is that if `interrupt-parent` is missing, to look at the > parent for an `interrupt-parent` property and walk up the tree til > you find an `interrupt-parent` property. So, the missing piece here is that if you try to treat a node with neither interrupt-controller nor interrupt-map as an interrupt parent, it acts as though it was a trivial interrupt nexus - it basically just forwards all irqs unchanged to *its* interrupt-parent, which will be its tree parent unless otherwise specified, and so forth. > > So, maybe this should read something like: > > "If this property is missing from a device, its interrupt parent should be given by an `interrupt-parent` property on its devicetree parent” > > Thoughts? It doesn't have to be its immediate parent. It also could be an interrupt-map or interrupt controller further up the tree. I don't think I've seen an interrupt controller acting as an tree parent, but an interrupt-map nexus acting as the ancestor of nodes who implicitly have it as their interrupt-parent is standard for handling old-school PCI LSIs. -- David Gibson | I'll have my music baroque, and my code david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_ | _way_ _around_! http://www.ozlabs.org/~dgibson
Attachment:
signature.asc
Description: PGP signature