From: Bin Meng <bmeng.cn@gmail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/8] dm: blk: part: Add UCLASS_NVME and IF_TYPE_NVME
Date: Thu, 3 Aug 2017 02:30:56 -0700 [thread overview]
Message-ID: <1501752663-25088-2-git-send-email-bmeng.cn@gmail.com> (raw)
In-Reply-To: <1501752663-25088-1-git-send-email-bmeng.cn@gmail.com>
From: Zhikang Zhang <zhikang.zhang@nxp.com>
This adds a new uclass id and block interface type for NVMe.
Signed-off-by: Zhikang Zhang <zhikang.zhang@nxp.com>
Signed-off-by: Wenbin Song <wenbin.song@nxp.com>
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Signed-off-by: Jon Nettleton <jon@solid-run.com>
---
disk/part.c | 6 +++++-
drivers/block/blk-uclass.c | 2 ++
include/blk.h | 1 +
include/dm/uclass-id.h | 1 +
4 files changed, 9 insertions(+), 1 deletion(-)
diff --git a/disk/part.c b/disk/part.c
index 491b02d..2a1929a 100644
--- a/disk/part.c
+++ b/disk/part.c
@@ -132,6 +132,7 @@ void dev_print (struct blk_desc *dev_desc)
case IF_TYPE_SD:
case IF_TYPE_MMC:
case IF_TYPE_USB:
+ case IF_TYPE_NVME:
printf ("Vendor: %s Rev: %s Prod: %s\n",
dev_desc->vendor,
dev_desc->revision,
@@ -263,7 +264,10 @@ static void print_part_header(const char *type, struct blk_desc *dev_desc)
puts ("MMC");
break;
case IF_TYPE_HOST:
- puts("HOST");
+ puts ("HOST");
+ break;
+ case IF_TYPE_NVME:
+ puts ("NVMe");
break;
default:
puts ("UNKNOWN");
diff --git a/drivers/block/blk-uclass.c b/drivers/block/blk-uclass.c
index 23f131b..a3737ba 100644
--- a/drivers/block/blk-uclass.c
+++ b/drivers/block/blk-uclass.c
@@ -22,6 +22,7 @@ static const char *if_typename_str[IF_TYPE_COUNT] = {
[IF_TYPE_SATA] = "sata",
[IF_TYPE_HOST] = "host",
[IF_TYPE_SYSTEMACE] = "ace",
+ [IF_TYPE_NVME] = "nvme",
};
static enum uclass_id if_type_uclass_id[IF_TYPE_COUNT] = {
@@ -34,6 +35,7 @@ static enum uclass_id if_type_uclass_id[IF_TYPE_COUNT] = {
[IF_TYPE_SD] = UCLASS_INVALID,
[IF_TYPE_SATA] = UCLASS_AHCI,
[IF_TYPE_HOST] = UCLASS_ROOT,
+ [IF_TYPE_NVME] = UCLASS_NVME,
[IF_TYPE_SYSTEMACE] = UCLASS_INVALID,
};
diff --git a/include/blk.h b/include/blk.h
index 1e6239a..61b5628 100644
--- a/include/blk.h
+++ b/include/blk.h
@@ -31,6 +31,7 @@ enum if_type {
IF_TYPE_SATA,
IF_TYPE_HOST,
IF_TYPE_SYSTEMACE,
+ IF_TYPE_NVME,
IF_TYPE_COUNT, /* Number of interface types */
};
diff --git a/include/dm/uclass-id.h b/include/dm/uclass-id.h
index 2e6498b..1a50199 100644
--- a/include/dm/uclass-id.h
+++ b/include/dm/uclass-id.h
@@ -52,6 +52,7 @@ enum uclass_id {
UCLASS_MOD_EXP, /* RSA Mod Exp device */
UCLASS_MTD, /* Memory Technology Device (MTD) device */
UCLASS_NORTHBRIDGE, /* Intel Northbridge / SDRAM controller */
+ UCLASS_NVME, /* NVM Express device */
UCLASS_PANEL, /* Display panel, such as an LCD */
UCLASS_PANEL_BACKLIGHT, /* Backlight controller for panel */
UCLASS_PCH, /* x86 platform controller hub */
--
2.9.2
next prev parent reply other threads:[~2017-08-03 9:30 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-08-03 9:30 [U-Boot] [PATCH 0/8] nvme: Add NVM Express driver support Bin Meng
2017-08-03 9:30 ` Bin Meng [this message]
2017-08-10 1:30 ` [U-Boot] [PATCH 1/8] dm: blk: part: Add UCLASS_NVME and IF_TYPE_NVME Tom Rini
2017-08-14 0:07 ` [U-Boot] [U-Boot, " Tom Rini
2017-08-03 9:30 ` [U-Boot] [PATCH 2/8] nvme: Add NVM Express driver support Bin Meng
2017-08-10 1:30 ` Tom Rini
2017-08-14 0:07 ` [U-Boot] [U-Boot,2/8] " Tom Rini
2017-08-03 9:30 ` [U-Boot] [PATCH 3/8] nvme: Add show routine to print detailed information Bin Meng
2017-08-10 1:31 ` Tom Rini
2017-08-14 0:07 ` [U-Boot] [U-Boot, " Tom Rini
2017-08-03 9:30 ` [U-Boot] [PATCH 4/8] nvme: Add nvme commands Bin Meng
2017-08-10 1:31 ` Tom Rini
2017-08-14 0:08 ` [U-Boot] [U-Boot,4/8] " Tom Rini
2017-08-03 9:31 ` [U-Boot] [PATCH 5/8] nvme: Detect devices that are class Storage Express Bin Meng
2017-08-10 1:31 ` Tom Rini
2017-08-14 0:08 ` [U-Boot] [U-Boot, " Tom Rini
2017-08-03 9:31 ` [U-Boot] [PATCH 6/8] nvme: Fix number of blocks detection Bin Meng
2017-08-10 1:31 ` Tom Rini
2017-08-14 0:08 ` [U-Boot] [U-Boot,6/8] " Tom Rini
2017-08-03 9:31 ` [U-Boot] [PATCH 7/8] nvme: Handle zero Maximum Data Transfer Size (MDTS) Bin Meng
2017-08-10 1:31 ` Tom Rini
2017-08-14 0:08 ` [U-Boot] [U-Boot, " Tom Rini
2017-08-03 9:31 ` [U-Boot] [PATCH 8/8] x86: qemu: Enable NVMe driver Bin Meng
2017-08-10 1:31 ` Tom Rini
2017-08-14 0:08 ` [U-Boot] [U-Boot,8/8] " Tom Rini
2017-08-09 22:40 ` [U-Boot] [PATCH 0/8] nvme: Add NVM Express driver support Bin Meng
2017-08-10 1:31 ` Tom Rini
2017-08-10 1:49 ` Bin Meng
2017-08-10 1:56 ` Tom Rini
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1501752663-25088-2-git-send-email-bmeng.cn@gmail.com \
--to=bmeng.cn@gmail.com \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox