1f433c4c | 02-Jul-2021 |
Jacek Kalwas <jacek.kalwas@intel.com> |
bdev/nvme: prefer NGUID over UUID if supported
NVMe specification defines namespace identification descriptors i.e. EUI64, NGUID, UUID.
BDEV abstracts NVMe specific details that is why only UUID is
bdev/nvme: prefer NGUID over UUID if supported
NVMe specification defines namespace identification descriptors i.e. EUI64, NGUID, UUID.
BDEV abstracts NVMe specific details that is why only UUID is exposed, however if NGUID is supported it is prefered to identify namespace with NGUID over UUID.
If NGUID is not supported by NVMe Controller then fallback to UUID.
Signed-off-by: Jacek Kalwas <jacek.kalwas@intel.com> Change-Id: If51889a3664c0daa7cbe983048231793e3c502e0 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/8627 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Community-CI: Mellanox Build Bot Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
show more ...
|
7ea4a778 | 13-Jun-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
bdev/nvme: Consolidate populate_namespace_cb() calls for error cases into connect_attach_cb()
Consolidate populate_namespaces_cb() calls for error cases into connect_attach_cb(). Then remove ctx pa
bdev/nvme: Consolidate populate_namespace_cb() calls for error cases into connect_attach_cb()
Consolidate populate_namespaces_cb() calls for error cases into connect_attach_cb(). Then remove ctx parameter from bdev_nvme_add_secondary_trid() because it is not necessary now.
The next patch will inline _nvme_bdev_ctrlr_create() into nvme_bdev_ctrlr_create().
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: Ia94f456df160c1cc874acac4c70aad27102cb0b6 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/8314 Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
show more ...
|
ef7738b3 | 14-May-2021 |
Changpeng Liu <changpeng.liu@intel.com> |
bdev/nvme: enable write zeroes split support in bdev layer
Change-Id: I4d54ac4b6aeaf1f1103c3ccb955da87334ce59f2 Signed-off-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-on: https://review.spd
bdev/nvme: enable write zeroes split support in bdev layer
Change-Id: I4d54ac4b6aeaf1f1103c3ccb955da87334ce59f2 Signed-off-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7876 Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
show more ...
|
2dd2d197 | 07-Jun-2021 |
Swapnil Ingle <swapnil.ingle@nutanix.com> |
bdev/nvme: Set bdev phys_blocklen
Set nvme bdev physical block size based value of NPWG and NAWUPF namespace field. The logic to set bdev phys_blocklen is based on how Linux nvme block driver sets i
bdev/nvme: Set bdev phys_blocklen
Set nvme bdev physical block size based value of NPWG and NAWUPF namespace field. The logic to set bdev phys_blocklen is based on how Linux nvme block driver sets it. If the underlying nvme namespace supports NPWG/NAWUPF then bdev phys_blocklen is set to min(npwg, nawupf)
Signed-off-by: Swapnil Ingle <swapnil.ingle@nutanix.com> Change-Id: I6d254a9e730dccc230b9db4d1217bf7ab2f39b6c Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/8224 Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Reviewed-by: Ziye Yang <ziye.yang@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
show more ...
|
55e4be34 | 01-Jun-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
bdev/nvme: find_io_path() returns spdk_nvme_ns pointer directly
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: I3f2b047c162c7d9cab69c273ca8ac5c2236314fa Reviewed-on: ht
bdev/nvme: find_io_path() returns spdk_nvme_ns pointer directly
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: I3f2b047c162c7d9cab69c273ca8ac5c2236314fa Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/8149 Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
show more ...
|
fdc4c13e | 31-May-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
bdev/nvme: Rename nvme_io_channel by nvme_io_path
By the next patch, nvme_io_channel will be used as an I/O channel to a single nvme_bdev. This channel is created to a single nvme_bdev_ctrlr and has
bdev/nvme: Rename nvme_io_channel by nvme_io_path
By the next patch, nvme_io_channel will be used as an I/O channel to a single nvme_bdev. This channel is created to a single nvme_bdev_ctrlr and has a corresponding I/O qpair. nvme_io_path will be a better name especially when we support multipath.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: Ic34162f3c383676c5249396a09173329fc6febce Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/8095 Reviewed-by: Ziye Yang <ziye.yang@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Reviewed-by: <dongx.yi@intel.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
show more ...
|
5863f95a | 31-May-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
bdev/nvme: Submit abort command for admin command on the current thread
Previously only a single thread could submit abort commands for admin commands and it was the thread of the corresponding cont
bdev/nvme: Submit abort command for admin command on the current thread
Previously only a single thread could submit abort commands for admin commands and it was the thread of the corresponding controller.
When we support multipath, we need to traverse the list of controllers to which the target admin command is submitted. Threads of controllers may be different.
On the other hand, the previous implementation made the I/O flow very clean, but the I/O flow will not be clean if there are many controllers and the subsystem does not have its thread.
This patch changes the policy so that any SPDK thread can submit abort commands for admin commands.
Then when multipath is supported, we will be able to traverse the list of controllers simply on the current thread to abort either I/O command or admin command.
We already are able to submit any admin command on any thread anytime including abort command. Hence this will not cause any issue.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: Ib69de33f2e84b03861c7d95ce060035bdb589e4b Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/8121 Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Community-CI: Mellanox Build Bot
show more ...
|
d4558c61 | 28-May-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
bdev/nvme: Reduce conversion between spdk_bdev_io and nvme_bdev_io
We can hold bdev_io directly in nvme_bdev_ctrlr as an outstanding reset.
We can put spdk_bdev_io_from_ctx(bio) into a parameter fo
bdev/nvme: Reduce conversion between spdk_bdev_io and nvme_bdev_io
We can hold bdev_io directly in nvme_bdev_ctrlr as an outstanding reset.
We can put spdk_bdev_io_from_ctx(bio) into a parameter for a few functions because it is used only once in a function.
Passing not spdk_bdev_io but nvme_bdev_io to bdev_nvme_verify_pi_error() remove unnecessary substitution.
This is a little more efficient and simplifies the implementation.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: If49ad9fa42abf27decf3afcd8c994f55faa3bc70 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/8094 Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
show more ...
|
924bfd06 | 20-Apr-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
bdev/nvme: Add ANA state per namespace into JSON info dump
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: Idc0e783a2a4373a4269276aab8b1d857ed73caae Reviewed-on: https:/
bdev/nvme: Add ANA state per namespace into JSON info dump
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: Idc0e783a2a4373a4269276aab8b1d857ed73caae Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7509 Reviewed-by: Paul Luse <paul.e.luse@intel.com> Reviewed-by: <dongx.yi@intel.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Reviewed-by: Monica Kenguva <monica.kenguva@intel.com> Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Community-CI: Mellanox Build Bot
show more ...
|
8c2738a8 | 16-May-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
bdev/nvme: Add UUID and EUI64 comparison to check if two namespaces are identical
Following Linux NVMe host, add UUID and EUI64 comparison to bdev_nvme_compare_ns().
Besides, previously the return
bdev/nvme: Add UUID and EUI64 comparison to check if two namespaces are identical
Following Linux NVMe host, add UUID and EUI64 comparison to bdev_nvme_compare_ns().
Besides, previously the return value of memcmp() had been used as the return value of bdev_nvme_compare_ns() and this was wrong. Fix it in this patch together.
Add unit test cases for bdev_nvme_compare_ns().
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: I069ab53e77741d6348b847d51e84a9338e2f3787 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7755 Reviewed-by: Paul Luse <paul.e.luse@intel.com> Reviewed-by: Ziye Yang <ziye.yang@intel.com> Reviewed-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-by: <dongx.yi@intel.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
show more ...
|
3faf457f | 03-May-2021 |
Jim Harris <james.r.harris@intel.com> |
bdev/nvme: do not use DSM to emulate write zeroes
We cannot rely on DSM/DEALLOCATE as a write zeroes alternative, even if DLFEAT reports that deallocated blocks will be read as all zeroes. DEALLOCA
bdev/nvme: do not use DSM to emulate write zeroes
We cannot rely on DSM/DEALLOCATE as a write zeroes alternative, even if DLFEAT reports that deallocated blocks will be read as all zeroes. DEALLOCATE is advisory, meaning that blocks may not actually be deallocated. In cases where they are not deallocated, they will not be read back later as zeroes.
QEMU 6.0 started reporting DLFEAT as returning zeroes for deallocated blocks but for some of our write zeroes tests, blocks aren't actually deallocated.
We may be able to add quirks in the future if we know that a controller reliably deallocates blocks, but for now we need to revert this completely.
Note that since bdev/nvme module now does not support write zeroes in any cases, we need to disable the write zeroes call in the unit tests.
Fixes issue #1932.
Signed-off-by: Jim Harris <james.r.harris@intel.com> Change-Id: I79f0673774b621a9ffcc46891728cc7719e34cdb Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7723 Community-CI: Broadcom CI Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
show more ...
|
476b6661 | 12-Apr-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
ut/bdev_nvme: Use attach/detach ctrlr for test_pending_reset()
This is necessary to the following patches to test reset continuation.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.co
ut/bdev_nvme: Use attach/detach ctrlr for test_pending_reset()
This is necessary to the following patches to test reset continuation.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: I20e0a6b96694eb06adadfbe8e20f73380645ea43 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7326 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Community-CI: Mellanox Build Bot
show more ...
|
f56563ad | 11-Apr-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
ut/bdev_nvme: Use const variable for string array to avoid raw number
It is more readable to use const variable rather than raw number. memset is the way to initialize variable size array.
Signed-o
ut/bdev_nvme: Use const variable for string array to avoid raw number
It is more readable to use const variable rather than raw number. memset is the way to initialize variable size array.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: I42f3f34422ea96e06a99bd6cc02e0e91349a4009 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7323 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Reviewed-by: <dongx.yi@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Community-CI: Mellanox Build Bot
show more ...
|
b96c0b27 | 10-Apr-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
ut/bdev_nvme: Populate namespaces by default when attaching ctrlr
Previously when attaching a ctrlr, all namespaces had not been populated. Hence we had to populate each namespace manually.
It is m
ut/bdev_nvme: Populate namespaces by default when attaching ctrlr
Previously when attaching a ctrlr, all namespaces had not been populated. Hence we had to populate each namespace manually.
It is more normal if all namespaces are populated when attaching the corresponding ctrlr.
This patch does such change.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: I55d9c444c492ba6e44a609eac81b1ef25a7190a8 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7313 Community-CI: Broadcom CI Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-by: <dongx.yi@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
show more ...
|
924081ce | 11-Apr-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
ut/bdev_nvme: spdk_nvme_probe_poll_async() stub processes only a ctrlr whose trid matches
Previously spdk_nvme_probe_poll_async() had processed all attaching controllers. Hence it was not easy to at
ut/bdev_nvme: spdk_nvme_probe_poll_async() stub processes only a ctrlr whose trid matches
Previously spdk_nvme_probe_poll_async() had processed all attaching controllers. Hence it was not easy to attach multiple controllers in unit tests.
Besides, add a check to exclude duplicated controllers into ut_attach_ctrlr().
If the target is any SPDK library, we should insert another patch only to do code movement, but this is a unit test file, and so it will be acceptable to include code movement in the same file.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: I9e8eba6a67b2a6d0df384214ff84aa5b0c602217 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7312 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Community-CI: Mellanox Build Bot Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
show more ...
|
67a03bc7 | 10-Apr-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
ut/bdev_nvme: spdk_nvme_detach() stub calls ut_detach_ctrlr() if ctrlr is attached by ut_attach_ctrlr()
bdev_nvme_delete() calls spdk_nvme_detach() in the end. However, previously spdk_nvme_detach()
ut/bdev_nvme: spdk_nvme_detach() stub calls ut_detach_ctrlr() if ctrlr is attached by ut_attach_ctrlr()
bdev_nvme_delete() calls spdk_nvme_detach() in the end. However, previously spdk_nvme_detach() stub did nothing and ut_detach_ctrlr() was called separately if ctrlr wass attached by ut_detach_ctrlr().
This was to differentiate the two cases, ctrlr is statically assigned or dynamically attached by ut_detach_ctrlr().
This might be a little confusing. Hence by adding a flag, attached, to ctrlr, merge ut_detach_ctrlr() into spdk_nvme_detach(), and remove ut_detach_ctrlr() calls.
Besides, change one SPDK_CU_ASSERT_FATAL to return NULL because the other cases do that and the callers for ut_attach_ctrlr() already have SPDK_CU_ASSERT_FATAL.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: I2a73f57c6031819d3ae441a6874127ff5d53fc04 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7311 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
show more ...
|
d9e3ffea | 29-Mar-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
ut/bdev_nvme: Use bdev_nvme_find_io_path() in unit tests
This will make the following change simpler and testing bdev_nvme_find_io_path() will be good.
Signed-off-by: Shuhei Matsumoto <shuhei.matsu
ut/bdev_nvme: Use bdev_nvme_find_io_path() in unit tests
This will make the following change simpler and testing bdev_nvme_find_io_path() will be good.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: Iac82bdba88e4abfa41c2ce04f10ce41a6b7dbd71 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7106 Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Paul Luse <paul.e.luse@intel.com>
show more ...
|
610dd86b | 26-Mar-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
bdev/nvme: Inline nvme_bdev_ns_to_bdev() and remove it
nvme_bdev_ns_to_bdev() was introduced because nvme_ns->bdev may be removed to support multipath. However, it is unlikely now.
Hence it is easi
bdev/nvme: Inline nvme_bdev_ns_to_bdev() and remove it
nvme_bdev_ns_to_bdev() was introduced because nvme_ns->bdev may be removed to support multipath. However, it is unlikely now.
Hence it is easier to read to stop using nvme_bdev_ns_to_bdev() and access nvme_ns->bdev directly.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: Iaf35455218761bafd03060a21110ad1c4098b1db Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7098 Community-CI: Broadcom CI Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Reviewed-by: Paul Luse <paul.e.luse@intel.com>
show more ...
|
08e2210a | 26-Mar-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
bdev/nvme: Merge callback and spdk_nvme_detach() into bdev_nvme_add_trid()
This change separates failover case more clearly, and will make the following changes simpler.
Merge spdk_nvme_detach() an
bdev/nvme: Merge callback and spdk_nvme_detach() into bdev_nvme_add_trid()
This change separates failover case more clearly, and will make the following changes simpler.
Merge spdk_nvme_detach() and populate_namespaces_cb() into bdev_nvme_add_secondary_trid(). Then change the return type of bdev_nvme_add_secondary_trid() to void and move the comment to the head of it.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: I0eb706728cf1b9ad7031eb66e11880a47e2ba767 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7044 Community-CI: Broadcom CI Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Paul Luse <paul.e.luse@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
show more ...
|
0e3de45d | 26-Mar-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
bdev/nvme: Refactor add_trid() and rename it by add_secondary_trid()
Clean up bdev_nvme_add_trid() by factoring out comparison of namespaces and comparison of trids into helper functions, bdev_nvme_
bdev/nvme: Refactor add_trid() and rename it by add_secondary_trid()
Clean up bdev_nvme_add_trid() by factoring out comparison of namespaces and comparison of trids into helper functions, bdev_nvme_compare_namespaces() and bdev_nvme_compare_trids(), respectively.
Then rename bdev_nvme_add_trid() by bdev_nvme_add_secondary_trid().
Rename is for clarification and clean-up is for the next patch. The next patch will merge spdk_nvme_detach() and populate_namespaces_cb() into the renamed bdev_nvme_secondary_trid(). Clean-up makes the next patch simpler.
One note is that checking if the type of trid is not PCIe is done by holding mutex now to prioritize clean up.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: Idc8652329dd2c721d101a724ec1a57a66c4174a7 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7094 Community-CI: Broadcom CI Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Reviewed-by: Paul Luse <paul.e.luse@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
show more ...
|
1aa25374 | 24-Mar-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
bdev/nvme: Merge populate_namespaces() and its callback into nvme_bdev_ctrlr_create()
The following changes will require nvme_bdev_ctrlr_create() to be asynchronous. As a preparation, merge nvme_ctr
bdev/nvme: Merge populate_namespaces() and its callback into nvme_bdev_ctrlr_create()
The following changes will require nvme_bdev_ctrlr_create() to be asynchronous. As a preparation, merge nvme_ctrlr_populate_namespaces() and populate_namespaces_cb() into nvme_bdev_ctrlr_create().
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: I623f927da072d746b4bd83314c0f5bcb9cc34ef0 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7043 Community-CI: Broadcom CI Community-CI: Mellanox Build Bot Reviewed-by: Paul Luse <paul.e.luse@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
show more ...
|
cb8aa8ab | 24-Mar-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
bdev/nvme: Not try freeing qpair when it is NULL, and add test scenario
The API spdk_nvme_ctrlr_free_io_qpair() returns immediately if the passed qpair is NULL, but calling spdk_nvme_ctrlr_free_io_q
bdev/nvme: Not try freeing qpair when it is NULL, and add test scenario
The API spdk_nvme_ctrlr_free_io_qpair() returns immediately if the passed qpair is NULL, but calling spdk_nvme_ctrlr_free_io_qpair() with NULL should be avoided.
This patch cleans up the code to ensure that nvme_ch->qpair is NULL if disconnected and spdk_nvme_ctrlr_free_io_qpair() is called only if nvme_ch->qpair is not NULL.
Then add a test scenario that two reset requests were submitted simultaneously and the first reset request failed and then the second reset request also failed. This verifies the refactoring done in the next patch.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: Iae461f7f826b0e1a4607a17e528c04a642242d6e Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7041 Community-CI: Broadcom CI Community-CI: Mellanox Build Bot Reviewed-by: Paul Luse <paul.e.luse@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
show more ...
|
059dcf1d | 03-Mar-2021 |
Niklas Cassel <niklas.cassel@wdc.com> |
bdev/nvme: add support for zoned namespaces
Add support for zoned namespaces in the bdev/nvme module.
Query the namespace type, and if a zoned namespace is found, set the bdev struct members needed
bdev/nvme: add support for zoned namespaces
Add support for zoned namespaces in the bdev/nvme module.
Query the namespace type, and if a zoned namespace is found, set the bdev struct members needed by the bdev_zone.h APIs.
Note that while vbdev_zone_block and bdev_ocssd have zone locks, bdev/nvme does not need any kind of zone lock, because NVMe ZNS supports append natively.
The whole point of the zone append command is that you don't need any locks, even when having multiple writers, since the drive will return back the Assigned LBA where the blocks were actually written.
If a SPDK application will utilize writes instead of zone appends, the SPDK application itself will need a per zone lock in order to make sure that there is only one outstanding write.
Adding zone locks in bdev/nvme would reduce the performance of zone appends, for no reason at all.
Signed-off-by: Niklas Cassel <niklas.cassel@wdc.com> Change-Id: Ibacdb9b6e839624aba869c9949231343db5914be Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/6911 Community-CI: Broadcom CI Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
show more ...
|
d515bf73 | 08-Mar-2021 |
Ziye Yang <ziye.yang@intel.com> |
bdev/nvme: Use the accelerated_engine
This patch really uses the accelrated engine. Currently, we only offload the crc32c caculation, but it can be extended.
Change-Id: If0e4c6a44b6e1e10e03f7eca355
bdev/nvme: Use the accelerated_engine
This patch really uses the accelrated engine. Currently, we only offload the crc32c caculation, but it can be extended.
Change-Id: If0e4c6a44b6e1e10e03f7eca355bed418d67326b Signed-off-by: Ziye Yang <ziye.yang@intel.com> Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/6760 Community-CI: Broadcom CI Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com> Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
show more ...
|
26c5cc52 | 18-Mar-2021 |
Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> |
bdev/nvme: Remove ctx parameter from _bdev_nvme_reset()
Separate bdev_nvme_reset() and _bdev_nvme_reset() by making bdev_nvme_reset() call _bdev_nvme_reset_start(), and then remove the ctx parameter
bdev/nvme: Remove ctx parameter from _bdev_nvme_reset()
Separate bdev_nvme_reset() and _bdev_nvme_reset() by making bdev_nvme_reset() call _bdev_nvme_reset_start(), and then remove the ctx parameter from _bdev_nvme_reset().
This clarifies the next patch and reduces the size of the next patch.
Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Change-Id: I76b0f2f5b83445845a313203e594dca0be150bc3 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/6949 Community-CI: Broadcom CI Community-CI: Mellanox Build Bot Tested-by: SPDK CI Jenkins <sys_sgci@intel.com> Reviewed-by: Changpeng Liu <changpeng.liu@intel.com> Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
show more ...
|