|
18 | 18 | #include <linux/pci_ids.h>
|
19 | 19 | #include <linux/pci.h>
|
20 | 20 | #include <linux/bitops.h>
|
21 |
| -#include <linux/ioport.h> |
22 | 21 | #include <linux/suspend.h>
|
23 | 22 | #include <asm/e820.h>
|
24 | 23 | #include <asm/io.h>
|
@@ -54,18 +53,6 @@ int fallback_aper_force __initdata;
|
54 | 53 |
|
55 | 54 | int fix_aperture __initdata = 1;
|
56 | 55 |
|
57 |
| -static struct resource gart_resource = { |
58 |
| - .name = "GART", |
59 |
| - .flags = IORESOURCE_MEM, |
60 |
| -}; |
61 |
| - |
62 |
| -static void __init insert_aperture_resource(u32 aper_base, u32 aper_size) |
63 |
| -{ |
64 |
| - gart_resource.start = aper_base; |
65 |
| - gart_resource.end = aper_base + aper_size - 1; |
66 |
| - insert_resource(&iomem_resource, &gart_resource); |
67 |
| -} |
68 |
| - |
69 | 56 | /* This code runs before the PCI subsystem is initialized, so just
|
70 | 57 | access the northbridge directly. */
|
71 | 58 |
|
@@ -96,7 +83,6 @@ static u32 __init allocate_aperture(void)
|
96 | 83 | memblock_reserve(addr, aper_size);
|
97 | 84 | printk(KERN_INFO "Mapping aperture over %d KB of RAM @ %lx\n",
|
98 | 85 | aper_size >> 10, addr);
|
99 |
| - insert_aperture_resource((u32)addr, aper_size); |
100 | 86 | register_nosave_region(addr >> PAGE_SHIFT,
|
101 | 87 | (addr+aper_size) >> PAGE_SHIFT);
|
102 | 88 |
|
@@ -444,12 +430,8 @@ int __init gart_iommu_hole_init(void)
|
444 | 430 |
|
445 | 431 | out:
|
446 | 432 | if (!fix && !fallback_aper_force) {
|
447 |
| - if (last_aper_base) { |
448 |
| - unsigned long n = (32 * 1024 * 1024) << last_aper_order; |
449 |
| - |
450 |
| - insert_aperture_resource((u32)last_aper_base, n); |
| 433 | + if (last_aper_base) |
451 | 434 | return 1;
|
452 |
| - } |
453 | 435 | return 0;
|
454 | 436 | }
|
455 | 437 |
|
|
0 commit comments