Re: [PATCH] net: mvpp2: Fix affinity hint allocation

From: David Miller
Date: Tue Oct 30 2018 - 14:40:18 EST


From: Marc Zyngier <marc.zyngier@xxxxxxx>
Date: Tue, 30 Oct 2018 15:41:00 +0000

> The mvpp2 driver has the curious behaviour of passing a stack variable
> to irq_set_affinity_hint(), which results in the kernel exploding
> the first time anyone accesses this information. News flash: userspace
> does, and irqbalance will happily take the machine down. Great stuff.
>
> An easy fix is to track the mask within the queue_vector structure,
> and to make sure it has the same lifetime as the interrupt itself.
>
> Fixes: e531f76757eb ("net: mvpp2: handle cases where more CPUs are available than s/w threads")
> Signed-off-by: Marc Zyngier <marc.zyngier@xxxxxxx>
> ---
> As requested in 20181030135354.GD3407@kwain/">https://lore.kernel.org/lkml/20181030135354.GD3407@kwain/

Applied.