diff options
author | Thierry Reding <treding@nvidia.com> | 2014-07-28 17:20:33 +0200 |
---|---|---|
committer | Thierry Reding <treding@nvidia.com> | 2014-11-10 15:59:21 +0100 |
commit | 4707a341b4af57c72c1573a89d303559cf7bcf88 (patch) | |
tree | adf5f6360dafaf60e00995326b92cf1664828662 /arch/s390/mm | |
parent | dc01201476ec9d62e81c0ee181531bccd8b007ff (diff) | |
download | talos-obmc-linux-4707a341b4af57c72c1573a89d303559cf7bcf88.tar.gz talos-obmc-linux-4707a341b4af57c72c1573a89d303559cf7bcf88.zip |
/dev/mem: Use more consistent data types
The xlate_dev_{kmem,mem}_ptr() functions take either a physical address
or a kernel virtual address, so data types should be phys_addr_t and
void *. They both return a kernel virtual address which is only ever
used in calls to copy_{from,to}_user(), so make variables that store it
void * rather than char * for consistency.
Also only define a weak unxlate_dev_mem_ptr() function if architectures
haven't overridden them in the asm/io.h header file.
Signed-off-by: Thierry Reding <treding@nvidia.com>
Diffstat (limited to 'arch/s390/mm')
-rw-r--r-- | arch/s390/mm/maccess.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/s390/mm/maccess.c b/arch/s390/mm/maccess.c index 2a2e35416d2f..2eb34bdfc613 100644 --- a/arch/s390/mm/maccess.c +++ b/arch/s390/mm/maccess.c @@ -176,7 +176,7 @@ static int is_swapped(unsigned long addr) * For swapped prefix pages a new buffer is returned that contains a copy of * the absolute memory. The buffer size is maximum one page large. */ -void *xlate_dev_mem_ptr(unsigned long addr) +void *xlate_dev_mem_ptr(phys_addr_t addr) { void *bounce = (void *) addr; unsigned long size; @@ -197,7 +197,7 @@ void *xlate_dev_mem_ptr(unsigned long addr) /* * Free converted buffer for /dev/mem access (if necessary) */ -void unxlate_dev_mem_ptr(unsigned long addr, void *buf) +void unxlate_dev_mem_ptr(phys_addr_t addr, void *buf) { if ((void *) addr != buf) free_page((unsigned long) buf); |