summaryrefslogtreecommitdiffstats
path: root/nvme.h
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2021-11-20 07:04:31 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2021-11-20 07:04:31 +0000
commit727de41af97db70722cfc1898ebb027b9e339969 (patch)
tree990f71500c8feeb9f437c5021522ebaff3915141 /nvme.h
parentAdding upstream version 1.15. (diff)
downloadnvme-cli-727de41af97db70722cfc1898ebb027b9e339969.tar.xz
nvme-cli-727de41af97db70722cfc1898ebb027b9e339969.zip
Adding upstream version 1.16.upstream/1.16
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'nvme.h')
-rw-r--r--nvme.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/nvme.h b/nvme.h
index 5150c8d..d6f5aa3 100644
--- a/nvme.h
+++ b/nvme.h
@@ -30,9 +30,9 @@
#define json_free_object(o) json_object_put(o)
#define json_free_array(a) json_object_put(a)
#define json_object_add_value_uint(o, k, v) \
- json_object_object_add(o, k, json_object_new_int(v))
+ json_object_object_add(o, k, json_object_new_uint64(v))
#define json_object_add_value_int(o, k, v) \
- json_object_object_add(o, k, json_object_new_int(v))
+ json_object_object_add(o, k, json_object_new_int64(v))
#define json_object_add_value_float(o, k, v) \
json_object_object_add(o, k, json_object_new_double(v))
#define json_object_add_value_string(o, k, v) \
@@ -43,6 +43,8 @@
json_object_object_add(o, k, v)
#define json_array_add_value_object(o, k) \
json_object_array_add(o, k)
+#define json_array_add_value_string(o, v) \
+ json_object_array_add(o, json_object_new_string(v))
#define json_print_object(o, u) \
printf("%s", json_object_to_json_string_ext(o, JSON_C_TO_STRING_PRETTY))
#else
@@ -152,5 +154,5 @@ static inline void nvme_strip_spaces(char *s, int l)
while (l && (s[l] == '\0' || s[l] == ' '))
s[l--] = '\0';
}
-
+__u16 get_feat_buf_len(unsigned short feature);
#endif /* _NVME_H */