This commit is contained in:
mchristi 2010-04-16 19:23:14 +00:00
parent 7d97f77d7a
commit e6af555c4d
2 changed files with 35 additions and 14 deletions

View File

@ -1,8 +1,30 @@
diff --git a/usr/initiator.c b/usr/initiator.c diff -aurp open-iscsi-2.0-872-rc1-bnx2i/usr/be2iscsi.c open-iscsi-2.0-872-rc1-bnx2i.work/usr/be2iscsi.c
index 1c9d8b6..70c873b 100644 --- open-iscsi-2.0-872-rc1-bnx2i/usr/be2iscsi.c 2010-04-16 14:15:44.000000000 -0500
--- a/usr/initiator.c +++ open-iscsi-2.0-872-rc1-bnx2i.work/usr/be2iscsi.c 2010-04-16 14:17:00.000000000 -0500
+++ b/usr/initiator.c @@ -18,6 +18,9 @@
@@ -368,9 +368,10 @@ iscsi_copy_operational_params(iscsi_conn_t *conn)
void be2iscsi_create_conn(struct iscsi_conn *conn)
{
+ struct iscsi_session *session = conn->session;
+ conn_rec_t *conn_rec = &session->nrec.conn[conn->id];
+
if (conn->max_recv_dlength > 65536)
conn->max_recv_dlength = 65536;
@@ -30,5 +33,9 @@ void be2iscsi_create_conn(struct iscsi_c
if (conn->max_xmit_dlength > 65536)
conn->max_xmit_dlength = 65536;
+ if (!conn_rec->iscsi.MaxXmitDataSegmentLength ||
+ conn_rec->iscsi.MaxXmitDataSegmentLength > 65536)
+ conn_rec->iscsi.MaxXmitDataSegmentLength = 65536;
+
conn->session->erl = 0;
}
diff -aurp open-iscsi-2.0-872-rc1-bnx2i/usr/initiator.c open-iscsi-2.0-872-rc1-bnx2i.work/usr/initiator.c
--- open-iscsi-2.0-872-rc1-bnx2i/usr/initiator.c 2010-04-16 14:16:30.000000000 -0500
+++ open-iscsi-2.0-872-rc1-bnx2i.work/usr/initiator.c 2010-04-16 14:16:41.000000000 -0500
@@ -369,9 +369,10 @@ iscsi_copy_operational_params(iscsi_conn
/* zero indicates to use the target's value */ /* zero indicates to use the target's value */
conn->max_xmit_dlength = conn->max_xmit_dlength =
__padding(conn_rec->iscsi.MaxXmitDataSegmentLength); __padding(conn_rec->iscsi.MaxXmitDataSegmentLength);
@ -16,11 +38,10 @@ index 1c9d8b6..70c873b 100644
log_error("Invalid iscsi.MaxXmitDataSegmentLength. Must be " log_error("Invalid iscsi.MaxXmitDataSegmentLength. Must be "
"within %u and %u. Setting to %u\n", "within %u and %u. Setting to %u\n",
ISCSI_MIN_MAX_RECV_SEG_LEN, ISCSI_MIN_MAX_RECV_SEG_LEN,
diff --git a/usr/login.c b/usr/login.c diff -aurp open-iscsi-2.0-872-rc1-bnx2i/usr/login.c open-iscsi-2.0-872-rc1-bnx2i.work/usr/login.c
index 4f891de..be19b9e 100644 --- open-iscsi-2.0-872-rc1-bnx2i/usr/login.c 2010-04-16 14:16:30.000000000 -0500
--- a/usr/login.c +++ open-iscsi-2.0-872-rc1-bnx2i.work/usr/login.c 2010-04-16 14:16:41.000000000 -0500
+++ b/usr/login.c @@ -390,9 +390,14 @@ get_op_params_text_keys(iscsi_session_t
@@ -390,9 +390,14 @@ get_op_params_text_keys(iscsi_session_t *session, int cid,
if (session->type == ISCSI_SESSION_TYPE_DISCOVERY || if (session->type == ISCSI_SESSION_TYPE_DISCOVERY ||
!session->t->template->rdma) { !session->t->template->rdma) {
int tgt_max_xmit; int tgt_max_xmit;
@ -36,6 +57,3 @@ index 4f891de..be19b9e 100644
tgt_max_xmit < conn->max_xmit_dlength) tgt_max_xmit < conn->max_xmit_dlength)
conn->max_xmit_dlength = tgt_max_xmit; conn->max_xmit_dlength = tgt_max_xmit;
} }
--
1.6.6.1

View File

@ -3,7 +3,7 @@
Summary: iSCSI daemon and utility programs Summary: iSCSI daemon and utility programs
Name: iscsi-initiator-utils Name: iscsi-initiator-utils
Version: 6.2.0.872 Version: 6.2.0.872
Release: 1%{?dist} Release: 2%{?dist}
Source0: http://people.redhat.com/mchristi/iscsi/rhel6.0/source/open-iscsi-2.0-872-rc1-bnx2i.tar.gz Source0: http://people.redhat.com/mchristi/iscsi/rhel6.0/source/open-iscsi-2.0-872-rc1-bnx2i.tar.gz
Source1: iscsid.init Source1: iscsid.init
Source2: iscsidevs.init Source2: iscsidevs.init
@ -177,6 +177,9 @@ fi
%{_includedir}/libiscsi.h %{_includedir}/libiscsi.h
%changelog %changelog
* Wed Mar 31 2010 Mike Christie <mchristi@redhat.com> 6.2.0.872.2
- 578455 Fix handling of MaxXmitDataSegmentLength=0 for be2iscsi
* Wed Mar 31 2010 Mike Christie <mchristi@redhat.com> 6.2.0.872.1 * Wed Mar 31 2010 Mike Christie <mchristi@redhat.com> 6.2.0.872.1
- 578455 Fix handling of MaxXmitDataSegmentLength=0 - 578455 Fix handling of MaxXmitDataSegmentLength=0