[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <874kf0doq7.ffs@nanos.tec.linutronix.de>
Date: Tue, 18 May 2021 17:51:44 +0200
From: Thomas Gleixner <tglx@...utronix.de>
To: Will Deacon <will@...nel.org>
Cc: LKML <linux-kernel@...r.kernel.org>,
Peter Zijlstra <peterz@...radead.org>,
Robin Murphy <robin.murphy@....com>,
Nitesh Lal <nilal@...hat.com>,
Jesse Brandeburg <jesse.brandeburg@...el.com>,
Marc Zyngier <maz@...nel.org>,
Mark Rutland <mark.rutland@....com>,
linux-arm-kernel@...ts.infradead.org, Frank Li <Frank.li@....com>,
Shawn Guo <shawnguo@...nel.org>,
Sascha Hauer <s.hauer@...gutronix.de>,
Pengutronix Kernel Team <kernel@...gutronix.de>,
Fabio Estevam <festevam@...il.com>,
NXP Linux Team <linux-imx@....com>,
Shaokun Zhang <zhangshaokun@...ilicon.com>
Subject: Re: [patch 0/8] genirq, perf: Cleanup the abuse of irq_set_affinity_hint()
On Tue, May 18 2021 at 11:48, Will Deacon wrote:
> On Tue, May 18, 2021 at 11:17:25AM +0200, Thomas Gleixner wrote:
>> The modular PMU drivers use irq_set_affinity_hint() to set the affinity
>> for the PMU interrupts, which relies on the undocumented side effect that
>> this function actually sets the affinity under the hood.
>>
>> Setting an hint is clearly not a guarantee and for these PMU interrupts an
>> affinity hint, which is supposed to guide userspace for setting affinity,
>> is beyond pointless, because the affinity of these interrupts cannot be
>> modified from user space.
>>
>> Aside of that the error checks are bogus because the only error which is
>> returned from irq_set_affinity_hint() is when there is no irq descriptor
>> for the interrupt number, but not when the affinity set fails. That's on
>> purpose because the hint can point to an offline CPU.
>>
>> Sigh, if people would at least talk if something is missing...
>>
>> Clean up the mess by exposing irq_set_affinity() and converting the drivers
>> over to that.
>
> This all looks good to me, thanks. Given the number of PMU drivers it
> touches, it may well conflict with driver work for 5.14. If you put the
> IRQ core stuff on a stable branch, then I could pull that into the Arm
> perf tree and stick all the driver changes on top. That also means any
> new drivers that come in can use irq_set_affinity() right away.
>
> Does that work for you?
Sure. I'll send you a tag to pull ...
Thanks,
tglx
Powered by blists - more mailing lists