summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/linux/nvme.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/nvme.h b/include/linux/nvme.h
index f2344aa923e8..acb484935603 100644
--- a/include/linux/nvme.h
+++ b/include/linux/nvme.h
@@ -1085,4 +1085,8 @@ struct nvme_completion {
#define NVME_VS(major, minor, tertiary) \
(((major) << 16) | ((minor) << 8) | (tertiary))
+#define NVME_MAJOR(ver) ((ver) >> 16)
+#define NVME_MINOR(ver) (((ver) >> 8) & 0xff)
+#define NVME_TERTIARY(ver) ((ver) & 0xff)
+
#endif /* _LINUX_NVME_H */