mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-26 15:35:04 +07:00
885f7f8e30
The function currently known as flush_icache_user_range only operates on a single page. Rename it to flush_icache_user_page as we'll need the name flush_icache_user_range for something else soon. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Acked-by: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Richard Henderson <rth@twiddle.net> Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru> Cc: Matt Turner <mattst88@gmail.com> Cc: Tony Luck <tony.luck@intel.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Greentime Hu <green.hu@gmail.com> Cc: Vincent Chen <deanbo422@gmail.com> Cc: Jonas Bonn <jonas@southpole.se> Cc: Stefan Kristiansson <stefan.kristiansson@saunalahti.fi> Cc: Stafford Horne <shorne@gmail.com> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: Paul Walmsley <paul.walmsley@sifive.com> Cc: Palmer Dabbelt <palmer@sifive.com> Cc: Albert Ou <aou@eecs.berkeley.edu> Cc: Arnd Bergmann <arnd@arndb.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Ingo Molnar <mingo@redhat.com> Cc: Arnaldo Carvalho de Melo <acme@kernel.org> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Jiri Olsa <jolsa@redhat.com> Cc: Namhyung Kim <namhyung@kernel.org> Link: http://lkml.kernel.org/r/20200515143646.3857579-20-hch@lst.de Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
110 lines
2.2 KiB
C
110 lines
2.2 KiB
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
#ifndef _ASM_GENERIC_CACHEFLUSH_H
|
|
#define _ASM_GENERIC_CACHEFLUSH_H
|
|
|
|
/*
|
|
* The cache doesn't need to be flushed when TLB entries change when
|
|
* the cache is mapped to physical memory, not virtual memory
|
|
*/
|
|
#ifndef flush_cache_all
|
|
static inline void flush_cache_all(void)
|
|
{
|
|
}
|
|
#endif
|
|
|
|
#ifndef flush_cache_mm
|
|
static inline void flush_cache_mm(struct mm_struct *mm)
|
|
{
|
|
}
|
|
#endif
|
|
|
|
#ifndef flush_cache_dup_mm
|
|
static inline void flush_cache_dup_mm(struct mm_struct *mm)
|
|
{
|
|
}
|
|
#endif
|
|
|
|
#ifndef flush_cache_range
|
|
static inline void flush_cache_range(struct vm_area_struct *vma,
|
|
unsigned long start,
|
|
unsigned long end)
|
|
{
|
|
}
|
|
#endif
|
|
|
|
#ifndef flush_cache_page
|
|
static inline void flush_cache_page(struct vm_area_struct *vma,
|
|
unsigned long vmaddr,
|
|
unsigned long pfn)
|
|
{
|
|
}
|
|
#endif
|
|
|
|
#ifndef ARCH_IMPLEMENTS_FLUSH_DCACHE_PAGE
|
|
static inline void flush_dcache_page(struct page *page)
|
|
{
|
|
}
|
|
#define ARCH_IMPLEMENTS_FLUSH_DCACHE_PAGE 0
|
|
#endif
|
|
|
|
|
|
#ifndef flush_dcache_mmap_lock
|
|
static inline void flush_dcache_mmap_lock(struct address_space *mapping)
|
|
{
|
|
}
|
|
#endif
|
|
|
|
#ifndef flush_dcache_mmap_unlock
|
|
static inline void flush_dcache_mmap_unlock(struct address_space *mapping)
|
|
{
|
|
}
|
|
#endif
|
|
|
|
#ifndef flush_icache_range
|
|
static inline void flush_icache_range(unsigned long start, unsigned long end)
|
|
{
|
|
}
|
|
#endif
|
|
|
|
#ifndef flush_icache_page
|
|
static inline void flush_icache_page(struct vm_area_struct *vma,
|
|
struct page *page)
|
|
{
|
|
}
|
|
#endif
|
|
|
|
#ifndef flush_icache_user_page
|
|
static inline void flush_icache_user_page(struct vm_area_struct *vma,
|
|
struct page *page,
|
|
unsigned long addr, int len)
|
|
{
|
|
}
|
|
#endif
|
|
|
|
#ifndef flush_cache_vmap
|
|
static inline void flush_cache_vmap(unsigned long start, unsigned long end)
|
|
{
|
|
}
|
|
#endif
|
|
|
|
#ifndef flush_cache_vunmap
|
|
static inline void flush_cache_vunmap(unsigned long start, unsigned long end)
|
|
{
|
|
}
|
|
#endif
|
|
|
|
#ifndef copy_to_user_page
|
|
#define copy_to_user_page(vma, page, vaddr, dst, src, len) \
|
|
do { \
|
|
memcpy(dst, src, len); \
|
|
flush_icache_user_page(vma, page, vaddr, len); \
|
|
} while (0)
|
|
#endif
|
|
|
|
#ifndef copy_from_user_page
|
|
#define copy_from_user_page(vma, page, vaddr, dst, src, len) \
|
|
memcpy(dst, src, len)
|
|
#endif
|
|
|
|
#endif /* _ASM_GENERIC_CACHEFLUSH_H */
|