diff options
Diffstat (limited to 'arch/x86/mm/ioremap.c')
-rw-r--r-- | arch/x86/mm/ioremap.c | 26 |
1 files changed, 1 insertions, 25 deletions
diff --git a/arch/x86/mm/ioremap.c b/arch/x86/mm/ioremap.c index 2feb9bdedaaf..c246d259822d 100644 --- a/arch/x86/mm/ioremap.c +++ b/arch/x86/mm/ioremap.c | |||
@@ -281,30 +281,6 @@ void __iomem *ioremap_cache(resource_size_t phys_addr, unsigned long size) | |||
281 | } | 281 | } |
282 | EXPORT_SYMBOL(ioremap_cache); | 282 | EXPORT_SYMBOL(ioremap_cache); |
283 | 283 | ||
284 | static void __iomem *ioremap_default(resource_size_t phys_addr, | ||
285 | unsigned long size) | ||
286 | { | ||
287 | unsigned long flags; | ||
288 | void __iomem *ret; | ||
289 | int err; | ||
290 | |||
291 | /* | ||
292 | * - WB for WB-able memory and no other conflicting mappings | ||
293 | * - UC_MINUS for non-WB-able memory with no other conflicting mappings | ||
294 | * - Inherit from confliting mappings otherwise | ||
295 | */ | ||
296 | err = reserve_memtype(phys_addr, phys_addr + size, | ||
297 | _PAGE_CACHE_WB, &flags); | ||
298 | if (err < 0) | ||
299 | return NULL; | ||
300 | |||
301 | ret = __ioremap_caller(phys_addr, size, flags, | ||
302 | __builtin_return_address(0)); | ||
303 | |||
304 | free_memtype(phys_addr, phys_addr + size); | ||
305 | return ret; | ||
306 | } | ||
307 | |||
308 | void __iomem *ioremap_prot(resource_size_t phys_addr, unsigned long size, | 284 | void __iomem *ioremap_prot(resource_size_t phys_addr, unsigned long size, |
309 | unsigned long prot_val) | 285 | unsigned long prot_val) |
310 | { | 286 | { |
@@ -380,7 +356,7 @@ void *xlate_dev_mem_ptr(unsigned long phys) | |||
380 | if (page_is_ram(start >> PAGE_SHIFT)) | 356 | if (page_is_ram(start >> PAGE_SHIFT)) |
381 | return __va(phys); | 357 | return __va(phys); |
382 | 358 | ||
383 | addr = (void __force *)ioremap_default(start, PAGE_SIZE); | 359 | addr = (void __force *)ioremap_cache(start, PAGE_SIZE); |
384 | if (addr) | 360 | if (addr) |
385 | addr = (void *)((unsigned long)addr | (phys & ~PAGE_MASK)); | 361 | addr = (void *)((unsigned long)addr | (phys & ~PAGE_MASK)); |
386 | 362 | ||