STRUCT CROS_EC_PLATFORM(9)
π struct cros_ec_platform(9) β like, the Kernel API Manual era β¨
okay so bestie, welcome to the glow-up of cros_ec_platform π
this is the little struct that carries around your ChromeOS EC platform info β the receipts, the vibes, the whole β¨situationβ¨. it lives in the kernel, it's lowkey iconic, and we're gonna read it together like a group chat at 2am π«Ά
πΈ NAME πΈ
struct cros_ec_platform β ChromeOS EC platform information. that's it, that's the whole main-character job π
β¨ SYNOPSIS β¨
struct cros_ec_platform {
const char *ec_name;
u16 cmd_offset;
};
look at her. two fields. no notes. ate and left no crumbs π
π Members π
ec_nameβ the name of the EC device, like'cros-ec','cros-pd', ... (you get the idea, the list goes on π«). this is the name that shows up in/dev/and in sysfs, so like, it's the one doing the introducing at the party π. type isconst char *, ngl she's a keeper.cmd_offsetβ the offset to apply for each command π₯. it gets set when you're registering a device that sits behind another one β like, the device is standing behind its friend in the photo, y'know? πΈ type isu16, so keep it cute and keep it in range π.
π¦ SEE ALSO π¦
- the kernel file
./include/linux/platform_data/cros_ec_proto.hπ struct cros_ec_command(9)β the command struct, bestie of the family πstruct cros_ec_device(9)β the device struct, also here, also slaying β¨struct cros_ec_dev(9)β the dev struct, you guessed it, in the lineup πΈcros_ec_get_time_ns(9)β the time-getting one, clocking in with nanosecond precision β±οΈ
fr fr go read those too, they're all connected, iykyk π§
aaaand that's the page!! mwah π this whole thing is filed under ./include/linux/platform_data, dated October 2026, and it's brought to you by the one and only Kernel API Manual β periodt, no cap, bye bestie πππ¦
π¦ 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