Re: [PATCH v21 1/4] mm: add VM_DROPPABLE for designating always lazily freeable mappings

From: David Hildenbrand
Date: Mon Jul 08 2024 - 04:23:26 EST


As a side note, I'll raise that I am not a particular fan of the
"droppable" terminology, at least with the "read 0s" approach.

From a user perspective, the memory might suddenly lose its state and
read as 0s just like volatile memory when it loses power. "dropping
pages" sounds more like an implementation detail.

Just to raise why I consider "dropping" an implementation detail: in combination with a previous idea I had of exposing "nonvolatile" memory to VMs, the following might be interesting:

A hypervisor could expose special "nonvolatile memory" as separate guest physical memory region to a VM.

We could use that special memory to back these MAP_XXX regions in our guest, in addition to trying to make use of them in the guest kernel, for example for something similar to cleancache.

Long story short: it's the hypervisor that could be effectively dropping/zeroing out that memory, not the guest VM. "NONVOLATILE" might be clearer than "DROPPABLE".

But again, naming is hard ... :)

--
Cheers,

David / dhildenb