Re: [RFC PATCH 2/3] wifi: ath11k: make external IRQ control idempotent

Mark Ruvald <[email protected]> Wed, 29 Jul 2026 15:40:47 +0200
Newsgroups org.infradead.lists.ath11k,org.kernel.vger.linux-wireless
Message-ID <CABmnzGrncCNgsjKHyScF_PzCWdBeezBb=utBc36cYhbzL-WyQw@mail.gmail.com>
> can you elaborate the scenario where the repeated lifecycle disable
> happen for better understand ?

Hey Karthikeyan, the scenario is a failed reset retry:

ath11k_core_reset()
  disable IRQ/NAPI                 depth 0 -> 1
  power-cycle
  recovery does not complete
    another reset_work is queued
      reset_count > 1
        wait_for(reset_complete) times out
          disable IRQ/NAPI again   depth 1 -> 2

later recovery succeeds
  enable IRQ/NAPI                  depth 2 -> 1

NAPI is then enabled, but the IRQ remains masked. The patch makes the second
lifecycle disable a no-op - ie idempotent.

This is an error/retry path, mainly the PCI/MHI reset path.

I haven't reproduced that exact sequence on hardware, but it was under
suspicion during testing, reloading of modules and kexec etc.
So this patch is more of a belt-and-suspenders kind of thing.
Idempotency helps me sleep at night.

regards Mark