summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLinus Walleij <linus.walleij@linaro.org>2023-08-10 09:40:30 +0200
committerGuo Ren <guoren@linux.alibaba.com>2023-08-10 22:12:33 -0400
commitee12fe28ae0e768af776c8e0247e83e59e5c4525 (patch)
tree722d15ed00c0326df74650ee41eaba8a2aa09b9e
parent1362d15ffb59db65b2df354b548b7915686cb05c (diff)
csky: Cast argument to virt_to_pfn() to (void *)
The virt_to_pfn() function takes a (void *) as argument, fix this up to avoid exploiting the unintended polymorphism of virt_to_pfn. Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Guo Ren <guoren@linux.alibaba.com> Signed-off-by: Guo Ren <guoren@kernel.org>
-rw-r--r--arch/arc/include/asm/page.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arc/include/asm/page.h b/arch/arc/include/asm/page.h
index e43fe27ec54d..02b53ad811fb 100644
--- a/arch/arc/include/asm/page.h
+++ b/arch/arc/include/asm/page.h
@@ -108,7 +108,7 @@ extern int pfn_valid(unsigned long pfn);
#else /* CONFIG_HIGHMEM */
-#define ARCH_PFN_OFFSET virt_to_pfn(CONFIG_LINUX_RAM_BASE)
+#define ARCH_PFN_OFFSET virt_to_pfn((void *)CONFIG_LINUX_RAM_BASE)
#endif /* CONFIG_HIGHMEM */