summaryrefslogtreecommitdiff
path: root/include/linux/highmem.h
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2021-07-26 12:55:17 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2021-07-26 12:55:17 +0200
commit71e69d7adee10a55b817df748dec5bfec7bf4c30 (patch)
treeac342851e20df5a5f7891cc603998b654d26724c /include/linux/highmem.h
parent03b1292d1c0ea195e025e667555d74db7da82026 (diff)
parentff1176468d368232b684f75e82563369208bc371 (diff)
Merge 5.14-rc3 into char-misc-next
We need the char-misc fixes from 5.14-rc3 into here as well. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/highmem.h')
-rw-r--r--include/linux/highmem.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/include/linux/highmem.h b/include/linux/highmem.h
index 8c6e8e996c87..d9a606a9fc64 100644
--- a/include/linux/highmem.h
+++ b/include/linux/highmem.h
@@ -318,14 +318,16 @@ static inline void memcpy_to_page(struct page *page, size_t offset,
VM_BUG_ON(offset + len > PAGE_SIZE);
memcpy(to + offset, from, len);
+ flush_dcache_page(page);
kunmap_local(to);
}
static inline void memzero_page(struct page *page, size_t offset, size_t len)
{
- char *addr = kmap_atomic(page);
+ char *addr = kmap_local_page(page);
memset(addr + offset, 0, len);
- kunmap_atomic(addr);
+ flush_dcache_page(page);
+ kunmap_local(addr);
}
#endif /* _LINUX_HIGHMEM_H */