simplecmd_store(9)
π NAME π
simplecmd_store β bestie, this is the one that sends a simple IPC command π
So like, this page? It's from the Kernel API Manual, and it's all about yeeting a lil' command off to the PMC. iykyk β¨
β¨ SYNOPSIS β¨
ssize_t simplecmd_store (struct device *dev , struct device_attribute
*attr , const char *buf , size_t count );
That's the whole vibe check right there π«Ά
πΈ ARGUMENTS πΈ
devβ the device that the attribute is chillin' under πattrβ the attribute in question, aka the one being talked about πbufβ the buffer holding the data that's getting stored to the attribute π¦countβ how many bytes are inbuf(the length, the size, the whole deal) π’
π DESCRIPTION π
Okay so lowkey here's the tea: this function expects a string with two integers separated with space π
Those two values? They hold the command and the subcommand that gets sent to the PMC. That's it, that's the whole job, and honestly? Iconic. π
π₯ RETURN π₯
On success it returns the number of bytes written β which is count, no cap β or a negative errno if something went wrong π
π¦ SEE ALSO π¦
The kernel file ./drivers/mfd/intel_pmc_bxt.c is the main character here, and you gotta go look at intel_pmc_gcr_read64(9), intel_pmc_gcr_update(9), intel_pmc_s0ix_counter_read(9), and northpeak_store(9) too β¨
ngl bestie, send a real command with real subcommand integers or the negative errno will absolutely humble you π
And that's the page!! π§ββοΈ Straight from ./drivers/mfd, dated October 2026, slaying in the Kernel API Manual the entire time. Periodt. ππβ
π¦ 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