cros_ec_get...version_mask(9)
π cros_ec_get...version_mask(9) π
okay bestie, welcome to the Kernel API Manual β¨ this one's a lil page about asking your ChromeOS Embedded Controller "hey girl, what version of this command do you speak?" β and it's lowkey iconic π
πΈ NAME πΈ
cros_ec_get_host_command_version_mask β no cap, that's the whole name section, the original didn't give us a one-liner so we're not gonna invent one π
β¨ SYNOPSIS β¨
int cros_ec_get_host_command_version_mask (struct cros_ec_device *ec_dev
, u16 cmd , u32 *mask );
that's the whole vibe right there π«Ά
π¦ ARGUMENTS π¦
ec_devβ the EC device you're calling, like dialing up your embedded controller bestie πcmdβ the command you wanna get the version of. yes, that command π―maskβ this is where the answer lands, but only when the function returns0. it's the output slot, bestie, it stays empty until things go right π
π DESCRIPTION π
Get the version mask of a given command. that's it, that's the whole thing, and honestly? slay π
return 0 on success, error code otherwise π (iykyk, always check your return values)
LOCKING: β οΈ the caller has ec_dev->lock mutex or the caller knows there is no other command in progress. fr fr, don't skip this β this is the vibe check for your locking discipline and it is not optional π
π§ SEE ALSO π§
the whole friend group, gathered for you π«Ά:
- Kernel file
./drivers/platform/chrome/cros_ec_proto.c cros_ec_prepare_tx(9)cros_ec_check_result(9)cros_ec_get_host_event_wake_mask(9)cros_ec_query_all(9)cros_ec_cmd_xfer(9)cros_ec_cmd_xfer_status(9)cros_ec_get_next_event(9)cros_ec_get_host_event(9)cros_ec_read_features(9)cros_ec_check_features(9)cros_ec_get_sensor_count(9)cros_ec_cmd(9)cros_ec_cmd_readmem(9)cros_ec_get_cmd_versions(9)cros_ec_device_registered(9)
and that's the page!! π this lil gem lives in ./drivers/platform/chrome, stamped October 2026, and it's part of the Kernel API Manual β go read the source, it's giving main character energy βπ₯
π¦ 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