Commit 5027579f authored by Shuhei Matsumoto's avatar Shuhei Matsumoto Committed by Jim Harris
Browse files

dif: Enable fast forward from the middle of the iovec array



Previously _iov_iter_fast_forward can fast forward only from the
start of the iovec array. This patch enables fast forward in the
middle of the iovec array.

Change-Id: I801fc46dec3c759e1d754042abe15e7100cbdc17
Signed-off-by: default avatarShuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/453734


Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: default avatarChangpeng Liu <changpeng.liu@intel.com>
Reviewed-by: default avatarJim Harris <james.r.harris@intel.com>
parent 1c468a0f
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -89,7 +89,7 @@ _dif_sgl_get_buf(struct _dif_sgl *s, void **_buf, uint32_t *_buf_len)
static void
_dif_sgl_fast_forward(struct _dif_sgl *s, uint32_t offset)
{
	s->iov_offset = offset;
	s->iov_offset += offset;
	while (s->iovcnt != 0) {
		if (s->iov_offset < s->iov->iov_len) {
			break;