diff options
author | Jayamohan Kallickal <jayamohan.kallickal@emulex.com> | 2014-05-05 21:41:27 -0400 |
---|---|---|
committer | Christoph Hellwig <hch@lst.de> | 2014-05-28 12:13:15 -0400 |
commit | b3c202dc57607174468b3ea6b4220b7ca5643f05 (patch) | |
tree | 243066fdd53267107236aed2387edf01e24ef91f /drivers/scsi/be2iscsi/be_iscsi.c | |
parent | 73af08e11c6638e2abd6b1fa13cdab58c2bbdbf8 (diff) |
be2iscsi: Fix TCP parameters while connection offloading.
SKH-R adapter, TCP Window Size/Scale parameters are passed
in TCP Connection Offload Mbx Command.
Signed-off-by: Minh Tran <minhduc.tran@emulex.com>
Signed-off-by: John Soni Jose <sony.john-n@emulex.com>
Signed-off-by: Jayamohan Kallickal <jayamohan.kallickal@emulex.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'drivers/scsi/be2iscsi/be_iscsi.c')
-rw-r--r-- | drivers/scsi/be2iscsi/be_iscsi.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/drivers/scsi/be2iscsi/be_iscsi.c b/drivers/scsi/be2iscsi/be_iscsi.c index a3df43324c98..fd284ff36ecf 100644 --- a/drivers/scsi/be2iscsi/be_iscsi.c +++ b/drivers/scsi/be2iscsi/be_iscsi.c | |||
@@ -1106,7 +1106,7 @@ static int beiscsi_open_conn(struct iscsi_endpoint *ep, | |||
1106 | struct beiscsi_hba *phba = beiscsi_ep->phba; | 1106 | struct beiscsi_hba *phba = beiscsi_ep->phba; |
1107 | struct tcp_connect_and_offload_out *ptcpcnct_out; | 1107 | struct tcp_connect_and_offload_out *ptcpcnct_out; |
1108 | struct be_dma_mem nonemb_cmd; | 1108 | struct be_dma_mem nonemb_cmd; |
1109 | unsigned int tag; | 1109 | unsigned int tag, req_memsize; |
1110 | int ret = -ENOMEM; | 1110 | int ret = -ENOMEM; |
1111 | 1111 | ||
1112 | beiscsi_log(phba, KERN_INFO, BEISCSI_LOG_CONFIG, | 1112 | beiscsi_log(phba, KERN_INFO, BEISCSI_LOG_CONFIG, |
@@ -1127,8 +1127,14 @@ static int beiscsi_open_conn(struct iscsi_endpoint *ep, | |||
1127 | (beiscsi_ep->ep_cid)] = ep; | 1127 | (beiscsi_ep->ep_cid)] = ep; |
1128 | 1128 | ||
1129 | beiscsi_ep->cid_vld = 0; | 1129 | beiscsi_ep->cid_vld = 0; |
1130 | |||
1131 | if (is_chip_be2_be3r(phba)) | ||
1132 | req_memsize = sizeof(struct tcp_connect_and_offload_in); | ||
1133 | else | ||
1134 | req_memsize = sizeof(struct tcp_connect_and_offload_in_v1); | ||
1135 | |||
1130 | nonemb_cmd.va = pci_alloc_consistent(phba->ctrl.pdev, | 1136 | nonemb_cmd.va = pci_alloc_consistent(phba->ctrl.pdev, |
1131 | sizeof(struct tcp_connect_and_offload_in), | 1137 | req_memsize, |
1132 | &nonemb_cmd.dma); | 1138 | &nonemb_cmd.dma); |
1133 | if (nonemb_cmd.va == NULL) { | 1139 | if (nonemb_cmd.va == NULL) { |
1134 | 1140 | ||
@@ -1139,7 +1145,7 @@ static int beiscsi_open_conn(struct iscsi_endpoint *ep, | |||
1139 | beiscsi_free_ep(beiscsi_ep); | 1145 | beiscsi_free_ep(beiscsi_ep); |
1140 | return -ENOMEM; | 1146 | return -ENOMEM; |
1141 | } | 1147 | } |
1142 | nonemb_cmd.size = sizeof(struct tcp_connect_and_offload_in); | 1148 | nonemb_cmd.size = req_memsize; |
1143 | memset(nonemb_cmd.va, 0, nonemb_cmd.size); | 1149 | memset(nonemb_cmd.va, 0, nonemb_cmd.size); |
1144 | tag = mgmt_open_connection(phba, dst_addr, beiscsi_ep, &nonemb_cmd); | 1150 | tag = mgmt_open_connection(phba, dst_addr, beiscsi_ep, &nonemb_cmd); |
1145 | if (tag <= 0) { | 1151 | if (tag <= 0) { |