Skip to content

Commit 9d25e28

Browse files
mbrost05rodrigovivi
authored andcommitted
drm/xe: Add has_range_tlb_invalidation device attribute
This will help implementing range based TLB invalidations. Signed-off-by: Matthew Brost <[email protected]> Signed-off-by: Rodrigo Vivi <[email protected]> Reviewed-by: Niranjana Vishwanathapura <[email protected]>
1 parent 0335b53 commit 9d25e28

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

drivers/gpu/drm/xe/xe_device_types.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,8 @@ struct xe_device {
8787
bool has_flat_ccs;
8888
/** @has_4tile: Whether tile-4 tiling is supported */
8989
bool has_4tile;
90+
/** @has_range_tlb_invalidation: Has range based TLB invalidations */
91+
bool has_range_tlb_invalidation;
9092
} info;
9193

9294
/** @irq: device interrupt state */

drivers/gpu/drm/xe/xe_pci.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ struct xe_device_desc {
7070
bool supports_usm;
7171
bool has_flat_ccs;
7272
bool has_4tile;
73+
bool has_range_tlb_invalidation;
7374
};
7475

7576
#define PLATFORM(x) \
@@ -139,6 +140,7 @@ static const struct xe_device_desc dg1_desc = {
139140
.require_force_probe = true, \
140141
.graphics_ver = 12, \
141142
.graphics_rel = 50, \
143+
.has_range_tlb_invalidation = true, \
142144
.has_flat_ccs = true, \
143145
.dma_mask_size = 46, \
144146
.max_tiles = 1, \
@@ -255,6 +257,7 @@ static const struct xe_device_desc mtl_desc = {
255257
.max_tiles = 2,
256258
.vm_max_level = 3,
257259
.media_ver = 13,
260+
.has_range_tlb_invalidation = true,
258261
PLATFORM(XE_METEORLAKE),
259262
.extra_gts = xelpmp_gts,
260263
.platform_engine_mask = MTL_MAIN_ENGINES,
@@ -407,6 +410,7 @@ static int xe_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent)
407410
xe->info.supports_usm = desc->supports_usm;
408411
xe->info.has_flat_ccs = desc->has_flat_ccs;
409412
xe->info.has_4tile = desc->has_4tile;
413+
xe->info.has_range_tlb_invalidation = desc->has_range_tlb_invalidation;
410414

411415
spd = subplatform_get(xe, desc);
412416
xe->info.subplatform = spd ? spd->subplatform : XE_SUBPLATFORM_NONE;

0 commit comments

Comments
 (0)