diff options
author | Vladimir Kondratyev <wulf@FreeBSD.org> | 2021-11-15 14:48:17 +0000 |
---|---|---|
committer | Vladimir Kondratyev <wulf@FreeBSD.org> | 2022-01-10 19:49:36 +0000 |
commit | 9a79e08ae761f1d53c982e1d089b923e25b0092f (patch) | |
tree | 00cae97f0cd8de54ec8b55606e4f272825472c96 | |
parent | dbc920bd9a9b413182a1940155539a3144a405aa (diff) | |
download | src-9a79e08ae761f1d53c982e1d089b923e25b0092f.tar.gz src-9a79e08ae761f1d53c982e1d089b923e25b0092f.zip |
LinuxKPI: Add clflush argument type conversion wrapper
to reduce amount of source patching in drm-kmod.
MFC after: 1 week
Reviewed by: manu
Differential Revision: https://reviews.freebsd.org/D33288
-rw-r--r-- | sys/compat/linuxkpi/common/include/linux/page.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/compat/linuxkpi/common/include/linux/page.h b/sys/compat/linuxkpi/common/include/linux/page.h index 0c3d456d6ec0..7cdaf01dce03 100644 --- a/sys/compat/linuxkpi/common/include/linux/page.h +++ b/sys/compat/linuxkpi/common/include/linux/page.h @@ -105,6 +105,7 @@ pgprot2cachemode(pgprot_t prot) #define trunc_page(x) ((uintptr_t)(x) & ~(PAGE_SIZE - 1)) #if defined(__i386__) || defined(__amd64__) +#undef clflush #undef clflushopt static inline void lkpi_clflushopt(unsigned long addr) @@ -116,6 +117,7 @@ lkpi_clflushopt(unsigned long addr) else pmap_invalidate_cache(); } +#define clflush(x) clflush((unsigned long)(x)) #define clflushopt(x) lkpi_clflushopt((unsigned long)(x)) #endif |