[PATCH v5 0/1] numa: add 'memmap-type' option for memory type configuration

fanhuang posted 1 patch 2 days, 5 hours ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20260123024312.1601732-1-FangSheng.Huang@amd.com
Maintainers: Eduardo Habkost <eduardo@habkost.net>, Marcel Apfelbaum <marcel.apfelbaum@gmail.com>, "Philippe Mathieu-Daudé" <philmd@linaro.org>, Yanan Wang <wangyanan55@huawei.com>, Zhao Liu <zhao1.liu@intel.com>, Paolo Bonzini <pbonzini@redhat.com>, Richard Henderson <richard.henderson@linaro.org>, "Michael S. Tsirkin" <mst@redhat.com>, Eric Blake <eblake@redhat.com>, Markus Armbruster <armbru@redhat.com>
[PATCH v5 0/1] numa: add 'memmap-type' option for memory type configuration
Posted by fanhuang 2 days, 5 hours ago
Hi all,

This is v5 of the SPM (Specific Purpose Memory) patch. Thank you for
the feedback on v4.

Changes in v5:
- Renamed 'spm=on|off' to 'memmap-type=normal|spm|reserved' enum
  (per Gregory's suggestion for better extensibility)
- Updated QAPI schema with new NumaMemmapType enum
- Updated documentation to describe SPM as a policy hint
  (per Jonathan's feedback)

Use case:
This feature allows marking NUMA node memory as Specific Purpose Memory
(SPM) or reserved in the E820 table. SPM serves as a hint to the guest
that this memory might be managed by device drivers based on guest policy

Example usage:
  -object memory-backend-ram,size=8G,id=m0
  -object memory-backend-memfd,size=8G,id=m1
  -numa node,nodeid=0,memdev=m0
  -numa node,nodeid=1,memdev=m1,memmap-type=spm

Supported memmap-type values:
  - normal:   Regular system RAM (E820 type 1, default)
  - spm:      Specific Purpose Memory (E820 type 0xEFFFFFFF), a hint
              that this memory might be managed by device drivers
  - reserved: Reserved memory (E820 type 2), not usable as RAM

Please review. Thanks!

Best regards,
Jerry Huang

-- 
2.34.1