drm_pagemap..._set_pagemap(9)
π« NAME π«
drm_pagemap_cache_set_pagemap β bestie, this is the one that assigns a drm_pagemap to a drm_pagemap_cache β¨
(also hi, this is the section 9 kernel API manual, we're in the deep lore today π«Ά)
πΈ SYNOPSIS πΈ
void drm_pagemap_cache_set_pagemap(struct drm_pagemap_cache *cache,
struct drm_pagemap *dpagemap);
π ARGUMENTS π
cacheβ thedrm_pagemap_cacheyou're assigning thedrm_pagemapto πdpagemapβ thedrm_pagemapyou're assigning, periodt.
π¦ DESCRIPTION π¦
okay so listen π β you call this function to populate a drm_pagemap_cache, and there is exactly one correct moment to do it: only after a call to drm_pagemap_get_from_cache has returned NULL. That's the vibe check, that's the window, that's your moment β¨
no cap, the ordering is the whole bit β get theNULLfromdrm_pagemap_get_from_cachefirst, then populate with this one π
π SEE ALSO π
the whole friend group, lowkey iconic:
- kernel file
./drivers/gpu/drm/drm_pagemap_util.cπ struct drm_pagemap_cache(9)struct drm_pagemap_shrinker(9)drm_pagemap_cache_create_devm(9)Cache lookup(9)drm_pagemap_cache_lock_lookup(9)drm_pagemap_cache_unlock_lookup(9)drm_pagemap_get_from_cache(9)drm_pagemap_get_from_cache_if_active(9)drm_pagemap_shrinker_might_lock(9)drm_pagemap_shrinker_add(9)drm_pagemap_shrinker_create_devm(9)struct drm_pagemap_owner(9)drm_pagemap_release_owner(9)interconnect_fn(9)drm_pagemap_acquire_owner(9)
π that's the whole page bestie, go populate some caches responsibly. shoutout to ./drivers/gpu/drm for housing this masterpiece, dated October 2026, filed under drm_pagemap..._set_pagemap(9) β ily, 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