linux/arch/hexagon
Linus Walleij d6e81532b1 Hexagon: Make pfn accessors statics inlines
Making virt_to_pfn() a static inline taking a strongly typed
(const void *) makes the contract of a passing a pointer of that
type to the function explicit and exposes any misuse of the
macro virt_to_pfn() acting polymorphic and accepting many types
such as (void *), (unitptr_t) or (unsigned long) as arguments
without warnings.

For symmetry do the same with pfn_to_virt().

For compiletime resolution of __pa() we need PAGE_OFFSET which
was not available to __pa() and resolved by the preprocessor
wherever __pa() was used. Fix this by explicitly including
<asm/mem-layout.h> where required, following the pattern of the
architectures page.h file.

Acked-by: Brian Cain <bcain@quicinc.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2023-12-05 13:11:37 +01:00
..
configs treewide: drop CONFIG_EMBEDDED 2023-08-21 13:46:25 -07:00
include Hexagon: Make pfn accessors statics inlines 2023-12-05 13:11:37 +01:00
kernel hexagon: Remove CONFIG_HEXAGON_ARCH_VERSION from uapi header 2023-11-23 10:38:58 +01:00
lib hexagon: export raw I/O routines for modules 2021-11-20 10:35:54 -08:00
mm hexagon: mm: convert to GENERIC_IOREMAP 2023-08-18 10:12:32 -07:00
Kbuild hexagon: move core-y in arch/hexagon/Makefile to arch/hexagon/Kbuild 2021-05-26 23:11:47 +09:00
Kconfig hexagon: mm: convert to GENERIC_IOREMAP 2023-08-18 10:12:32 -07:00
Kconfig.debug
Makefile kbuild: remove head-y syntax 2022-10-02 18:06:03 +09:00