cros_ec_cmd_xfer_status(9)
π cros_ec_cmd_xfer_status(9) π
okay so this is a page from the Kernel API Manual, and honestly bestie, it's a whole little function with main character energy. Sit down, hydrate, let's get into it π«Ά
β¨ NAME β¨
cros_ec_cmd_xfer_status β literally the function you call to send a command to the ChromeOS EC. that's the whole vibe. π
πΈ SYNOPSIS πΈ
int cros_ec_cmd_xfer_status (struct cros_ec_device *ec_dev , struct
cros_ec_command *msg );
she takes two things and gives you back an int, no cap β¨
π ARGUMENTS π
ec_devβ the EC device. like, the actual guy you're talking to π¦msgβ the message to write. the thing you wanna say to him π
π« DESCRIPTION π«
Call this to send a command to the ChromeOS EC. periodt.
and like, actually call this one β not the EC's cmd_xfer callback directly, bestie. lowkey that's the whole point of this wrapper and the docs are being so serious about it π
the tea is: it only returns a success status if both things went down, and you need both, no exceptions:
- the command was transmitted successfully β
- the EC replied with success status β
two yeses or it's a no. that's the vibe check π₯
π RETURN π
>=0β the number of bytes transferred. she ate and left crumbs π<0β a Linux error code. π it's giving sad girl hours, go check your errno
π SEE ALSO π
Kernel file ./drivers/platform/chrome/cros_ec_proto.c β that's where she lives, iykyk β
and the whole friend group, all of them, here we go:
cros_ec_prepare_tx(9)cros_ec_check_result(9)cros_ec_get_host_event_wake_mask(9)cros_ec_get_host_command_version_mask(9)cros_ec_query_all(9)cros_ec_cmd_xfer(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)
like an entire group chat of EC functions, and they're all iconic in their own way π§
ngl, the<bold>-worthy takeaway here: use the wrapper, check both the transfer and the EC's reply, and don't go pokingcmd_xferyourself. π
okay that's the page!! mwah π this manual page came to us from the ./drivers/platform/chrome directory and it's dated October 2026 β slay, putting that in my calendar ποΈβ¨ byeee π¦π
π¦ 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