nvme/tcp: Fix the bug when doing offloading.
For nvme/tcp connection, we use the synced manner if the qpair is not fully connected. Thus without the check, we will stuck here. And this patch fixes this issue. Change-Id: I72815bf5b4c0b31c4866bc1b9034b0e42b81d3f1 Signed-off-by: Ziye Yang <ziye.yang@intel.com> Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/8025 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> Community-CI: Mellanox Build Bot
This commit is contained in:
parent
dde419084b
commit
9776b89444
@ -444,8 +444,9 @@ pdu_data_crc32_compute(struct nvme_tcp_pdu *pdu)
|
||||
/* Data Digest */
|
||||
if (pdu->data_len > 0 && g_nvme_tcp_ddgst[pdu->hdr.common.pdu_type] &&
|
||||
tqpair->flags.host_ddgst_enable) {
|
||||
/* Only suport this limitated case for the first step */
|
||||
if (tgroup != NULL && tgroup->group.group->accel_fn_table.submit_accel_crc32c &&
|
||||
/* Only suport this limited case for the first step */
|
||||
if ((nvme_qpair_get_state(&tqpair->qpair) >= NVME_QPAIR_CONNECTED) &&
|
||||
(tgroup != NULL && tgroup->group.group->accel_fn_table.submit_accel_crc32c) &&
|
||||
spdk_likely(!pdu->dif_ctx && (pdu->data_len % SPDK_NVME_TCP_DIGEST_ALIGNMENT == 0))) {
|
||||
tgroup->group.group->accel_fn_table.submit_accel_crc32c(tgroup->group.group->ctx,
|
||||
&pdu->data_digest_crc32, pdu->data_iov,
|
||||
|
Loading…
Reference in New Issue
Block a user