[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <87r0b02umj.ffs@tglx>
Date: Wed, 07 Aug 2024 17:57:40 +0200
From: Thomas Gleixner <tglx@...utronix.de>
To: Matti Vaittinen <mazziesaccount@...il.com>, Matti Vaittinen
<matti.vaittinen@...rohmeurope.com>
Cc: Mark Brown <broonie@...nel.org>, Greg Kroah-Hartman
<gregkh@...uxfoundation.org>, "Rafael J. Wysocki" <rafael@...nel.org>,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/2] regmap: Allow setting IRQ domain name suffix
Matti!
On Wed, Aug 07 2024 at 15:02, Thomas Gleixner wrote:
> On Tue, Aug 06 2024 at 14:51, Matti Vaittinen wrote:
>> Hence I'd rather learn from a small explanation (what is the
>> expected .size) than by fixing this after I see regression reports from
>> real users of the irq_domain_create_legacy() :)
>
> So the size of the domain is sum of the parameters @size and
> @first_hwirq. That's so that the hardware interrupt is zero indexed for
> an array based lookup.
>
> The association obviously wants only the @size parameter because that's
> what the caller wants interrupts for as it obviously can't provide
> interrupts below @first_hwirq.
For more background.
The legacy domain is for configurations which have fixed interrupt
numbers either in general or for parts of the interrupt space.
The trivial case is that there is a single interrupt domain with
interrupt numbers from 0 to $MAX.
But there are cases which have the interrupt space devided into chunks:
hwirq virq domain
0-15 0-15 A
16-31 16-31 B
...
To support such configurations in the irq domain world, the legacy
domain was added. Similar to that is the simple domain which allows the
caller to specify a linux interrupt number from which the domain should
start. See
1bc04f2cf8c2 ("irq_domain: Add support for base irq and hwirq in legacy mappings")
781d0f46d81e ("irq_domain: Standardise legacy/linear domain selection")
for further enlightment.
Thanks,
tglx
Powered by blists - more mailing lists