target/spdknvmf: Add max_queue_depth configuration parameter

User can specify max_queue_depth parameter used in spdk
when creating rdma transport.

Change-Id: I5dc6024907e5fdb0ff0e852eed8e80792d363697
Signed-off-by: Pawel Kaminski <pawelx.kaminski@intel.com>
This commit is contained in:
Pawel Kaminski 2019-07-22 14:58:01 +00:00
parent 1ffcbedc31
commit aacd4ae790
2 changed files with 11 additions and 0 deletions

View File

@ -34,6 +34,10 @@ spdk_opts = [
cfg.StrOpt('spdk_rpc_password',
help='The NVMe target remote configuration password.',
secret=True),
cfg.IntOpt('spdk_max_queue_depth',
default=64,
min=1, max=128,
help='Queue depth for rdma transport.'),
]
CONF = cfg.CONF
CONF.register_opts(spdk_opts, group=configuration.SHARED_CONF_GROUP)
@ -58,6 +62,8 @@ class SpdkNvmf(nvmeof.NVMeOF):
try:
params = {
'trtype': 'rdma',
'max_queue_depth':
self.configuration.spdk_max_queue_depth
}
self._rpc_call('nvmf_create_transport', params)
except Exception:

View File

@ -0,0 +1,5 @@
---
upgrade:
- |
New config option spdk_max_queue_depth is added for SPDK NVMe-oF target.
It allows users to specify max queu depth.