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

Xie Yuanbin <[email protected]>
Newsgroups org.kvack.linux-mm,org.kernel.vger.linux-kernel
Message-ID <[email protected]>
On Wed, 12 Aug 2026 11:53:29 +0100, Lorenzo Stoakes (ARM) wrote:
> But you seem to be implying the two options cannot both be enabled, that's
> untrue:
>
> $ grep CONFIG_MIGRATION .config
> CONFIG_MIGRATION=y
> $ grep CONFIG_MEMORY_FAILURE .config
> CONFIG_MEMORY_FAILURE=y
>
> Have you disabled compaction somehow?
>
> It sounds like your .config is broken and... you need to fix it yourself not
> edit mm/Kconfig?
>
> If not you need to spell out exactly what config it is you have where you must
> not have one of the things that select migration, but do want it anyway.
>
> I'm not sure we'd even support that?
>
> Right now:
>
>	CONFIG_COMPACTION (!)
>	CONFIG_MEMORY_HOTREMOVE
>	CONFIG_NUMA_MIGRATION
>	CONFIG_CMA
>
> All select CONFIG_MIGRATION. Why is it that you cannot select one of these?

As you say, currently, MEMORY_FAILURE and MIGRATION can be both
enabled, however, you must enable one of the following configs
at the same time:
	CONFIG_COMPACTION
	CONFIG_MEMORY_HOTREMOVE
	CONFIG_NUMA_MIGRATION
	CONFIG_CMA

However, for embedded devices, these configs are not always enabled, and
they can indeed be manually disable. This is the actual situation I am
currently encountering.

> What
> weird config needs CONFIG_COMPACTION disabled but does want migration just for
> soft offline debugging?

It is not for debugging, but a real configuration in the production environment:
	CONFIG_COMPACTION=n
	CONFIG_MEMORY_HOTREMOVE=n
	CONFIG_NUMA=n
	CONFIG_CMA=n
	CONFIG_MEMORY_FAILURE=y

> Users shouldn't select this at all. And this is an absolutely horrible way of
> resolving whatever your real configuration issue is.
>
> I hate hate hate this. This is just completely the wrong resolution.

What abort making MEMORY_FAILURE select MIGRATION, just like what Mike
Rapoport said? If it's not appropriate no matter what, then let's stop
discussing this patch as if it was never submitted. I'm sorry about that.

Thanks very much.
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.