Re: [PATCH net-next v1 2/3] dinghai: add MSI-X interrupt pools

From: Andrew Lunn

Date: Mon Aug 24 2026 - 19:56:29 EST


> + * Device vectors are managed in per-purpose pools. An IRQ carries a
> + * refcount so that several event queues can share one vector; on
> + * raise, the interrupt is fanned out through an atomic notifier chain
> + * attached to the IRQ.


> +static int zxdh_irq_get_locked(struct zxdh_irq *irq)
> +{
> + lockdep_assert_held(&irq->pool->lock);
> + if (WARN_ON_ONCE(!irq->refcount))
> + return 0;
> +
> + irq->refcount++;

Why not use kref?

Andrew