Skip to content

Commit 52e8948

Browse files
lucasdemarchiThomas Hellström
authored andcommitted
drm/xe/mmio: Cast to u64 when printing
resource_size_t uses %pa format in printk since the size varies depending on build options. However to keep the io_size/physical_size addition in the same call we can't pass the address without adding yet another variable in these function. Simply cast it to u64 and keep using %llx. Fixes: 286089c ("drm/xe: Improve vram info debug printing") Cc: Oak Zeng <[email protected]> Cc: Michael J. Ruhl <[email protected]> Cc: Matthew Brost <[email protected]> Cc: Rodrigo Vivi <[email protected]> Reviewed-by: Matt Roper <[email protected]> Signed-off-by: Lucas De Marchi <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected] (cherry picked from commit 6d8d038) Signed-off-by: Thomas Hellström <[email protected]>
1 parent 32f6c33 commit 52e8948

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/gpu/drm/xe/xe_mmio.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -272,8 +272,8 @@ int xe_mmio_probe_vram(struct xe_device *xe)
272272
drm_info(&xe->drm, "VRAM[%u, %u]: Actual physical size %pa, usable size exclude stolen %pa, CPU accessible size %pa\n", id,
273273
tile->id, &tile->mem.vram.actual_physical_size, &tile->mem.vram.usable_size, &tile->mem.vram.io_size);
274274
drm_info(&xe->drm, "VRAM[%u, %u]: DPA range: [%pa-%llx], io range: [%pa-%llx]\n", id, tile->id,
275-
&tile->mem.vram.dpa_base, tile->mem.vram.dpa_base + tile->mem.vram.actual_physical_size,
276-
&tile->mem.vram.io_start, tile->mem.vram.io_start + tile->mem.vram.io_size);
275+
&tile->mem.vram.dpa_base, tile->mem.vram.dpa_base + (u64)tile->mem.vram.actual_physical_size,
276+
&tile->mem.vram.io_start, tile->mem.vram.io_start + (u64)tile->mem.vram.io_size);
277277

278278
/* calculate total size using tile size to get the correct HW sizing */
279279
total_size += tile_size;

0 commit comments

Comments
 (0)