panfrost: Increase address space to 48-bit

Valhall can allow up to 48-bit of address space, we should reflect this
here to allow more memory to be mapped in the same address space when
possible.

Signed-off-by: Mary Guillemard <mary.guillemard@collabora.com>
Reviewed by: Eric R. Smith <eric.smith@collabora.com>

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30088>
This commit is contained in:
Mary Guillemard
2024-07-08 16:10:47 +02:00
committed by Marge Bot
parent 04685e732e
commit 02e38664f3

View File

@@ -78,13 +78,13 @@ panfrost_open_device(void *memctx, int fd, struct panfrost_device *dev)
if (!dev->model)
goto err_free_kmod_dev;
/* 32bit address space, with the lower 32MB reserved. We clamp
/* 48bit address space max, with the lower 32MB reserved. We clamp
* things so it matches kmod VA range limitations.
*/
uint64_t user_va_start = panfrost_clamp_to_usable_va_range(
dev->kmod.dev, PANFROST_VA_RESERVE_BOTTOM);
uint64_t user_va_end =
panfrost_clamp_to_usable_va_range(dev->kmod.dev, 1ull << 32);
panfrost_clamp_to_usable_va_range(dev->kmod.dev, 1ull << 48ull);
dev->kmod.vm = pan_kmod_vm_create(
dev->kmod.dev, PAN_KMOD_VM_FLAG_AUTO_VA | PAN_KMOD_VM_FLAG_TRACK_ACTIVITY,