drivers/gpu/drm/xe/xe_lmtt_types.h

Source file repositories/reference/linux-study-clean/drivers/gpu/drm/xe/xe_lmtt_types.h

File Facts

System
Linux kernel
Corpus path
drivers/gpu/drm/xe/xe_lmtt_types.h
Extension
.h
Size
1439 bytes
Lines
64
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.

Dependency Surface

Detected Declarations

Annotated Snippet

struct xe_lmtt {
	/** @pd: root LMTT Directory */
	struct xe_lmtt_pt *pd;

	/** @ops: LMTT functions */
	const struct xe_lmtt_ops *ops;
};

/**
 * struct xe_lmtt_pt - Local Memory Translation Table Page Table
 *
 * Represents single level of the LMTT.
 */
struct xe_lmtt_pt {
	/** @level: page table level, 0 is leaf */
	unsigned int level;

	/** @bo: buffer object with actual LMTT PTE values */
	struct xe_bo *bo;

	/** @entries: leaf page tables, exist only for root/non-leaf */
	struct xe_lmtt_pt *entries[];
};

/**
 * struct xe_lmtt_ops - Local Memory Translation Table Operations
 *
 * Provides abstraction of the LMTT variants.
 */
struct xe_lmtt_ops {
	/* private: */
	unsigned int (*lmtt_root_pd_level)(void);
	unsigned int (*lmtt_pte_num)(unsigned int level);
	unsigned int (*lmtt_pte_size)(unsigned int level);
	unsigned int (*lmtt_pte_shift)(unsigned int level);
	unsigned int (*lmtt_pte_index)(u64 addr, unsigned int level);
	u64 (*lmtt_pte_encode)(unsigned long offset, unsigned int level);
};

extern const struct xe_lmtt_ops lmtt_2l_ops;
extern const struct xe_lmtt_ops lmtt_ml_ops;

#endif

Annotation

Implementation Notes