Skip to content

Commit a57ab96

Browse files
arndbRichard Kuo
authored andcommitted
hexagon: add memset_io() helper
We already have memcpy_toio(), but not memset_io(), so let's add the obvious version to allow building an allmodconfig kernel without errors like drivers/gpu/drm/ttm/ttm_bo_util.c: In function 'ttm_bo_move_memcpy': drivers/gpu/drm/ttm/ttm_bo_util.c:390:3: error: implicit declaration of function 'memset_io' [-Werror=implicit-function-declaration] Signed-off-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Richard Kuo <rkuo@codeaurora.org>
1 parent 6da6c0d commit a57ab96

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

  • arch/hexagon/include/asm

‎arch/hexagon/include/asm/io.h‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -216,6 +216,12 @@ static inline void memcpy_toio(volatile void __iomem *dst, const void *src,
216216
memcpy((void *) dst, src, count);
217217
}
218218

219+
static inline void memset_io(volatile void __iomem *addr, int value,
220+
size_t size)
221+
{
222+
memset((void __force *)addr, value, size);
223+
}
224+
219225
#define PCI_IO_ADDR (volatile void __iomem *)
220226

221227
/*

0 commit comments

Comments
 (0)