Spdk/lib
Jim Harris 5354d0c63f nvme: reset mapping_length correctly for contig SGL
spdk_vtophys() takes a mapping_length parameter, so
it can return the length for which the returned
virtual address is valid.

But spdk_vtophys() will only return the max
between the valid length and the input mapping_length
parameter.

So the nvme SGL building code for contiguous buffers
was broken, since it would only set the mapping_length
once, before the loop started.  Worst case, if a buffer
started just before (maybe 256 bytes) before a huge page
boundary, each time through the loop we would create
a new SGL for only 256 bytes at a time, very quickly
running out of SGL entries for a large buffer.

Fixes #1852.

Signed-off-by: Jim Harris <james.r.harris@intel.com>
Change-Id: Ib1000d8b130e8e4bfeacccd6e60f8109428dfc1e

Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/7659
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: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Aleksey Marchuk <alexeymar@mellanox.com>
2021-04-29 07:09:43 +00:00
..
accel accel_engine: fix the bug while computing chained crc32c via hardware engine. 2021-04-19 21:27:21 +00:00
bdev bdev/zone: add support for get num zones 2021-04-26 16:16:42 +00:00
blob lib/blob: do not write extent pages during md sync for thin blobs 2021-04-23 07:52:25 +00:00
blobfs so_ver: increase all major versions 2021-02-05 14:43:47 +00:00
conf so_ver: increase all major versions 2021-02-05 14:43:47 +00:00
env_dpdk env_dpdk: save hotplug timeout timestamps separate from rte_devargs 2021-04-23 08:16:24 +00:00
env_ocf lib/thead: print error log when create mempool or ring failed 2020-11-05 09:41:06 +00:00
event reactor: call callback if no need to set intr 2021-04-26 06:58:36 +00:00
ftl so_ver: increase all major versions 2021-02-05 14:43:47 +00:00
idxd idxd: Update the definition of register according to the new spec. 2021-04-15 04:35:09 +00:00
ioat so_ver: increase all major versions 2021-02-05 14:43:47 +00:00
iscsi lib/iscsi: Merge multiple Data-OUT PDUs up to 64KB in a sequence 2021-04-19 12:47:40 +00:00
json so_ver: increase all major versions 2021-02-05 14:43:47 +00:00
jsonrpc so_ver: increase all major versions 2021-02-05 14:43:47 +00:00
log so_ver: increase all major versions 2021-02-05 14:43:47 +00:00
lvol so_ver: increase all major versions 2021-02-05 14:43:47 +00:00
nbd nbd: add set interrupt mode to poller 2021-04-23 18:09:54 +00:00
net net: deprecate library 2021-04-26 06:55:03 +00:00
notify so_ver: increase all major versions 2021-02-05 14:43:47 +00:00
nvme nvme: reset mapping_length correctly for contig SGL 2021-04-29 07:09:43 +00:00
nvmf nvmf:Return cdw0 over tcp transport for retrieve cmd 2021-04-26 14:22:38 +00:00
rdma include: remove util.h include from queue_extras.h 2021-04-14 07:25:21 +00:00
reduce so_ver: increase all major versions 2021-02-05 14:43:47 +00:00
rocksdb build: use DEPDIRS variables to build SPDK_LIB_LIST 2020-12-18 09:40:01 +00:00
rpc so_ver: increase all major versions 2021-02-05 14:43:47 +00:00
scsi scsi: return scsi error status for invalid SCSI CDB 2021-04-15 20:25:28 +00:00
sock sock: Add new params to configure zcopy for server, client sockets 2021-04-27 08:13:32 +00:00
thread thread: do not ignore read() return 2021-04-26 06:55:48 +00:00
trace so_ver: increase all major versions 2021-02-05 14:43:47 +00:00
ut_mock so_ver: increase all major versions 2021-02-05 14:43:47 +00:00
util lib/util/math.c: improve portability 2021-02-10 08:44:01 +00:00
vfio_user lib/vfio_user: Fix compiling warning of non-debug warning. 2021-04-19 12:49:25 +00:00
vhost vhost-blk: add set interrupt mode to poller 2021-04-23 18:09:54 +00:00
virtio virtio_blk: add hotplug support 2021-04-16 19:21:13 +00:00
vmd so_ver: increase all major versions 2021-02-05 14:43:47 +00:00
Makefile NVMe/vfio-user: add initial version vfio-user transport to NVMe driver 2021-01-21 05:00:18 +00:00