nvk: Use the OS page size in nvk_AllocateMemory

In bccb9fe091 ("nvk/nvkmd: nouveau uses the OS page size"),
the alignment size was narrowed to the OS page size in
nvkmd_nouveau_alloc_tiled_mem. This makes the same change
for nvk_AllocateMemory.

This is being done in preparation for large page support, which will
be more picky about alignments.

Reviewed-by: Mohamed Ahmed <mohamedahmedegypt2001@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/38702>
This commit is contained in:
Mel Henning 2025-11-17 15:54:29 -05:00 committed by Marge Bot
parent ab86088438
commit 7a492e102f

View file

@ -150,9 +150,7 @@ nvk_AllocateMemory(VkDevice device,
const enum nvkmd_mem_flags flags = nvk_memory_type_flags(type, handle_types);
uint32_t alignment = (1ULL << 12);
if (flags & NVKMD_MEM_LOCAL)
alignment = (1ULL << 16);
uint32_t alignment = pdev->nvkmd->bind_align_B;
uint8_t pte_kind = 0, tile_mode = 0;
if (dedicated_info != NULL) {