]> www.infradead.org Git - users/sagi/nvme-cli.git/commit
nvme-print-json: include vs for identify namespace
authorhris Patterson <cpatterson@microsoft.com>
Mon, 11 Dec 2023 08:39:23 +0000 (09:39 +0100)
committerDaniel Wagner <wagi@monom.org>
Tue, 19 Dec 2023 09:07:52 +0000 (10:07 +0100)
commit613056bf9d6a7dc280f2d252a2966f78fd810ac4
tree34b88b9da98765e61b6a5890b78d504e055c5a6d
parent3bf49358274be21a8cb3717794de0c93bf179bd8
nvme-print-json: include vs for identify namespace

While the spec may allow for arbitrary use of vendor-specific
data, some implementations are simply strings.  JSON will
encode the string, allowing for safe use of control characters.

The only requirement is that the there be a null-byte in the
vendor-specific field terminating the string.  Data beyond the
null-byte will be ignored.

Signed-off-by: Chris Patterson <cpatterson@microsoft.com>
[dwagner: use d_json instead obj_add_str]
Signed-off-by: Daniel Wagner <dwagner@suse.de>
nvme-print-json.c