smu_cmn_get...rom_firmware(9)
π smu_cmn_get_pptable_from_firmware β like, the NAME section, bestie
okay so picture this: smu_cmn_get_pptable_from_firmware β it locates the soft pptable that's embedded in the SMC firmware binary. that's it, that's the whole vibe. it's giving "find the thing inside the bigger thing" β¨
this one lives in the Kernel API Manual, section 9, and it's genuinely so useful once you get it, i promise π«Ά
πΈ SYNOPSIS πΈ
int smu_cmn_get_pptable_from_firmware (struct smu_context *smu , void
**table , uint32_t *size , uint32_t pptable_id );
like, yes, the wrapping is ugly, but that's literally how it's written, no cap π copy it exactly and you're golden π
π ARGUMENTS π
smuβ the SMU context, aka the main character of this whole function πtableβ on success, this gets set to the start of the pptable within the firmware blob. like a little pointer bookmark π¦sizeβ on success, set to the pptable size in bytes. yes, in bytes, don't @ me πpptable_idβ the entry ID you're searching for. heads up tho: it's used only for v2.1 binaries β
β¨ DESCRIPTION β¨
okay so here's what happens. it reads the firmware header version and then dispatches to the appropriate v2.x parser β like a little router, very organized, we love to see it π§
important vibe check: only major version 2 is supported. that's the rule, don't fight it π
and then the minor version is what picks the layout:
- single-entry layout β that's v2.0 πΈ
- multi-entry directory layout β that's v2.1 π
that's the whole fork in the road. minor version decides, periodt π
π₯ RETURN π₯
0β success, slay, we ate π-EINVALβ bestieβ¦ something went wrong. this is your error if:- the version is unsupported π
- the requested pptable can't be found π
- the requested pptable exceeds the binary bounds (aka it's trying to escape the blob, not today π)
π SEE ALSO π
the source file for this one, ngl you should probably peek at it:
Kernel file ./drivers/gpu/drm/amd/pm/swsmu/smu_cmn.c
and the whole friend group of related calls, all of them iconic in their own way π:
smu_cmn_wait_for_response(9)smu_cmn_send_smc_msg_with_params_ext(9)smu_cmn_send_smc_msg_with_param(9)smu_msg_v1_send_msg(9)smu_msg_send_async_locked(9)smu_cmn_disable_all_features_with_exception(9)
fr fr, if you're getting -EINVAL and you swear the pptable exists, double-check that major version 2 thing. it's almost always that. iykyk π«Ά
okay that's the page!! this came out of ./drivers/gpu/drm/amd/pm/swsmu, dated October 2026 β bookmark it, screenshot it, send it to the group chat, whatever you gotta do. mwah π go be amazing with your pptables β¨π
π¦ 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