[PATCH v3 0/2] csky: Convert memory accessors to static inlines

From: Linus Walleij
Date: Thu Aug 10 2023 - 03:40:54 EST


This converts the virt_to_pfn and pfn_to_virt macros
into static inlines so we get proper type checking on
the pointers passed in.

Signed-off-by: Linus Walleij <linus.walleij@xxxxxxxxxx>
---
Changes in v3:
- Do not return const void * from pfn_to_virt(), return
void * so we don't case a mess.
- Link to v2: https://lore.kernel.org/r/20230809-csky-virt-to-phys-v2-0-2697c93f60cf@xxxxxxxxxx

Changes in v2:
- Fix compilation error on pfn_to_virt() by more casting.
- Return const void * rather than just void * from pfn_to_virt()
- Link to v1: https://lore.kernel.org/r/20230808-csky-virt-to-phys-v1-0-ac727f8def2f@xxxxxxxxxx

---
Linus Walleij (2):
csky: Cast argument to virt_to_pfn() to (void *)
csky: Make pfn accessors static inlines

arch/arc/include/asm/page.h | 2 +-
arch/csky/include/asm/page.h | 13 ++++++++++---
2 files changed, 11 insertions(+), 4 deletions(-)
---
base-commit: 06c2afb862f9da8dc5efa4b6076a0e48c3fbaaa5
change-id: 20230808-csky-virt-to-phys-3d80c17211f9

Best regards,
--
Linus Walleij <linus.walleij@xxxxxxxxxx>