STRUCT DRM_GPUSVM_PAGES(9)
β¨ struct drm_gpusvm_pages(9) β¨
okay so bestie, we're in the Kernel API Manual today and this page is literally all about one little struct that holds a GPU SVM mapped pages situation. no cap, it's giving "small struct, big responsibilities" π
π NAME π
struct drm_gpusvm_pages β the structure that represents a GPU SVM mapped pages. yes that's the whole name, she's not wordy, she's just iconic π«Ά
πΈ SYNOPSIS πΈ
struct drm_gpusvm_pages {
struct drm_device *drm;
struct drm_pagemap_addr *dma_addr;
struct drm_pagemap *dpagemap;
struct dma_iova_state state;
unsigned long state_offset;
unsigned long notifier_seq;
struct drm_gpusvm_pages_flags flags;
};
like, look at her. seven fields. every one of them pulling her weight π
π¦ Members π¦
drmβ thestruct drm_devicethat owns the dma mappings. she's the main character whose name is on the lease πdma_addrβ the device address array. it's literally an array. of device addresses. slay β¨dpagemapβ thestruct drm_pagemapof the device pages we're dma-mapping. heads up tho: this here is assuming only onedrm_pagemapper range is allowed. that's the rule, don't come for me, i don't make the rules πstateβ the DMA IOVA state for mapping. the vibe of the mapping, if you will π₯state_offsetβ the DMA IOVA offset for mapping. she's thestate's little offset bestie π₯°notifier_seqβ the notifier sequence number of the range's pages. it counts, it sequences, it ate πflagsβ the flags for the range; seestruct drm_gpusvm_pages_flagsfor what's actually in there. go look, i'll wait π
π SEE ALSO π
Kernel file ./include/drm/drm_gpusvm.h β and like, the whole extended friend group:
struct drm_gpusvm_ops(9), struct drm_gpusvm_notifier(9), struct drm_gpusvm_pages_flags(9), struct drm_gpusvm_range_flags(9), struct drm_gpusvm_range(9), struct drm_gpusvm(9), struct drm_gpusvm_ctx(9), drm_gpusvm_init_pages(9), enum drm_gpusvm_scan_result(9), drm_gpusvm_driver_set_lock(9), drm_gpusvm_notifier_lock(9), drm_gpusvm_notifier_unlock(9), drm_gpusvm_range_start(9), drm_gpusvm_range_end(9), drm_gpusvm_range_size(9), drm_gpusvm_notifier_start(9), drm_gpusvm_notifier_end(9), drm_gpusvm_notifier_size(9), __drm_gpusvm_range_next(9), drm_gpusvm_for_each_range(9), drm_gpusvm_for_each_range_safe(9), __drm_gpusvm_notifier_next(9), drm_gpusvm_for_each_notifier(9), drm_gpusvm_for_each_notifier_safe(9)
that's the whole group chat, fr fr. go say hi π§
k that's the page!! sourced from ./include/drm, dated October 2026, and yes she's still serving struct drm_gpusvm_pages(9) realness. love that for her ππ
π¦ 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