lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Sun, 6 Feb 2022 23:33:40 +0200
From:   Mike Rapoport <rppt@...nel.org>
To:     Matthew Wilcox <willy@...radead.org>
Cc:     linux-mm@...ck.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 41/75] hexagon: Add pmd_pfn()

On Sun, Feb 06, 2022 at 08:46:45PM +0000, Matthew Wilcox wrote:
> On Sun, Feb 06, 2022 at 08:13:11PM +0200, Mike Rapoport wrote:
> > On Fri, Feb 04, 2022 at 07:58:18PM +0000, Matthew Wilcox (Oracle) wrote:
> > > I need to use this function in common code, so define it for hexagon.
> > > 
> > > Signed-off-by: Matthew Wilcox (Oracle) <willy@...radead.org>
> > > ---
> > >  arch/hexagon/include/asm/pgtable.h | 3 ++-
> > 
> > Why hexagon out of all architectures?
> > What about m68k, nios2, nds32 etc?

> Presumably they don't support CONFIG_TRANSPARENT_HUGEPAGE.
> This code isn't compiled when THP are disabled; at least I haven't
> had a buildbot complaint for any other architectures.

m68k defconfig fails:

  CC      mm/page_vma_mapped.o
mm/page_vma_mapped.c: In function 'page_vma_mapped_walk':
mm/page_vma_mapped.c:219:20: error: implicit declaration of function 'pmd_pfn'; did you mean 'pmd_off'? [-Werror=implicit-function-declaration]
  219 |     if (!check_pmd(pmd_pfn(pmde), pvmw))
      |                    ^~~~~~~
      |                    pmd_off
> 
> > > +#define pmd_pfn(pmd)	(pmd_val(pmd) >> PAGE_SHIFT)
> > 
> > I'd put it in include/linux/pgtable.h inside #ifndef pmd_pfn
> 
> That's completely upside down.  pmd_pfn() should be defined by each
> architecture (because generic code can't know anything about the format
> of PMDs); if anything pmd_page() should be defined in linux/pgtable.h
> in terms of pmd_pfn.
> 
> I'm not signing up to do that work as part of this series.  That seems
> like a distraction.

-- 
Sincerely yours,
Mike.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ