None of the chipsets we use this on have instanced engines, so this is fine.
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Reviewed-by: Lyude Paul <lyude@redhat.com>
                        chan->func->engine_dtor(chan, engine);
                nvkm_object_del(&engn->object);
                if (chan->vmm)
-                       atomic_dec(&chan->vmm->engref[engine->subdev.index]);
+                       atomic_dec(&chan->vmm->engref[engine->subdev.type]);
        }
 }
 
                };
 
                if (chan->vmm)
-                       atomic_inc(&chan->vmm->engref[engine->subdev.index]);
+                       atomic_inc(&chan->vmm->engref[engine->subdev.type]);
 
                if (engine->func->fifo.cclass) {
                        ret = engine->func->fifo.cclass(chan, &cclass,
 
                case NVKM_ENGINE_MSVLD : id = 0x09; break;
                case NVKM_ENGINE_CIPHER:
                case NVKM_ENGINE_SEC   : id = 0x0a; break;
-               case NVKM_ENGINE_CE0   : id = 0x0d; break;
+               case NVKM_ENGINE_CE    : id = 0x0d; break;
                default:
                        continue;
                }