qemu/docs/system/devices
Stephen Bates 23a4b3ebc7 hw/nvme: Add OCP SMART / Health Information Extended Log Page
The Open Compute Project [1] includes a Datacenter NVMe
SSD Specification [2]. The most recent version of this specification
(as of November 2024) is 2.6.1. This specification layers on top of
the NVM Express specifications [3] to provide additional
functionality. A key part of of this is the 512 Byte OCP SMART / Health
Information Extended log page that is defined in Section 4.8.6 of the
specification.

We add a controller argument (ocp) that toggles on/off the SMART log
extended structure.  To accommodate different vendor specific specifications
like OCP, we add a multiplexing function (nvme_vendor_specific_log) which
will route to the different log functions based on arguments and log ids.
We only return the OCP extended SMART log when the command is 0xC0 and ocp
has been turned on in the nvme argumants.

Though we add the whole nvme SMART log extended structure, we only populate
the physical_media_units_{read,written}, log_page_version and
log_page_uuid.

This patch is based on work done by Joel but has been modified enough
that he requested a co-developed-by tag rather than a signed-off-by.

[1]: https://www.opencompute.org/
[2]: https://www.opencompute.org/documents/datacenter-nvme-ssd-specification-v2-6-1-pdf
[3]: https://nvmexpress.org/specifications/

Signed-off-by: Stephen Bates <sbates@raithlin.com>
Co-developed-by: Joel Granados <j.granados@samsung.com>
Reviewed-by: Klaus Jensen <k.jensen@samsung.com>
Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
2025-02-25 12:27:21 +01:00
..
can.rst docs: use "buses" rather than "busses" 2024-01-05 22:28:54 +03:00
canokey.rst docs: correct typos 2024-02-20 22:20:48 +03:00
ccid.rst docs/ccid: convert to restructuredText 2022-04-20 09:25:10 +02:00
cxl.rst docs/cxl: fix some typos 2024-06-30 19:51:44 +03:00
igb.rst docs/system/devices/igb: Note igb is tested for DPDK 2023-05-23 15:20:15 +08:00
ivshmem-flat.rst hw/misc/ivshmem-flat: Add ivshmem-flat device 2024-12-31 21:21:27 +01:00
ivshmem.rst docs/specs/ivshmem-spec: Convert to rST 2023-11-02 12:52:06 +00:00
keyboard.rst escc: emulate dip switch language layout settings on SUN keyboard 2023-06-28 10:54:25 +01:00
net.rst docs: Remove unused weirdly-named cross-reference targets 2023-05-12 15:43:38 +01:00
nvme.rst hw/nvme: Add OCP SMART / Health Information Extended Log Page 2025-02-25 12:27:21 +01:00
usb-u2f.rst docs: Convert u2f.txt to rST 2023-05-18 11:40:32 +01:00
usb.rst docs/system/devices/usb: Replace the non-existing "qemu" binary 2024-06-30 19:51:44 +03:00
vhost-user-input.rst docs/system: Add vhost-user-input documentation 2024-02-14 06:09:32 -05:00
vhost-user-rng.rst docs/system: add a basic enumeration of vhost-user devices 2024-02-14 06:09:32 -05:00
vhost-user.rst hostmem: add a new memory backend based on POSIX shm_open() 2024-07-03 18:14:06 -04:00
virtio-gpu.rst virtio-gpu: Support Venus context 2024-10-28 16:56:36 +00:00
virtio-pmem.rst docs: collect the disparate device emulation docs into one section 2021-07-23 17:22:16 +01:00
virtio-snd.rst docs/system: add basic virtio-snd documentation 2023-11-07 03:39:10 -05:00