nouveau_channel_ctor currently allocates the Volta USERD page in VRAM, but GV11B has only system memory. Request coherent, CPU-mappable host memory when the device reports zero VRAM.
Signed-off-by: Mikko Perttunen <[email protected]> --- drivers/gpu/drm/nouveau/nouveau_chan.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/nouveau/nouveau_chan.c b/drivers/gpu/drm/nouveau/nouveau_chan.c index f142f6310596..a96475ca3d02 100644 --- a/drivers/gpu/drm/nouveau/nouveau_chan.c +++ b/drivers/gpu/drm/nouveau/nouveau_chan.c @@ -326,8 +326,10 @@ nouveau_channel_ctor(struct nouveau_cli *cli, bool priv, u64 runm, /* allocate userd */ if (hosts[cid].oclass >= VOLTA_CHANNEL_GPFIFO_A) { + u8 type = device->info.ram_size ? NVIF_MEM_VRAM : NVIF_MEM_HOST; + ret = nvif_mem_ctor(&cli->mmu, "abi16ChanUSERD", NVIF_CLASS_MEM_GF100, - NVIF_MEM_VRAM | NVIF_MEM_COHERENT | NVIF_MEM_MAPPABLE, + type | NVIF_MEM_COHERENT | NVIF_MEM_MAPPABLE, 0, PAGE_SIZE, NULL, 0, &chan->mem_userd); if (ret) return ret; -- 2.56.1
