gaokun_ec_write(9)
π gaokun_ec_write(9) β like, the kernel API manual page, bestie
okay so we're in the Kernel API Manual today and the main character of this page is gaokun_ec_write π«Ά that's the function name and the manual name, so jot that down iykyk
β¨ NAME β¨
gaokun_ec_write β Write to EC π
πΈ SYNOPSIS πΈ
int gaokun_ec_write (struct gaokun_ec *ec , const u8 *req );
π ARGUMENTS π
ecβ Thegaokun_ecstructure π the whole vibe, the context, the little guy you're handing overreqβ The sequence to request β¨ like, the actual bytes you want sent
π¦ DESCRIPTION π¦
okay so real talk, this function has no big difference from gaokun_ec_read β they're basically twins, fr fr π―
but here's the ~moment~: when the caller cares only about write status and no actual data are returned, then use it. that's the whole thing. that's the assignment. periodt π
so like, if you're sitting there waiting for a payload to come back, wrong function bestie π this one's just here to tell you if the write went okay.
π₯ RETURN π₯
0on success π- negative error code if it went sideways π (not zero, not "meh" β negative, ngl that's how you know)
π SEE ALSO π
the absolute squad, ok, look at this lineup π
- Kernel file
./drivers/platform/arm64/huawei-gaokun-ec.cβ the source, the origin story π§ gaokun_ec_read(9)gaokun_ec_register_notify(9)gaokun_ec_unregister_notify(9)gaokun_ec_psy_multi_read(9)gaokun_ec_psy_get_smart_charge(9)gaokun_ec_psy_set_smart_charge(9)gaokun_ec_psy_get_smart_charge_enable(9)gaokun_ec_psy_set_smart_charge_enable(9)gaokun_ec_ucsi_read(9)gaokun_ec_ucsi_write(9)gaokun_ec_ucsi_get_reg(9)gaokun_ec_ucsi_pan_ack(9)
and that's the page!! π this iconic little number lives in ./drivers/platform/arm64, dated October 2026, and it answers to the name gaokun_ec_write(9) β go forth and write to that EC, bestie, you got this ππ¦β¨
π¦ 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