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] [day] [month] [year] [list]
Message-Id: <20240313085144.13b37a79c688b6126af0bd07@linux-foundation.org>
Date: Wed, 13 Mar 2024 08:51:44 -0700
From: Andrew Morton <akpm@...ux-foundation.org>
To: "Huang, Ying" <ying.huang@...el.com>
Cc: Donet Tom <donettom@...ux.ibm.com>, linux-mm@...ck.org,
 linux-kernel@...r.kernel.org, Aneesh Kumar <aneesh.kumar@...nel.org>,
 Michal Hocko <mhocko@...nel.org>, Dave Hansen
 <dave.hansen@...ux.intel.com>, Mel Gorman <mgorman@...e.de>, Feng Tang
 <feng.tang@...el.com>, Andrea Arcangeli <aarcange@...hat.com>, Peter
 Zijlstra <peterz@...radead.org>, Ingo Molnar <mingo@...hat.com>, Rik van
 Riel <riel@...riel.com>, Johannes Weiner <hannes@...xchg.org>, Matthew
 Wilcox <willy@...radead.org>, Vlastimil Babka <vbabka@...e.cz>, Dan
 Williams <dan.j.williams@...el.com>, Hugh Dickins <hughd@...gle.com>,
 Kefeng Wang <wangkefeng.wang@...wei.com>, Suren Baghdasaryan
 <surenb@...gle.com>
Subject: Re: [PATCH v2 2/2] mm/numa_balancing:Allow migrate on protnone
 reference with MPOL_PREFERRED_MANY policy

On Mon, 11 Mar 2024 09:37:36 +0800 "Huang, Ying" <ying.huang@...el.com> wrote:

> > @@ -2515,15 +2516,26 @@ int mpol_misplaced(struct folio *folio, struct vm_fault *vmf,
> >  		break;
> >  
> >  	case MPOL_BIND:
> > -		/* Optimize placement among multiple nodes via NUMA balancing */
> > +	case MPOL_PREFERRED_MANY:
> > +		/*
> > +		 * Even though MPOL_PREFERRED_MANY can allocate pages outside
> > +		 * policy nodemask we don't allow numa migration to nodes
> > +		 * outside policy nodemask for now. This is done so that if we
> > +		 * want demotion to slow memory to happen, before allocating
> > +		 * from some DRAM node say 'x', we will end up using a
> > +		 * MPOL_PREFERRED_MANY mask excluding node 'x'. In such scenario
> > +		 * we should not promote to node 'x' from slow memory node.
> > +		 */
> 
> This is a little hard to digest for me.  And, I don't think that we need
> to put this policy choice in code comments.  It's better to put it in
> patch description.  Where we can give more background, for example, to
> avoid cross-socket traffic, etc.

Oh.  I like the comment.  We could perhaps put additional detail in the
changelog, but using changelogs to understand the code is so darned
inconvenient.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ