napi_synchronize(9)
π napi_synchronize β like, the Kernel API Manual, but make it make sense
okay bestie, so this is napi_synchronize(9) from the Kernel API Manual β yes that's a real section, yes we're doing this, and yes it's lowkey the politest little wait-loop in the networking stack π«Ά
β¨ NAME β¨
napi_synchronize β literally just wait until NAPI is not running, that's the whole vibe π
πΈ SYNOPSIS πΈ
void napi_synchronize (const struct napi_struct *n );
no cap, that's it. one function, one argument, zero drama β¨
π¦ ARGUMENTS π¦
nβ the NAPI context π (it's aconst struct napi_struct *, so like, we're looking, not touching π)
β DESCRIPTION β
So here's the tea: napi_synchronize waits until NAPI is done being scheduled on this context. That's it. That's the function. π
It waits till any outstanding processing completes β like, all the in-flight stuff finishes up, bestie, we're not leaving anything half-done π
But β and this is the part you gotta hear me on β it does not disable future activations. Nope. It's not a lock, it's not a gate, it's not blocking the door. It just waits for the current round to wrap up and then lets the future do its thing π
so don't be out here thinking this thing freezes NAPI forever, because it fr fr does not. it's a "wait for it to finish" not a "make it never happen again". big difference, iykyk π
π§ SEE ALSO π§
okay this list is iconic and honestly kind of long, so buckle in β everything below lives in the kernel file ./include/linux/netdevice.h:
struct gro_node(9)napi_is_scheduled(9)napi_schedule(9)napi_schedule_irqoff(9)napi_complete_done(9)napi_if_scheduled_mark_missed(9)enum netdev_priv_flags(9)struct net_device(9)netdev_priv(9)netdev_from_priv(9)netif_napi_add(9)netif_napi_add_config(9)netif_napi_add_tx(9)__netif_napi_del(9)netif_napi_del(9)netif_start_queue(9)netif_wake_queue(9)netif_stop_queue(9)netif_queue_stopped(9)netdev_queue_set_dql_min_limit(9)netdev_txq_bql_enqueue_prefetchw(9)netdev_txq_bql_complete_prefetchw(9)netdev_tx_sent_queue(9)netdev_sent_queue(9)netdev_tx_completed_queue(9)netdev_completed_queue(9)netdev_tx_reset_subqueue(9)netdev_reset_queue(9)netdev_cap_txqueue(9)netif_running(9)netif_start_subqueue(9)netif_stop_subqueue(9)__netif_subqueue_stopped(9)netif_subqueue_stopped(9)netif_wake_subqueue(9)netif_attr_test_mask(9)netif_attr_test_online(9)netif_attrmask_next(9)netif_attrmask_next_and(9)netif_is_multiqueue(9)dev_hold(9)dev_put(9)linkwatch_sync_dev(9)netif_carrier_ok(9)netif_dormant_on(9)netif_dormant_off(9)netif_dormant(9)netif_testing_on(9)netif_testing_off(9)netif_testing(9)netif_oper_up(9)netif_device_present(9)netif_tx_lock(9)__dev_uc_sync(9)__dev_uc_unsync(9)__dev_mc_sync(9)__dev_mc_unsync(9)
like i said. a lot. but every single one ate, so π€·ββοΈπ
okay that's the whole page, go be a networking girlypop π§β¨ this one's from ./include/linux, dated October 2026 β mwah, love u, bye ππ
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms