IT lexicon › Networking › NAPI

NAPI

Networking På svenska → Updated: 2026-07-29

The mechanism that makes a Linux network driver stop using interrupts and start polling once traffic gets dense enough. The defence against a machine choking on its own interrupts.

At low traffic, interrupts are right: the packet arrives, the processor wakes, latency is minimal. At high traffic the same thing becomes catastrophic, because interrupt handling has higher priority than everything else — the machine can end up receiving packets at full speed while never getting time to actually process them, a state called receive livelock. NAPI solves it by having the driver disable further interrupts on the first one and letting the kernel pull packets out of the ring buffer in batches instead, with a cap per batch so other work gets through. When the queue empties, interrupts are re-enabled. The cap is set with net.core.netdev_budget.

← Back to the lexicon