Skip to content
BSD syscall#514

svc · unix #514

__channel_set_opt

Sets a per-channel Skywalk option, e.g. wake policy or scheduler class.

Prototype

int __channel_set_opt(int c, uint32_t opt, const void *aoptval, uint32_t optlen);

Returns: int

Arguments

NameTypeDirDescription
cint-
optuint32_t-
aoptvalconst void-
optlenuint32_t-

Version history

XNU tagmacOS#
xnu-8792.41.9macOS 13.0 Ventura514
xnu-10002.1.13macOS 14.0 Sonoma514
xnu-11215.1.10macOS 15.0 Sequoia514
xnu-11417.101.15macOS 15.4 Sequoia514
xnu-12377.1.9macOS 26.0 Tahoe514
xnu-10002.41.9514
xnu-10002.61.3514
xnu-10002.81.5514
xnu-10063.101.15514
xnu-10063.121.3514
xnu-10063.141.1514
xnu-11215.41.3514
xnu-11215.61.5514
xnu-11215.81.4514
xnu-11417.121.6514
xnu-11417.140.69514
xnu-12377.101.15514
xnu-12377.41.6514
xnu-12377.61.12514
xnu-12377.81.4514
xnu-8019.80.24514
xnu-8020.101.4514
xnu-8020.121.3514
xnu-8020.140.41514
xnu-8792.61.2514
xnu-8792.81.2514
xnu-8796.101.5514
xnu-8796.121.2514
xnu-8796.141.3514

Notes

Used to dial in QoS hints, enable/disable interrupt moderation, mark a channel as low-power-eligible, or attach a defunct callback. Some options require the channel to be in a quiesced state, returning EBUSY otherwise. The SK_OPT_DEFUNCT_OK option lets a process voluntarily release its rings under memory pressure without losing the channel handle.

Detection

Not visible to ES. Anomalous use is paired with __channel_open by an unexpected caller.

Related APIs

__channel_get_opt__channel_open__channel_syncsetsockopt