@@ -284,8 +284,7 @@ acpi_map_lookup_virt(void __iomem *virt, acpi_size size)
284
284
#define should_use_kmap (pfn ) page_is_ram(pfn)
285
285
#endif
286
286
287
- static void __iomem * acpi_map (acpi_physical_address pg_off , unsigned long pg_sz ,
288
- bool memory )
287
+ static void __iomem * acpi_map (acpi_physical_address pg_off , unsigned long pg_sz )
289
288
{
290
289
unsigned long pfn ;
291
290
@@ -295,8 +294,7 @@ static void __iomem *acpi_map(acpi_physical_address pg_off, unsigned long pg_sz,
295
294
return NULL ;
296
295
return (void __iomem __force * )kmap (pfn_to_page (pfn ));
297
296
} else
298
- return memory ? acpi_os_memmap (pg_off , pg_sz ) :
299
- acpi_os_ioremap (pg_off , pg_sz );
297
+ return acpi_os_ioremap (pg_off , pg_sz );
300
298
}
301
299
302
300
static void acpi_unmap (acpi_physical_address pg_off , void __iomem * vaddr )
@@ -311,10 +309,9 @@ static void acpi_unmap(acpi_physical_address pg_off, void __iomem *vaddr)
311
309
}
312
310
313
311
/**
314
- * __acpi_os_map_iomem - Get a virtual address for a given physical address range.
312
+ * acpi_os_map_iomem - Get a virtual address for a given physical address range.
315
313
* @phys: Start of the physical address range to map.
316
314
* @size: Size of the physical address range to map.
317
- * @memory: true if remapping memory, false if IO
318
315
*
319
316
* Look up the given physical address range in the list of existing ACPI memory
320
317
* mappings. If found, get a reference to it and return a pointer to it (its
@@ -324,8 +321,8 @@ static void acpi_unmap(acpi_physical_address pg_off, void __iomem *vaddr)
324
321
* During early init (when acpi_permanent_mmap has not been set yet) this
325
322
* routine simply calls __acpi_map_table() to get the job done.
326
323
*/
327
- static void __iomem __ref
328
- * __acpi_os_map_iomem (acpi_physical_address phys , acpi_size size , bool memory )
324
+ void __iomem __ref
325
+ * acpi_os_map_iomem (acpi_physical_address phys , acpi_size size )
329
326
{
330
327
struct acpi_ioremap * map ;
331
328
void __iomem * virt ;
@@ -356,7 +353,7 @@ static void __iomem __ref
356
353
357
354
pg_off = round_down (phys , PAGE_SIZE );
358
355
pg_sz = round_up (phys + size , PAGE_SIZE ) - pg_off ;
359
- virt = acpi_map (phys , size , memory );
356
+ virt = acpi_map (phys , size );
360
357
if (!virt ) {
361
358
mutex_unlock (& acpi_ioremap_lock );
362
359
kfree (map );
@@ -375,17 +372,11 @@ static void __iomem __ref
375
372
mutex_unlock (& acpi_ioremap_lock );
376
373
return map -> virt + (phys - map -> phys );
377
374
}
378
-
379
- void __iomem * __ref
380
- acpi_os_map_iomem (acpi_physical_address phys , acpi_size size )
381
- {
382
- return __acpi_os_map_iomem (phys , size , false);
383
- }
384
375
EXPORT_SYMBOL_GPL (acpi_os_map_iomem );
385
376
386
377
void * __ref acpi_os_map_memory (acpi_physical_address phys , acpi_size size )
387
378
{
388
- return (void * )__acpi_os_map_iomem (phys , size , true );
379
+ return (void * )acpi_os_map_iomem (phys , size );
389
380
}
390
381
EXPORT_SYMBOL_GPL (acpi_os_map_memory );
391
382
0 commit comments