STRUCT DRM_PAGEMAP_ADDR(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’… struct drm_pagemap_addr(9) πŸ’…

okay so bestie, welcome to the Kernel API Manual β€” this is the page for struct drm_pagemap_addr, and honestly it's giving "small struct, big responsibilities" energy ✨


🌸 NAME 🌸

struct drm_pagemap_addr β€” Address representation. That's it. That's the whole vibe. It's a struct that represents an address. Simple queen behavior πŸ‘‘


✨ SYNOPSIS ✨

struct drm_pagemap_addr {
    dma_addr_t addr;
    u64 proto : 54;
    u64 order : 8;
    u64 dir : 2;
 };

look at those bitfields. 54 + 8 + 2 πŸ”₯ do the math, it's literally 64. the packing is real.


πŸŽ€ Members πŸŽ€

  • addr β€” this is the dma address, or a driver-defined address for driver private interconnects. so yeah, it's either the standard thing or your driver's own little custom situation. iykyk πŸ’…
  • proto β€” the interconnect protocol. which protocol? that one. the interconnect one πŸ¦‹
  • order β€” the page order of the device mapping, and before you ask, the size is PAGE_SIZE << order. yes, shift left by order. no cap, that's the formula πŸ“
  • dir β€” the DMA direction. that's it. it's the direction. of DMA. 🧭

πŸ’€ Note πŸ’€

There is room for improvement here. We should be able to pack into 64 bits.

ngl, the manpage itself is out here being self-aware 😭 it's literally saying "we could do better, we should be able to pack into 64 bits." icon energy: being honest about your own flaws. we love growth 🫢


πŸ¦‹ SEE ALSO πŸ¦‹

Kernel file ./include/drm/drm_pagemap.h enum

like, go read all of these. the whole pagemap cinematic universe is right there πŸ“


aaaand that's the page, bestie πŸ’– sourced from ./include/drm, dated October 2026 β€” mwah, slay, periodt πŸ‘‘πŸŒΈ

πŸ“¦ where this page comes from