FIRMWARE LAYOUT(9)
π Firmware Layout(9) π
okay bestie so you're reading the Firmware Layout page from the Kernel API Manual and honestly? it's giving "anatomy diagram but make it firmware" and we're gonna get through it together π«Ά
πΈ The Actual Layout πΈ
The GuC/HuC firmware layout looks like this, no cap:
+======================================================================+
| Firmware blob |
+===============+===============+============+============+============+
| CSS header | uCode | RSA key | modulus | exponent |
+===============+===============+============+============+============+
<-header size-> <---header size continued ----------->
<--- size ----------------------------------------------------------->
<-key size->
<-mod size->
<-exp size->
so like, the firmware may or may not have the modulus key and exponent data β it's optional, she's flexible π . But the header, uCode and RSA signature are must-have components that will be used by the driver. periodt.
The length of each component β which is all in dwords btw, write that down β can be found in the header. And in the case that modulus and exponent are NOT present in the fw, a.k.a a truncated image, the length value still appears in the header. like it's still invited to the party even if it doesn't show up, iykyk β¨
π¦ The Driver's Size Validation Rules π¦
The driver does some basic fw size validation based on the following rules, and honestly it's very "let me just vibe-check this real quick":
- Header, uCode and RSA are must-have components.
- All firmware components, if they present, are in the sequence illustrated in the layout table above.
- Length info of each component can be found in header, in dwords.
- Modulus and exponent key are not required by driver. They may not appear in fw. So driver will load a truncated firmware in this case.
π The DG2 Plot Twist π
Starting from DG2, the HuC is loaded by the GSC instead of i915. main character energy fr fr π
The GSC firmware performs all the required integrity checks, so we just need to check the version. easy slay.
β οΈ heads up bestie: note that the header for GSC-managed blobs is different from the CSS used for dma-loaded firmwares. don't mix them up, that's not the vibe π
β¨ SEE ALSO β¨
- Kernel file
./drivers/gpu/drm/i915/gt/uc/intel_uc_fw_abi.h
that's the whole thing, you ate that π this iconic little page lives in ./drivers/gpu/drm/i915/gt/uc, it's dated October 2026, and it's the one and only Firmware Layout(9) β go forth and read firmware headers responsibly, mwah ππ
π¦ 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