drm/gm100/bios: hw disable register has moved
authorBen Skeggs <bskeggs@redhat.com>
Mon, 24 Feb 2014 02:30:06 +0000 (12:30 +1000)
committerBen Skeggs <bskeggs@redhat.com>
Wed, 26 Mar 2014 04:00:56 +0000 (14:00 +1000)
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
drivers/gpu/drm/nouveau/core/subdev/bios/base.c

index ef0c9c4a8cc3925f9f8df1279417fc028a39f2f9..13bb829f959cec50117f7024dafc3c7c49818994 100644 (file)
@@ -90,10 +90,16 @@ nouveau_bios_shadow_pramin(struct nouveau_bios *bios)
        int i;
 
        if (device->card_type >= NV_50) {
-               if (  device->card_type < NV_C0 ||
-                   !(nv_rd32(bios, 0x022500) & 0x00000001))
-                       addr = (u64)(nv_rd32(bios, 0x619f04) & 0xffffff00) << 8;
+               if (device->card_type >= NV_C0 && device->card_type < GM100) {
+                       if (nv_rd32(bios, 0x022500) & 0x00000001)
+                               return;
+               } else
+               if (device->card_type >= GM100) {
+                       if (nv_rd32(bios, 0x021c04) & 0x00000001)
+                               return;
+               }
 
+               addr = (u64)(nv_rd32(bios, 0x619f04) & 0xffffff00) << 8;
                if (!addr) {
                        addr  = (u64)nv_rd32(bios, 0x001700) << 16;
                        addr += 0xf0000;