On Fri, Apr 24, 2026 at 05:48:40AM -0700, Andrew Morton wrote: > On Fri, 24 Apr 2026 05:24:01 -0700 Breno Leitao <[email protected]> wrote: > > > Add documentation for the new vm.panic_on_unrecoverable_memory_failure > > sysctl, describing the three categories of failures that trigger a > > panic and noting which kernel page types are not yet covered. > > > > > > ... > > > > +When enabled, this sysctl triggers a panic on three categories of > > +unrecoverable failures: reserved kernel pages, non-buddy kernel pages > > +with zero refcount (e.g. tail pages of high-order allocations), and > > +pages whose state cannot be classified as recoverable. > > Before someone asks, I wonder if we should make this a bitfield thing, > so people can select which of the above three should get the panic > treatment.
That's an interesting idea, though I think the necessary infrastructure doesn't exist yet. As discussed in this thread, even distinguishing non-userspace pages from userspace pages presents non-trivial challenges. Implementing a bitfield-based approach would require significant groundwork. If we want to pursue that direction, it might make sense to defer this patchset and focus on building that infrastructure first. My preference would be to start with the coarse-grained approach (current approach) and refine it incrementally based on actual needs.

