Merge branch 'linus' into x86/gart
authorIngo Molnar <mingo@elte.hu>
Thu, 12 Jun 2008 09:27:22 +0000 (11:27 +0200)
committerIngo Molnar <mingo@elte.hu>
Thu, 12 Jun 2008 09:27:22 +0000 (11:27 +0200)
1  2 
arch/x86/kernel/pci-gart_64.c

@@@ -592,9 -615,26 +615,15 @@@ static __init int init_k8_gatt(struct a
        agp_gatt_table = gatt;
  
        for (i = 0; i < num_k8_northbridges; i++) {
 -              u32 gatt_reg;
 -              u32 ctl;
 -
                dev = k8_northbridges[i];
 -              gatt_reg = __pa(gatt) >> 12;
 -              gatt_reg <<= 4;
 -              pci_write_config_dword(dev, 0x98, gatt_reg);
 -              pci_read_config_dword(dev, 0x90, &ctl);
 -
 -              ctl |= 1;
 -              ctl &= ~((1<<4) | (1<<5));
 -
 -              pci_write_config_dword(dev, 0x90, ctl);
 +              enable_gart_translation(dev, __pa(gatt));
        }
+       error = sysdev_class_register(&gart_sysdev_class);
+       if (!error)
+               error = sysdev_register(&device_gart);
+       if (error)
+               panic("Could not register gart_sysdev -- would corrupt data on next suspend");
        flush_gart();
  
        printk(KERN_INFO "PCI-DMA: aperture base @ %x size %u KB\n",