twx-linux/arch/xtensa/include/asm
Max Filippov 2b83878dd7 xtensa: make __pa work with uncached KSEG addresses
When __pa is applied to virtual address in uncached KSEG region the
result is incorrect. Fix it by checking if the original address is in
the uncached KSEG and adjusting the result. It looks better than masking
off bits because pfn_valid would correctly work with new __pa results
and it may be made working in noMMU case, once we get definition for
uncached memory view.

This is required for the dma_common_mmap and DMA debug code to work
correctly: they both indirectly use __pa with coherent DMA addresses.
In case of DMA debug the visible effect is false reports that an address
mapped for DMA is accessed by CPU.

Cc: stable@vger.kernel.org
Tested-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Reviewed-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
2017-03-30 13:29:20 -07:00
..
asm-offsets.h
asm-uaccess.h xtensa: split uaccess.h into C and asm sides 2016-09-27 21:15:21 -04:00
asmmacro.h
atomic.h locking/atomic: Remove linux/atomic.h:atomic_fetch_or() 2016-06-16 10:48:32 +02:00
barrier.h
bitops.h xtensa: fix __ffs result type 2016-07-24 06:33:29 +03:00
bootparam.h
bugs.h
cache.h
cacheasm.h xtensa: define ___unlock_[di]cache_all unconditionally 2016-06-29 04:18:45 +03:00
cacheflush.h
checksum.h Replace <asm/uaccess.h> with <linux/uaccess.h> globally 2016-12-24 11:46:01 -08:00
cmpxchg.h
coprocessor.h
current.h
delay.h
device.h treewide: Move dma_ops from struct dev_archdata into struct device 2017-01-24 12:23:35 -05:00
dma-mapping.h treewide: Consolidate get_dma_ops() implementations 2017-01-24 12:23:35 -05:00
dma.h
elf.h
fb.h
fixmap.h xtensa: add alternative kernel memory layouts 2016-07-24 06:33:58 +03:00
flat.h
ftrace.h
futex.h
highmem.h xtensa: add alternative kernel memory layouts 2016-07-24 06:33:58 +03:00
hw_breakpoint.h
hw_irq.h
initialize_mmu.h xtensa: cleanup MMU setup and kernel layout macros 2016-07-24 06:33:58 +03:00
io.h
irq.h
irqflags.h
Kbuild kprobes: move kprobe declarations to asm-generic/kprobes.h 2017-02-27 18:43:45 -08:00
kmem_layout.h xtensa: cleanup MMU setup and kernel layout macros 2016-07-24 06:33:58 +03:00
mmu_context.h sched/headers: Prepare to remove the <linux/mm_types.h> dependency from <linux/sched.h> 2017-03-02 08:42:37 +01:00
mmu.h
module.h
mxregs.h
nommu_context.h
page.h xtensa: make __pa work with uncached KSEG addresses 2017-03-30 13:29:20 -07:00
param.h
pci-bridge.h
pci.h
perf_event.h
pgalloc.h tree wide: get rid of __GFP_REPEAT for order-0 allocations part I 2016-06-24 17:23:52 -07:00
pgtable.h arch, mm: convert all architectures to use 5level-fixup.h 2017-03-09 11:48:47 -08:00
platform.h xtensa: extract common CPU reset code into separate function 2016-09-11 23:53:22 -07:00
processor.h locking/core: Provide common cpu_relax_yield() definition 2016-11-17 08:17:36 +01:00
ptrace.h
regs.h
segment.h Replace <asm/uaccess.h> with <linux/uaccess.h> globally 2016-12-24 11:46:01 -08:00
serial.h
shmparam.h
signal.h
smp.h
spinlock_types.h
spinlock.h locking/spinlock, arch: Update and fix spin_unlock_wait() implementations 2016-06-14 11:55:15 +02:00
stacktrace.h
string.h
switch_to.h
syscall.h
sysmem.h xtensa: drop sysmem and switch to memblock 2016-07-24 06:34:00 +03:00
thread_info.h
timex.h
tlb.h
tlbflush.h
traps.h
types.h
uaccess.h xtensa: split uaccess.h into C and asm sides 2016-09-27 21:15:21 -04:00
ucontext.h
unaligned.h
unistd.h
user.h
vectors.h xtensa: allow merging vectors into .text section 2017-03-01 12:32:50 -08:00
vga.h