]> git.baikalelectronics.ru Git - kernel.git/commitdiff
drm/nouveau/fifo/gk104-gp1xx: fix creation of sw class
authorBen Skeggs <bskeggs@redhat.com>
Tue, 2 Mar 2021 11:36:14 +0000 (21:36 +1000)
committerBen Skeggs <bskeggs@redhat.com>
Tue, 2 Mar 2021 11:48:42 +0000 (21:48 +1000)
Fixes: 497f5eadaeed851e ("drm/nouveau/fifo: add id_engine hook")
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
drivers/gpu/drm/nouveau/nvkm/engine/fifo/gk104.c

index 69da601f1754a5cfe4b852a120bc3f7be2c617e9..e771bd519ee24f0e30fc155eecc0cc7f5b9ff86f 100644 (file)
@@ -261,6 +261,9 @@ gk104_fifo_pbdma = {
 struct nvkm_engine *
 gk104_fifo_id_engine(struct nvkm_fifo *base, int engi)
 {
+       if (engi == GK104_FIFO_ENGN_SW)
+               return nvkm_device_engine(base->engine.subdev.device, NVKM_ENGINE_SW, 0);
+
        return gk104_fifo(base)->engine[engi].engine;
 }