include/drm/ttm/ttm_pool.h
Source file repositories/reference/linux-study-clean/include/drm/ttm/ttm_pool.h
File Facts
- System
- Linux kernel
- Corpus path
include/drm/ttm/ttm_pool.h- Extension
.h- Size
- 3151 bytes
- Lines
- 101
- Domain
- Repository Root And Misc
- Bucket
- include
- Inferred role
- Repository Root And Misc: implementation source
- Status
- source implementation candidate
Why This File Exists
Top-level or miscellaneous repository surface. Use this as map coverage unless a later manual pass promotes the file into a deeper subsystem dossier.
- Top-level or miscellaneous repository surface. Use this as map coverage unless a later manual pass promotes the file into a deeper subsystem dossier.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/mmzone.hlinux/llist.hlinux/spinlock.hlinux/list_lru.hdrm/ttm/ttm_caching.h
Detected Declarations
struct devicestruct seq_filestruct ttm_backup_flagsstruct ttm_operation_ctxstruct ttm_poolstruct ttm_ttstruct ttm_pool_typestruct ttm_pool
Annotated Snippet
struct ttm_pool_type {
struct ttm_pool *pool;
unsigned int order;
enum ttm_caching caching;
struct list_head shrinker_list;
struct list_lru pages;
};
/**
* struct ttm_pool - Pool for all caching and orders
*
* @dev: the device we allocate pages for
* @nid: which numa node to use
* @alloc_flags: TTM_ALLOCATION_POOL_* flags
* @caching: pools for each caching/order
*/
struct ttm_pool {
struct device *dev;
int nid;
unsigned int alloc_flags;
struct {
struct ttm_pool_type orders[NR_PAGE_ORDERS];
} caching[TTM_NUM_CACHING_TYPES];
};
int ttm_pool_alloc(struct ttm_pool *pool, struct ttm_tt *tt,
struct ttm_operation_ctx *ctx);
void ttm_pool_free(struct ttm_pool *pool, struct ttm_tt *tt);
void ttm_pool_init(struct ttm_pool *pool, struct device *dev,
int nid, unsigned int alloc_flags);
void ttm_pool_fini(struct ttm_pool *pool);
int ttm_pool_debugfs(struct ttm_pool *pool, struct seq_file *m);
void ttm_pool_drop_backed_up(struct ttm_tt *tt);
long ttm_pool_backup(struct ttm_pool *pool, struct ttm_tt *ttm,
const struct ttm_backup_flags *flags);
int ttm_pool_restore_and_alloc(struct ttm_pool *pool, struct ttm_tt *tt,
const struct ttm_operation_ctx *ctx);
int ttm_pool_mgr_init(unsigned long num_pages);
void ttm_pool_mgr_fini(void);
#endif
Annotation
- Immediate include surface: `linux/mmzone.h`, `linux/llist.h`, `linux/spinlock.h`, `linux/list_lru.h`, `drm/ttm/ttm_caching.h`.
- Detected declarations: `struct device`, `struct seq_file`, `struct ttm_backup_flags`, `struct ttm_operation_ctx`, `struct ttm_pool`, `struct ttm_tt`, `struct ttm_pool_type`, `struct ttm_pool`.
- Atlas domain: Repository Root And Misc / include.
- Implementation status: source implementation candidate.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.