LinuxKPI: Implement clflush_cache_range()

Required by drm-kmod 5.7

MFC after:	1 week
Reviewed by:	hselasky, manu
Differential Revision:	https://reviews.freebsd.org/D33289
This commit is contained in:
Vladimir Kondratyev 2021-11-15 18:06:50 +03:00
parent 9a79e08ae7
commit db562aeff7

View file

@ -119,6 +119,13 @@ lkpi_clflushopt(unsigned long addr)
}
#define clflush(x) clflush((unsigned long)(x))
#define clflushopt(x) lkpi_clflushopt((unsigned long)(x))
static inline void
clflush_cache_range(void *addr, unsigned int size)
{
pmap_force_invalidate_cache_range((vm_offset_t)addr,
(vm_offset_t)addr + size);
}
#endif
#endif /* _LINUX_PAGE_H_ */