CVE-2026-89757: mm/mglru: fix and remove redundant unevictable folio handling

Published Sep 11, 2026
·
Updated

In the Linux kernel, the following vulnerability has been resolved:

mm/mglru: fix and remove redundant unevictable folio handling

sortfolio() has a shortcut for moving folios that are no longer evictable but are still sitting on a generation list. However, this shortcut is buggy. It does not follow the PGlru usage convention, and it has a more serious issue.

Unevictable folios are not threaded on lists[LRUUNEVICTABLE], so that folio->lru can be reused to hold folio->mlockcount (see the comment in lruvecinit()). Hence lruvecaddfolio() skips the listadd() for them, and every other place that turns a folio unevictable initialises mlockcount explicitly: lruadd() sets it to 0, mlockfolio() and mlocknewfolio() set it to !!foliotestmlocked(folio). sortfolio() sets nothing, and the lrugendelfolio() right above it may have already poisoned folio->lru via listdel(), so mlockcount ends up aliasing LISTPOISON2, which reads as 0x122, i.e. 290. The result is user visible. On munlock, munlockfolio() decrements that bogus count, finds it still non-zero and bails out before clearing PGmlocked, so the folio remains unevictable and the Mlocked accounting stays inflated until the folio is freed.

The shortcut also touches the LRU flags in the wrong order. It calls lrugendelfolio() while PGlru is still set, so a concurrent foliotestclearlru() (e.g. compaction, folioisolatelru()) can succeed on a folio that has already been taken off the generation list, which may lead to unexpected behavior.

So fix it by isolating them as common folios and letting the generic shrink path cull them. This matches the classical LRU behavior, and there should be no visible effect on the generic eviction or isolation behavior.

There is no performance concern either, such a folio goes through this once, and then it is off the generation lists for good.

Affected Software

1 affected component
Linux Kernel

Event History

Sep 11, 2026
CVE Published
via MITRE·07:46 PM
Data Sourced
via MITRE·07:46 PM
Description

Frequently Asked Questions

1

Which systems and workloads are most likely to encounter this issue?

The issue affects Linux kernel memory-management paths involving multi-generation LRU and folios that become unevictable while still on a generation list. Workloads that lock and later unlock memory through mlock/munlock are relevant to the user-visible failure described.

2

What condition triggers the incorrect state?

A folio must no longer be evictable while it remains on a generation list, causing the affected shortcut to handle it without initializing its mlock count. A later munlock can then decrement a bogus nonzero count and exit without clearing the mlocked state.

3

How could an administrator identify that the problem has occurred?

The described symptom is that memory remains unevictable after munlock and mlocked-memory accounting stays inflated. This can appear as folios retaining their mlocked state when they should have been released.

4

Is a fix available?

The vulnerability is described as resolved, and three stable kernel commit references are provided. No affected or fixed kernel version ranges are supplied in the available data.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203