diff options
author | Greentime Hu <greentime@andestech.com> | 2018-04-19 15:38:58 +0800 |
---|---|---|
committer | Greentime Hu <greentime@andestech.com> | 2018-05-23 13:26:20 +0800 |
commit | 03969d0b3a3f6a7cd2c731eed1c4ccf76da88586 (patch) | |
tree | 71ad536a95ccab656a5ad57ee040bfecc9c0f368 /arch/nds32/mm | |
parent | 8cedb78fdf82468020a2f3b24ef63ccd397662a2 (diff) | |
download | linux-03969d0b3a3f6a7cd2c731eed1c4ccf76da88586.tar.bz2 |
nds32: Fix xfs_buf built failed by export invalidate_kernel_vmap_range and flush_kernel_vmap_range
It broke the 'allmodconfig' build.
fs/xfs/xfs_buf.c: In function 'xfs_buf_bio_end_io':
fs/xfs/xfs_buf.c:1242:3: error: implicit declaration of function 'invalidate_kernel_vmap_range' [-Werror=implicit-function-declaration]
invalidate_kernel_vmap_range(bp->b_addr, xfs_buf_vmap_len(bp));
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
fs/xfs/xfs_buf.c: In function 'xfs_buf_ioapply_map':
fs/xfs/xfs_buf.c:1312:4: error: implicit declaration of function 'flush_kernel_vmap_range' [-Werror=implicit-function-declaration]
flush_kernel_vmap_range(bp->b_addr,
^~~~~~~~~~~~~~~~~~~~~~~
Signed-off-by: Greentime Hu <greentime@andestech.com>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Diffstat (limited to 'arch/nds32/mm')
-rw-r--r-- | arch/nds32/mm/cacheflush.c | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/arch/nds32/mm/cacheflush.c b/arch/nds32/mm/cacheflush.c index 6eb786a399a2..bd52918d5923 100644 --- a/arch/nds32/mm/cacheflush.c +++ b/arch/nds32/mm/cacheflush.c @@ -273,6 +273,24 @@ void flush_kernel_dcache_page(struct page *page) local_irq_restore(flags); } +void flush_kernel_vmap_range(void *addr, int size) +{ + unsigned long flags; + local_irq_save(flags); + cpu_dcache_wb_range((unsigned long)addr, (unsigned long)addr + size); + local_irq_restore(flags); +} +EXPORT_SYMBOL(flush_kernel_vmap_range); + +void invalidate_kernel_vmap_range(void *addr, int size) +{ + unsigned long flags; + local_irq_save(flags); + cpu_dcache_inval_range((unsigned long)addr, (unsigned long)addr + size); + local_irq_restore(flags); +} +EXPORT_SYMBOL(invalidate_kernel_vmap_range); + void flush_icache_range(unsigned long start, unsigned long end) { unsigned long line_size, flags; |