Merge branch 'linux-3.18' of git://anongit.freedesktop.org/git/nouveau/linux-2.6...
authorDave Airlie <airlied@redhat.com>
Mon, 20 Oct 2014 06:14:19 +0000 (16:14 +1000)
committerDave Airlie <airlied@redhat.com>
Mon, 20 Oct 2014 06:14:19 +0000 (16:14 +1000)
two nouveau fixes.

* 'linux-3.18' of git://anongit.freedesktop.org/git/nouveau/linux-2.6:
  drm/nouveau: fix regression on agp boards
  drm/gt215/gr: fix initialisation on gddr5 boards

1  2 
drivers/gpu/drm/nouveau/nouveau_chan.c

index 589dbb582da200c543b2ee04e9296d58e0d70e1f,77c81d6b45ee2ea34add2ffd102815269fb1c916..fd3dbd59d73e18113a6ef357e658570c113155be
@@@ -285,7 -285,6 +285,7 @@@ nouveau_channel_init(struct nouveau_cha
        struct nouveau_software_chan *swch;
        struct nv_dma_v0 args = {};
        int ret, i;
 +      bool save;
  
        nvif_object_map(chan->object);
  
        }
  
        /* initialise synchronisation */
 -      return nouveau_fence(chan->drm)->context_new(chan);
 +      save = cli->base.super;
 +      cli->base.super = true; /* hack until fencenv50 fixed */
 +      ret = nouveau_fence(chan->drm)->context_new(chan);
 +      cli->base.super = save;
 +      return ret;
  }
  
  int
@@@ -400,15 -395,20 +400,20 @@@ nouveau_channel_new(struct nouveau_drm 
                    struct nouveau_channel **pchan)
  {
        struct nouveau_cli *cli = (void *)nvif_client(&device->base);
+       bool super;
        int ret;
  
+       /* hack until fencenv50 is fixed, and agp access relaxed */
+       super = cli->base.super;
+       cli->base.super = true;
        ret = nouveau_channel_ind(drm, device, handle, arg0, pchan);
        if (ret) {
                NV_PRINTK(debug, cli, "ib channel create, %d\n", ret);
                ret = nouveau_channel_dma(drm, device, handle, pchan);
                if (ret) {
                        NV_PRINTK(debug, cli, "dma channel create, %d\n", ret);
-                       return ret;
+                       goto done;
                }
        }
  
        if (ret) {
                NV_PRINTK(error, cli, "channel failed to initialise, %d\n", ret);
                nouveau_channel_del(pchan);
-               return ret;
        }
  
-       return 0;
+ done:
+       cli->base.super = super;
+       return ret;
  }