Thread (6 messages) 6 messages, 3 authors, 2024-10-10

Re: [PATCH] asm-generic: provide generic page_to_phys and phys_to_page implementations

From: Christoph Hellwig <hch@lst.de>
Date: 2024-10-10 08:38:02
Also in: linux-alpha, linux-arch, linux-arm-kernel, linux-m68k, linux-mips, linux-riscv, linux-s390, linux-sh, linux-um, lkml, loongarch, sparclinux

On Thu, Oct 10, 2024 at 09:03:42AM +0200, Christoph Hellwig wrote:
quoted
I think we should try to have a little fewer nested macros
to evaluate here, right now this ends up expanding
__pfn_to_phys, PFN_PHYS, PAGE_SHIFT, CONFIG_PAGE_SHIFT,
page_to_pfn and __page_to_pfn. While the behavior is fine,
modern gcc versions list all of those in an warning message
if someone passes the wrong arguments.

Changing the two macros above into inline functions
would help as well, but may cause other problems.
Doing them as inlines seems useful to me, let me throw that at
the buildbot and see if anything explodes.
The inline version instantly blows up, so I'll try just open coding
the phys to/from pfn translation instead.

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help