Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

x86/io: Remove xlate_dev_kmem_ptr() duplication

Generic header defines xlate_dev_kmem_ptr().

Reuse it from generic header and remove in x86 code.
Move a description to the generic header as well.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: Baolin Wang <baolin.wang@spreadtrum.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Mika Westerberg <mika.westerberg@linux.intel.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: intel-gfx@lists.freedesktop.org
Cc: linux-i2c@vger.kernel.org
Cc: wsa@the-dreams.de
Link: http://lkml.kernel.org/r/20170630170934.83028-5-andriy.shevchenko@linux.intel.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>

authored by

Andy Shevchenko and committed by
Ingo Molnar
eabc2a7c c2327da0

+3 -5
-5
arch/x86/include/asm/io.h
··· 216 216 #include <asm-generic/iomap.h> 217 217 218 218 /* 219 - * Convert a virtual cached pointer to an uncached pointer 220 - */ 221 - #define xlate_dev_kmem_ptr(p) p 222 - 223 - /* 224 219 * ISA space is 'always mapped' on a typical x86 system, no need to 225 220 * explicitly ioremap() it. The fact that the ISA IO space is mapped 226 221 * to PAGE_OFFSET is pure coincidence - it does not mean ISA values
+3
include/asm-generic/io.h
··· 915 915 #endif /* CONFIG_GENERIC_IOMAP */ 916 916 #endif /* CONFIG_HAS_IOPORT_MAP */ 917 917 918 + /* 919 + * Convert a virtual cached pointer to an uncached pointer 920 + */ 918 921 #ifndef xlate_dev_kmem_ptr 919 922 #define xlate_dev_kmem_ptr xlate_dev_kmem_ptr 920 923 static inline void *xlate_dev_kmem_ptr(void *addr)