]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - arch/x86/kernel/pci-gart_64.c
driver core: fix a lot of printk usages of bus_id
[linux-2.6-omap-h63xx.git] / arch / x86 / kernel / pci-gart_64.c
index a614ee10f8468ab8411955105b94d1dc858f90e2..df5f142657d27352a9e3c1bbd911fd89f677c1fa 100644 (file)
@@ -32,6 +32,7 @@
 #include <asm/mtrr.h>
 #include <asm/pgtable.h>
 #include <asm/proto.h>
+#include <asm/iommu.h>
 #include <asm/gart.h>
 #include <asm/cacheflush.h>
 #include <asm/swiotlb.h>
@@ -197,9 +198,7 @@ static void iommu_full(struct device *dev, size_t size, int dir)
         * out. Hopefully no network devices use single mappings that big.
         */
 
-       printk(KERN_ERR
-               "PCI-DMA: Out of IOMMU space for %lu bytes at device %s\n",
-               size, dev->bus_id);
+       dev_err(dev, "PCI-DMA: Out of IOMMU space for %lu bytes\n", size);
 
        if (size > PAGE_SIZE*EMERGENCY_PAGES) {
                if (dir == PCI_DMA_FROMDEVICE || dir == PCI_DMA_BIDIRECTIONAL)
@@ -679,11 +678,8 @@ static __init int init_k8_gatt(struct agp_kern_info *info)
        /* need to map that range */
        end_pfn = (aper_base>>PAGE_SHIFT) + (aper_size>>PAGE_SHIFT);
        if (end_pfn > max_low_pfn_mapped) {
-               start_pfn = max_low_pfn_mapped;
-               max_low_pfn_mapped = init_memory_mapping(start_pfn<<PAGE_SHIFT,
-                                                        end_pfn<<PAGE_SHIFT);
-               if (max_pfn_mapped < max_low_pfn_mapped)
-                       max_pfn_mapped = max_low_pfn_mapped;
+               start_pfn = (aper_base>>PAGE_SHIFT);
+               init_memory_mapping(start_pfn<<PAGE_SHIFT, end_pfn<<PAGE_SHIFT);
        }
        return 0;