[PATCH v12 05/12] iommu/arm-smmu-v3: Add ARM_SMMU_FEAT_EVTQ for the event queue

John Garry john.garry at arm.com
Mon Nov 16 02:59:42 PST 2026


On 11/2/26 05:19, Nicolin Chen wrote:
> The driver programs and enables the event queue unconditionally, while the
> PRI queue has an ARM_SMMU_FEAT_PRI gating each of its touch points. Yet a
> kdump kernel wants to leave both of the queues alone, which would take an
> is_kdump_kernel() test at every one of those places.
> 
> Add an ARM_SMMU_FEAT_EVTQ that the probe always sets, as the event queue is
> architecturally mandatory, and gate the queue's allocation, its interrupt,
> its MSI vector, and its CR0 and IRQ_CTRL enables on it. A subsequent change
> will turn the queue off in a single place.
> 
> No functional change intended.
> 
> Suggested-by: Jason Gunthorpe<jgg at nvidia.com>
> Suggested-by: Robin Murphy<robin.murphy at arm.com>
> Acked-by: Kiryl Shutsemau (Meta)<kas at kernel.org>
> Reviewed-by: Jason Gunthorpe<jgg at nvidia.com>
> Reviewed-by: Mostafa Saleh<smostafa at google.com>
> Tested-by: Breno Leitao<leitao at kernel.org>
> Tested-by: Cristian Prundeanu<cpru at amazon.com>
> Tested-by: Shuai Xue<xueshuai at linux.alibaba.com>
> Signed-off-by: Nicolin Chen<nicolinc at nvidia.com>
> ---

FWIW, regardless of nitpicking:

Reviewed-by: John Garry <john.garry at arm.com>

>   
> +	/* The event queue is architecturally mandatory, unlike the PRI queue */

nit: I don't see a need to mention PRI

> +	smmu->features |= ARM_SMMU_FEAT_EVTQ;
> +


 > +	if (smmu->features & ARM_SMMU_FEAT_EVTQ) {
 > +		irq = smmu->evtq.q.irq;
 > +		if (irq) {

Again I am wondering if ARM_SMMU_FEAT_EVTQ unset is equivalent to irq == 
0? If we only checked irq != 0, then we would get the useful "no evtq 
irq - events will not be reported!\n" message. I don't think that this 
is printed elsewhere (for no evtq). But maybe I am missing something on 
this.



More information about the linux-arm-kernel mailing list