STRUCT CDX_MCDI_IFACE(9)
π¦ struct cdx_mcdi_iface(9) β the MCDI protocol context, explained
okay so bestie, welcome to the Kernel API Manual page for struct cdx_mcdi_iface β¨ this is the little home where the MCDI protocol context lives, and honestly? it's giving main character energy in the CDX world π
πΈ NAME
struct cdx_mcdi_iface β the MCDI protocol context π
like, this struct is the vibe where all your MCDI state hangs out. periodt.
β¨ SYNOPSIS
struct cdx_mcdi_iface {
struct cdx_mcdi *cdx;
struct mutex iface_lock;
unsigned int outstanding_cleanups;
struct list_head cmd_list;
struct workqueue_struct *workqueue;
wait_queue_head_t cmd_complete_wq;
struct cdx_mcdi_cmd *db_held_by;
struct cdx_mcdi_cmd *seq_held_by[16];
unsigned int prev_handle;
enum cdx_mcdi_mode mode;
u8 prev_seq;
bool new_epoch;
};
no cap, that's the whole shape of it π
π«Ά Members (the whole cast, no one gets left out)
cdxβ the associated NIC π» like, the network interface this whole thing is attached to.iface_lockβ serialise access to this structure π literally the bouncer at the door, one at a time please.outstanding_cleanupsβ count of cleanups π§Ή keeping track of how many cleanups are still outstanding.cmd_listβ list of outstanding and running commands π both the ones in flight and the ones still waiting, all in one list.workqueueβ workqueue used for delayed processing β³ the place where delayed work gets handled.cmd_complete_wqβ waitqueue for command completion π΄ you sit here and wait until your command is done.db_held_byβ the command the MC doorbell is in use by π whoever's holding the doorbell right now.seq_held_byβ the command each sequence number is in use by π’ an array where each slot says which command is using that sequence number.prev_handleβ the last used command handle π·οΈ the handle that got used most recently.modeβ poll for mcdi completion, or wait for anmcdi_eventπ two whole lifestyles: you either poll, or you wait for the event. choose your fighter.prev_seqβ the last used sequence number π same energy asprev_handle, but for sequences.new_epochβ indicates start of day or start of MC reboot recovery π a fresh start β either the beginning of a day or the beginning of MC reboot recovery. iconic either way.
π SEE ALSO
- Kernel file
./include/linux/cdx/mcdi.h enum cdx_mcdi_mode(9)enum cdx_mcdi_cmd_state(9)struct cdx_mcdi(9)struct cdx_mcdi_cmd(9)struct cdx_mcdi_data(9)
go read those next, bestie, iykyk π§
heads up glampire: this page is filed under ./include/linux/cdx and it's dated October 2026 β that's the source and the version/date, so don't @ me when you're citing it π
and that's the whole page β struct cdx_mcdi_iface(9) from the Kernel API Manual, source ./include/linux/cdx, October 2026. slay πβπ₯
π¦ 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