Re: [PATCH] mm/Kconfig: allow user to select MIGRATION if MEMORY_FAILURE is enabled

Mike Rapoport <[email protected]>
Newsgroups org.kernel.vger.linux-kernel,org.kvack.linux-mm
Message-ID <[email protected]>
On Wed, Aug 12, 2026 at 11:55:03AM +0100, Lorenzo Stoakes (ARM) wrote:
> On Wed, Aug 12, 2026 at 01:45:30PM +0300, Mike Rapoport wrote:
> > Hi,
> >
> > On Wed, Aug 12, 2026 at 05:16:44PM +0800, Xie Yuanbin wrote:
> > > Currently, memory-failure can be enabled without migration. However,
> > > migration cannot be selected by user when memory-failure is enabled.
> > >
> > > Migration is very useful for soft_offline_page(), which may be triggered
> > > by correctable memory errors. Most of the anonymous or file-mapping
> > > faulty pages can be migrated to other healthy pages.
> > >
> > > Allow user to select MIGRATION if MEMORY_FAILURE is enabled.
> > > Also, select MIGRATION by default if MEMORY_FAILURE is enabled.
> >
> > Do we want to make users decide if they need MIGRATION when MEMORY_FAILURE
> > is enabled?
> >
> > Just make MEMORY_FAILURE select MIGRATION.
> 
> NO.
> 
> Explain first why the hell one of the other options that selection migration
> can't be enabled.

Think small systems ;-P
 
> Changing configs just to support a weirdo no to compaction but yes to doing soft
> offline for debugging or whatever isn't really convincing unless a real world,
> sensible use case can be stated.
> 
> The kernel isn't there to allow you to have broken configs.
> 
> >
> > > Signed-off-by: Xie Yuanbin <[email protected]>
> > > ---
> > >  mm/Kconfig | 3 ++-
> > >  1 file changed, 2 insertions(+), 1 deletion(-)
> > >
> > > diff --git a/mm/Kconfig b/mm/Kconfig
> > > index 8a24c130d008..b4c217383b51 100644
> > > --- a/mm/Kconfig
> > > +++ b/mm/Kconfig
> > > @@ -682,7 +682,8 @@ config NUMA_MIGRATION
> > >  	  demotion for memory tiering.
> > >
> > >  config MIGRATION
> > > -	bool
> > > +	bool "Enable page migration" if MEMORY_FAILURE
> > > +	default y if MEMORY_FAILURE
> > >  	depends on MMU
> > >
> > >  config DEVICE_MIGRATION
> > > --
> > > 2.55.0
> > >
> >
> > --
> > Sincerely yours,
> > Mike.
> 
> --
> Cheers, Lorenzo

-- 
Sincerely yours,
Mike.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.