drivers/gpu/drm/xe/xe_pt_types.h
Source file repositories/reference/linux-study-clean/drivers/gpu/drm/xe/xe_pt_types.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/gpu/drm/xe/xe_pt_types.h- Extension
.h- Size
- 3322 bytes
- Lines
- 131
- Domain
- Driver Families
- Bucket
- drivers/gpu
- Inferred role
- Driver Families: implementation source
- Status
- source implementation candidate
Why This File Exists
Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/types.hxe_page_reclaim.hxe_pt_walk.h
Detected Declarations
struct xe_bostruct xe_devicestruct xe_vmastruct xe_ptstruct xe_pt_opsstruct xe_pt_entrystruct xe_vm_pgtable_updatestruct xe_vm_pgtable_update_opstruct xe_vm_pgtable_update_opsenum xe_cache_level
Annotated Snippet
struct xe_pt {
struct xe_ptw base;
struct xe_bo *bo;
unsigned int level;
unsigned int num_live;
bool rebind;
bool is_compact;
#if IS_ENABLED(CONFIG_DRM_XE_DEBUG_VM)
/** @addr: Virtual address start address of the PT. */
u64 addr;
#endif
};
struct xe_pt_ops {
u64 (*pte_encode_bo)(struct xe_bo *bo, u64 bo_offset,
u16 pat_index, u32 pt_level);
u64 (*pte_encode_vma)(u64 pte, struct xe_vma *vma,
u16 pat_index, u32 pt_level);
u64 (*pte_encode_addr)(struct xe_device *xe, u64 addr,
u16 pat_index,
u32 pt_level, bool devmem, u64 flags);
u64 (*pde_encode_bo)(struct xe_bo *bo, u64 bo_offset);
};
struct xe_pt_entry {
struct xe_pt *pt;
u64 pte;
};
struct xe_vm_pgtable_update {
/** @bo: page table bo to write to */
struct xe_bo *pt_bo;
/** @ofs: offset inside this PTE to begin writing to (in qwords) */
u32 ofs;
/** @qwords: number of PTE's to write */
u32 qwords;
/** @pt: opaque pointer useful for the caller of xe_migrate_update_pgtables */
struct xe_pt *pt;
/** @pt_entries: Newly added pagetable entries */
struct xe_pt_entry *pt_entries;
/** @flags: Target flags */
u32 flags;
};
/** struct xe_vm_pgtable_update_op - Page table update operation */
struct xe_vm_pgtable_update_op {
/** @entries: entries to update for this operation */
struct xe_vm_pgtable_update entries[XE_VM_MAX_LEVEL * 2 + 1];
/** @vma: VMA for operation, operation not valid if NULL */
struct xe_vma *vma;
/** @prl: Backing pointer to page reclaim list of pt_update_ops */
struct xe_page_reclaim_list *prl;
/** @num_entries: number of entries for this update operation */
u32 num_entries;
/** @bind: is a bind */
bool bind;
/** @rebind: is a rebind */
bool rebind;
};
/** struct xe_vm_pgtable_update_ops: page table update operations */
struct xe_vm_pgtable_update_ops {
/** @ops: operations */
struct xe_vm_pgtable_update_op *ops;
/** @deferred: deferred list to destroy PT entries */
struct llist_head deferred;
/** @q: exec queue for PT operations */
struct xe_exec_queue *q;
/** @prl: embedded page reclaim list */
struct xe_page_reclaim_list prl;
/** @start: start address of ops */
u64 start;
/** @last: last address of ops */
u64 last;
/** @num_ops: number of operations */
u32 num_ops;
/** @current_op: current operations */
u32 current_op;
/** @needs_svm_lock: Needs SVM lock */
bool needs_svm_lock;
/** @needs_invalidation: Needs invalidation */
bool needs_invalidation;
/**
* @wait_vm_bookkeep: PT operations need to wait until VM is idle
* (bookkeep dma-resv slots are idle) and stage all future VM activity
Annotation
- Immediate include surface: `linux/types.h`, `xe_page_reclaim.h`, `xe_pt_walk.h`.
- Detected declarations: `struct xe_bo`, `struct xe_device`, `struct xe_vma`, `struct xe_pt`, `struct xe_pt_ops`, `struct xe_pt_entry`, `struct xe_vm_pgtable_update`, `struct xe_vm_pgtable_update_op`, `struct xe_vm_pgtable_update_ops`, `enum xe_cache_level`.
- Atlas domain: Driver Families / drivers/gpu.
- 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.