diff --git a/lib/iscsi/iscsi.h b/lib/iscsi/iscsi.h index f56cf6c4a..b9301df0f 100644 --- a/lib/iscsi/iscsi.h +++ b/lib/iscsi/iscsi.h @@ -82,12 +82,6 @@ */ #define SPDK_ISCSI_MAX_RECV_DATA_SEGMENT_LENGTH 65536 -/* - * SPDK iSCSI target will only send a maximum of SPDK_BDEV_LARGE_BUF_MAX_SIZE data segments, even if the - * connection can support more. - */ -#define SPDK_ISCSI_MAX_SEND_DATA_SEGMENT_LENGTH SPDK_BDEV_LARGE_BUF_MAX_SIZE - /* * Defines maximum number of data out buffers each connection can have in * use at any given time. diff --git a/lib/iscsi/param.c b/lib/iscsi/param.c index 7c67d2c2e..b90cf879c 100644 --- a/lib/iscsi/param.c +++ b/lib/iscsi/param.c @@ -1128,8 +1128,8 @@ spdk_iscsi_copy_param2var(struct spdk_iscsi_conn *conn) SPDK_DEBUGLOG(SPDK_LOG_ISCSI, "copy MaxRecvDataSegmentLength=%s\n", val); conn->MaxRecvDataSegmentLength = (int)strtol(val, NULL, 10); - if (conn->MaxRecvDataSegmentLength > SPDK_ISCSI_MAX_SEND_DATA_SEGMENT_LENGTH) { - conn->MaxRecvDataSegmentLength = SPDK_ISCSI_MAX_SEND_DATA_SEGMENT_LENGTH; + if (conn->MaxRecvDataSegmentLength > SPDK_BDEV_LARGE_BUF_MAX_SIZE) { + conn->MaxRecvDataSegmentLength = SPDK_BDEV_LARGE_BUF_MAX_SIZE; } val = spdk_iscsi_param_get_val(conn->params, "HeaderDigest");