drm/nouveau/fifo/gf100: fix certain engines not being recovered after a fault
authorBen Skeggs <bskeggs@redhat.com>
Fri, 11 Mar 2016 03:09:28 +0000 (13:09 +1000)
committerBen Skeggs <bskeggs@redhat.com>
Mon, 14 Mar 2016 00:13:38 +0000 (10:13 +1000)
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
drivers/gpu/drm/nouveau/nvkm/engine/fifo/gf100.c

index c56311acc9fe907ecdb299d1a876fbf1fff9651a..352a0baec84d70332245caaf857ad3ba09118c7b 100644 (file)
@@ -148,11 +148,11 @@ gf100_fifo_recover_work(struct work_struct *w)
        fifo->recover.mask = 0ULL;
        spin_unlock_irqrestore(&fifo->base.lock, flags);
 
-       for (todo = mask; engn = __ffs64(todo), todo; todo &= ~(1 << engn))
+       for (todo = mask; engn = __ffs64(todo), todo; todo &= ~BIT_ULL(engn))
                engm |= 1 << gf100_fifo_engidx(fifo, engn);
        nvkm_mask(device, 0x002630, engm, engm);
 
-       for (todo = mask; engn = __ffs64(todo), todo; todo &= ~(1 << engn)) {
+       for (todo = mask; engn = __ffs64(todo), todo; todo &= ~BIT_ULL(engn)) {
                if ((engine = nvkm_device_engine(device, engn))) {
                        nvkm_subdev_fini(&engine->subdev, false);
                        WARN_ON(nvkm_subdev_init(&engine->subdev));