diff options
author | Christof Schmitt <christof.schmitt@de.ibm.com> | 2008-10-01 06:42:20 -0400 |
---|---|---|
committer | James Bottomley <James.Bottomley@HansenPartnership.com> | 2008-10-03 13:11:54 -0400 |
commit | 0406289ed57955860a4f8d744a14f4c819260ce4 (patch) | |
tree | be91ef3d51f3108469d74c1fa36d10c914ce4c6d /drivers/s390/scsi/zfcp_fsf.c | |
parent | a1b449de5d35b9eec8981c6ea999eea263b19a0b (diff) |
[SCSI] zfcp: Simplify zfcp data structures
Reduce the size of zfcp data structures by removing unused and
redundant members. scsi_lun is only the mangled version of the
fcp_lun. So, remove the redundant field and use the fcp_lun instead.
Since the queue lock and the pci_batch indicator are only used in the
request queue, move them from the common queue struct to the adapter
struct.
Signed-off-by: Christof Schmitt <christof.schmitt@de.ibm.com>
Signed-off-by: Swen Schillig <swen@vnet.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'drivers/s390/scsi/zfcp_fsf.c')
-rw-r--r-- | drivers/s390/scsi/zfcp_fsf.c | 89 |
1 files changed, 45 insertions, 44 deletions
diff --git a/drivers/s390/scsi/zfcp_fsf.c b/drivers/s390/scsi/zfcp_fsf.c index 02a570084d88..c10b88d235d2 100644 --- a/drivers/s390/scsi/zfcp_fsf.c +++ b/drivers/s390/scsi/zfcp_fsf.c | |||
@@ -639,12 +639,14 @@ static void zfcp_fsf_exchange_port_data_handler(struct zfcp_fsf_req *req) | |||
639 | } | 639 | } |
640 | } | 640 | } |
641 | 641 | ||
642 | static int zfcp_fsf_sbal_check(struct zfcp_qdio_queue *queue) | 642 | static int zfcp_fsf_sbal_check(struct zfcp_adapter *adapter) |
643 | { | 643 | { |
644 | spin_lock_bh(&queue->lock); | 644 | struct zfcp_qdio_queue *req_q = &adapter->req_q; |
645 | if (atomic_read(&queue->count)) | 645 | |
646 | spin_lock_bh(&adapter->req_q_lock); | ||
647 | if (atomic_read(&req_q->count)) | ||
646 | return 1; | 648 | return 1; |
647 | spin_unlock_bh(&queue->lock); | 649 | spin_unlock_bh(&adapter->req_q_lock); |
648 | return 0; | 650 | return 0; |
649 | } | 651 | } |
650 | 652 | ||
@@ -659,17 +661,16 @@ static int zfcp_fsf_sbal_available(struct zfcp_adapter *adapter) | |||
659 | static int zfcp_fsf_req_sbal_get(struct zfcp_adapter *adapter) | 661 | static int zfcp_fsf_req_sbal_get(struct zfcp_adapter *adapter) |
660 | { | 662 | { |
661 | long ret; | 663 | long ret; |
662 | struct zfcp_qdio_queue *req_q = &adapter->req_q; | ||
663 | 664 | ||
664 | spin_unlock_bh(&req_q->lock); | 665 | spin_unlock_bh(&adapter->req_q_lock); |
665 | ret = wait_event_interruptible_timeout(adapter->request_wq, | 666 | ret = wait_event_interruptible_timeout(adapter->request_wq, |
666 | zfcp_fsf_sbal_check(req_q), 5 * HZ); | 667 | zfcp_fsf_sbal_check(adapter), 5 * HZ); |
667 | if (ret > 0) | 668 | if (ret > 0) |
668 | return 0; | 669 | return 0; |
669 | if (!ret) | 670 | if (!ret) |
670 | atomic_inc(&adapter->qdio_outb_full); | 671 | atomic_inc(&adapter->qdio_outb_full); |
671 | 672 | ||
672 | spin_lock_bh(&req_q->lock); | 673 | spin_lock_bh(&adapter->req_q_lock); |
673 | return -EIO; | 674 | return -EIO; |
674 | } | 675 | } |
675 | 676 | ||
@@ -811,7 +812,7 @@ int zfcp_fsf_status_read(struct zfcp_adapter *adapter) | |||
811 | struct qdio_buffer_element *sbale; | 812 | struct qdio_buffer_element *sbale; |
812 | int retval = -EIO; | 813 | int retval = -EIO; |
813 | 814 | ||
814 | spin_lock_bh(&adapter->req_q.lock); | 815 | spin_lock_bh(&adapter->req_q_lock); |
815 | if (zfcp_fsf_req_sbal_get(adapter)) | 816 | if (zfcp_fsf_req_sbal_get(adapter)) |
816 | goto out; | 817 | goto out; |
817 | 818 | ||
@@ -851,7 +852,7 @@ failed_buf: | |||
851 | zfcp_fsf_req_free(req); | 852 | zfcp_fsf_req_free(req); |
852 | zfcp_hba_dbf_event_fsf_unsol("fail", adapter, NULL); | 853 | zfcp_hba_dbf_event_fsf_unsol("fail", adapter, NULL); |
853 | out: | 854 | out: |
854 | spin_unlock_bh(&adapter->req_q.lock); | 855 | spin_unlock_bh(&adapter->req_q_lock); |
855 | return retval; | 856 | return retval; |
856 | } | 857 | } |
857 | 858 | ||
@@ -924,7 +925,7 @@ struct zfcp_fsf_req *zfcp_fsf_abort_fcp_command(unsigned long old_req_id, | |||
924 | struct qdio_buffer_element *sbale; | 925 | struct qdio_buffer_element *sbale; |
925 | struct zfcp_fsf_req *req = NULL; | 926 | struct zfcp_fsf_req *req = NULL; |
926 | 927 | ||
927 | spin_lock(&adapter->req_q.lock); | 928 | spin_lock(&adapter->req_q_lock); |
928 | if (!zfcp_fsf_sbal_available(adapter)) | 929 | if (!zfcp_fsf_sbal_available(adapter)) |
929 | goto out; | 930 | goto out; |
930 | req = zfcp_fsf_req_create(adapter, FSF_QTCB_ABORT_FCP_CMND, | 931 | req = zfcp_fsf_req_create(adapter, FSF_QTCB_ABORT_FCP_CMND, |
@@ -954,7 +955,7 @@ out_error_free: | |||
954 | zfcp_fsf_req_free(req); | 955 | zfcp_fsf_req_free(req); |
955 | req = NULL; | 956 | req = NULL; |
956 | out: | 957 | out: |
957 | spin_unlock(&adapter->req_q.lock); | 958 | spin_unlock(&adapter->req_q_lock); |
958 | return req; | 959 | return req; |
959 | } | 960 | } |
960 | 961 | ||
@@ -1043,7 +1044,7 @@ int zfcp_fsf_send_ct(struct zfcp_send_ct *ct, mempool_t *pool, | |||
1043 | struct zfcp_fsf_req *req; | 1044 | struct zfcp_fsf_req *req; |
1044 | int ret = -EIO; | 1045 | int ret = -EIO; |
1045 | 1046 | ||
1046 | spin_lock_bh(&adapter->req_q.lock); | 1047 | spin_lock_bh(&adapter->req_q_lock); |
1047 | if (zfcp_fsf_req_sbal_get(adapter)) | 1048 | if (zfcp_fsf_req_sbal_get(adapter)) |
1048 | goto out; | 1049 | goto out; |
1049 | 1050 | ||
@@ -1085,7 +1086,7 @@ failed_send: | |||
1085 | if (erp_action) | 1086 | if (erp_action) |
1086 | erp_action->fsf_req = NULL; | 1087 | erp_action->fsf_req = NULL; |
1087 | out: | 1088 | out: |
1088 | spin_unlock_bh(&adapter->req_q.lock); | 1089 | spin_unlock_bh(&adapter->req_q_lock); |
1089 | return ret; | 1090 | return ret; |
1090 | } | 1091 | } |
1091 | 1092 | ||
@@ -1155,7 +1156,7 @@ int zfcp_fsf_send_els(struct zfcp_send_els *els) | |||
1155 | ZFCP_STATUS_COMMON_UNBLOCKED))) | 1156 | ZFCP_STATUS_COMMON_UNBLOCKED))) |
1156 | return -EBUSY; | 1157 | return -EBUSY; |
1157 | 1158 | ||
1158 | spin_lock(&adapter->req_q.lock); | 1159 | spin_lock(&adapter->req_q_lock); |
1159 | if (!zfcp_fsf_sbal_available(adapter)) | 1160 | if (!zfcp_fsf_sbal_available(adapter)) |
1160 | goto out; | 1161 | goto out; |
1161 | req = zfcp_fsf_req_create(adapter, FSF_QTCB_SEND_ELS, | 1162 | req = zfcp_fsf_req_create(adapter, FSF_QTCB_SEND_ELS, |
@@ -1189,7 +1190,7 @@ int zfcp_fsf_send_els(struct zfcp_send_els *els) | |||
1189 | failed_send: | 1190 | failed_send: |
1190 | zfcp_fsf_req_free(req); | 1191 | zfcp_fsf_req_free(req); |
1191 | out: | 1192 | out: |
1192 | spin_unlock(&adapter->req_q.lock); | 1193 | spin_unlock(&adapter->req_q_lock); |
1193 | return ret; | 1194 | return ret; |
1194 | } | 1195 | } |
1195 | 1196 | ||
@@ -1200,7 +1201,7 @@ int zfcp_fsf_exchange_config_data(struct zfcp_erp_action *erp_action) | |||
1200 | struct zfcp_adapter *adapter = erp_action->adapter; | 1201 | struct zfcp_adapter *adapter = erp_action->adapter; |
1201 | int retval = -EIO; | 1202 | int retval = -EIO; |
1202 | 1203 | ||
1203 | spin_lock_bh(&adapter->req_q.lock); | 1204 | spin_lock_bh(&adapter->req_q_lock); |
1204 | if (!zfcp_fsf_sbal_available(adapter)) | 1205 | if (!zfcp_fsf_sbal_available(adapter)) |
1205 | goto out; | 1206 | goto out; |
1206 | req = zfcp_fsf_req_create(adapter, | 1207 | req = zfcp_fsf_req_create(adapter, |
@@ -1232,7 +1233,7 @@ int zfcp_fsf_exchange_config_data(struct zfcp_erp_action *erp_action) | |||
1232 | erp_action->fsf_req = NULL; | 1233 | erp_action->fsf_req = NULL; |
1233 | } | 1234 | } |
1234 | out: | 1235 | out: |
1235 | spin_unlock_bh(&adapter->req_q.lock); | 1236 | spin_unlock_bh(&adapter->req_q_lock); |
1236 | return retval; | 1237 | return retval; |
1237 | } | 1238 | } |
1238 | 1239 | ||
@@ -1243,7 +1244,7 @@ int zfcp_fsf_exchange_config_data_sync(struct zfcp_adapter *adapter, | |||
1243 | struct zfcp_fsf_req *req = NULL; | 1244 | struct zfcp_fsf_req *req = NULL; |
1244 | int retval = -EIO; | 1245 | int retval = -EIO; |
1245 | 1246 | ||
1246 | spin_lock_bh(&adapter->req_q.lock); | 1247 | spin_lock_bh(&adapter->req_q_lock); |
1247 | if (zfcp_fsf_req_sbal_get(adapter)) | 1248 | if (zfcp_fsf_req_sbal_get(adapter)) |
1248 | goto out; | 1249 | goto out; |
1249 | 1250 | ||
@@ -1271,7 +1272,7 @@ int zfcp_fsf_exchange_config_data_sync(struct zfcp_adapter *adapter, | |||
1271 | zfcp_fsf_start_timer(req, ZFCP_FSF_REQUEST_TIMEOUT); | 1272 | zfcp_fsf_start_timer(req, ZFCP_FSF_REQUEST_TIMEOUT); |
1272 | retval = zfcp_fsf_req_send(req); | 1273 | retval = zfcp_fsf_req_send(req); |
1273 | out: | 1274 | out: |
1274 | spin_unlock_bh(&adapter->req_q.lock); | 1275 | spin_unlock_bh(&adapter->req_q_lock); |
1275 | if (!retval) | 1276 | if (!retval) |
1276 | wait_event(req->completion_wq, | 1277 | wait_event(req->completion_wq, |
1277 | req->status & ZFCP_STATUS_FSFREQ_COMPLETED); | 1278 | req->status & ZFCP_STATUS_FSFREQ_COMPLETED); |
@@ -1296,7 +1297,7 @@ int zfcp_fsf_exchange_port_data(struct zfcp_erp_action *erp_action) | |||
1296 | if (!(adapter->adapter_features & FSF_FEATURE_HBAAPI_MANAGEMENT)) | 1297 | if (!(adapter->adapter_features & FSF_FEATURE_HBAAPI_MANAGEMENT)) |
1297 | return -EOPNOTSUPP; | 1298 | return -EOPNOTSUPP; |
1298 | 1299 | ||
1299 | spin_lock_bh(&adapter->req_q.lock); | 1300 | spin_lock_bh(&adapter->req_q_lock); |
1300 | if (!zfcp_fsf_sbal_available(adapter)) | 1301 | if (!zfcp_fsf_sbal_available(adapter)) |
1301 | goto out; | 1302 | goto out; |
1302 | req = zfcp_fsf_req_create(adapter, FSF_QTCB_EXCHANGE_PORT_DATA, | 1303 | req = zfcp_fsf_req_create(adapter, FSF_QTCB_EXCHANGE_PORT_DATA, |
@@ -1322,7 +1323,7 @@ int zfcp_fsf_exchange_port_data(struct zfcp_erp_action *erp_action) | |||
1322 | erp_action->fsf_req = NULL; | 1323 | erp_action->fsf_req = NULL; |
1323 | } | 1324 | } |
1324 | out: | 1325 | out: |
1325 | spin_unlock_bh(&adapter->req_q.lock); | 1326 | spin_unlock_bh(&adapter->req_q_lock); |
1326 | return retval; | 1327 | return retval; |
1327 | } | 1328 | } |
1328 | 1329 | ||
@@ -1342,7 +1343,7 @@ int zfcp_fsf_exchange_port_data_sync(struct zfcp_adapter *adapter, | |||
1342 | if (!(adapter->adapter_features & FSF_FEATURE_HBAAPI_MANAGEMENT)) | 1343 | if (!(adapter->adapter_features & FSF_FEATURE_HBAAPI_MANAGEMENT)) |
1343 | return -EOPNOTSUPP; | 1344 | return -EOPNOTSUPP; |
1344 | 1345 | ||
1345 | spin_lock_bh(&adapter->req_q.lock); | 1346 | spin_lock_bh(&adapter->req_q_lock); |
1346 | if (!zfcp_fsf_sbal_available(adapter)) | 1347 | if (!zfcp_fsf_sbal_available(adapter)) |
1347 | goto out; | 1348 | goto out; |
1348 | 1349 | ||
@@ -1364,7 +1365,7 @@ int zfcp_fsf_exchange_port_data_sync(struct zfcp_adapter *adapter, | |||
1364 | zfcp_fsf_start_timer(req, ZFCP_FSF_REQUEST_TIMEOUT); | 1365 | zfcp_fsf_start_timer(req, ZFCP_FSF_REQUEST_TIMEOUT); |
1365 | retval = zfcp_fsf_req_send(req); | 1366 | retval = zfcp_fsf_req_send(req); |
1366 | out: | 1367 | out: |
1367 | spin_unlock_bh(&adapter->req_q.lock); | 1368 | spin_unlock_bh(&adapter->req_q_lock); |
1368 | if (!retval) | 1369 | if (!retval) |
1369 | wait_event(req->completion_wq, | 1370 | wait_event(req->completion_wq, |
1370 | req->status & ZFCP_STATUS_FSFREQ_COMPLETED); | 1371 | req->status & ZFCP_STATUS_FSFREQ_COMPLETED); |
@@ -1462,7 +1463,7 @@ int zfcp_fsf_open_port(struct zfcp_erp_action *erp_action) | |||
1462 | struct zfcp_fsf_req *req; | 1463 | struct zfcp_fsf_req *req; |
1463 | int retval = -EIO; | 1464 | int retval = -EIO; |
1464 | 1465 | ||
1465 | spin_lock_bh(&adapter->req_q.lock); | 1466 | spin_lock_bh(&adapter->req_q_lock); |
1466 | if (zfcp_fsf_req_sbal_get(adapter)) | 1467 | if (zfcp_fsf_req_sbal_get(adapter)) |
1467 | goto out; | 1468 | goto out; |
1468 | 1469 | ||
@@ -1492,7 +1493,7 @@ int zfcp_fsf_open_port(struct zfcp_erp_action *erp_action) | |||
1492 | erp_action->fsf_req = NULL; | 1493 | erp_action->fsf_req = NULL; |
1493 | } | 1494 | } |
1494 | out: | 1495 | out: |
1495 | spin_unlock_bh(&adapter->req_q.lock); | 1496 | spin_unlock_bh(&adapter->req_q_lock); |
1496 | return retval; | 1497 | return retval; |
1497 | } | 1498 | } |
1498 | 1499 | ||
@@ -1530,7 +1531,7 @@ int zfcp_fsf_close_port(struct zfcp_erp_action *erp_action) | |||
1530 | struct zfcp_fsf_req *req; | 1531 | struct zfcp_fsf_req *req; |
1531 | int retval = -EIO; | 1532 | int retval = -EIO; |
1532 | 1533 | ||
1533 | spin_lock_bh(&adapter->req_q.lock); | 1534 | spin_lock_bh(&adapter->req_q_lock); |
1534 | if (zfcp_fsf_req_sbal_get(adapter)) | 1535 | if (zfcp_fsf_req_sbal_get(adapter)) |
1535 | goto out; | 1536 | goto out; |
1536 | 1537 | ||
@@ -1559,7 +1560,7 @@ int zfcp_fsf_close_port(struct zfcp_erp_action *erp_action) | |||
1559 | erp_action->fsf_req = NULL; | 1560 | erp_action->fsf_req = NULL; |
1560 | } | 1561 | } |
1561 | out: | 1562 | out: |
1562 | spin_unlock_bh(&adapter->req_q.lock); | 1563 | spin_unlock_bh(&adapter->req_q_lock); |
1563 | return retval; | 1564 | return retval; |
1564 | } | 1565 | } |
1565 | 1566 | ||
@@ -1603,7 +1604,7 @@ int zfcp_fsf_open_wka_port(struct zfcp_wka_port *wka_port) | |||
1603 | struct zfcp_fsf_req *req; | 1604 | struct zfcp_fsf_req *req; |
1604 | int retval = -EIO; | 1605 | int retval = -EIO; |
1605 | 1606 | ||
1606 | spin_lock_bh(&adapter->req_q.lock); | 1607 | spin_lock_bh(&adapter->req_q_lock); |
1607 | if (zfcp_fsf_req_sbal_get(adapter)) | 1608 | if (zfcp_fsf_req_sbal_get(adapter)) |
1608 | goto out; | 1609 | goto out; |
1609 | 1610 | ||
@@ -1629,7 +1630,7 @@ int zfcp_fsf_open_wka_port(struct zfcp_wka_port *wka_port) | |||
1629 | if (retval) | 1630 | if (retval) |
1630 | zfcp_fsf_req_free(req); | 1631 | zfcp_fsf_req_free(req); |
1631 | out: | 1632 | out: |
1632 | spin_unlock_bh(&adapter->req_q.lock); | 1633 | spin_unlock_bh(&adapter->req_q_lock); |
1633 | return retval; | 1634 | return retval; |
1634 | } | 1635 | } |
1635 | 1636 | ||
@@ -1658,7 +1659,7 @@ int zfcp_fsf_close_wka_port(struct zfcp_wka_port *wka_port) | |||
1658 | struct zfcp_fsf_req *req; | 1659 | struct zfcp_fsf_req *req; |
1659 | int retval = -EIO; | 1660 | int retval = -EIO; |
1660 | 1661 | ||
1661 | spin_lock_bh(&adapter->req_q.lock); | 1662 | spin_lock_bh(&adapter->req_q_lock); |
1662 | if (zfcp_fsf_req_sbal_get(adapter)) | 1663 | if (zfcp_fsf_req_sbal_get(adapter)) |
1663 | goto out; | 1664 | goto out; |
1664 | 1665 | ||
@@ -1683,7 +1684,7 @@ int zfcp_fsf_close_wka_port(struct zfcp_wka_port *wka_port) | |||
1683 | if (retval) | 1684 | if (retval) |
1684 | zfcp_fsf_req_free(req); | 1685 | zfcp_fsf_req_free(req); |
1685 | out: | 1686 | out: |
1686 | spin_unlock_bh(&adapter->req_q.lock); | 1687 | spin_unlock_bh(&adapter->req_q_lock); |
1687 | return retval; | 1688 | return retval; |
1688 | } | 1689 | } |
1689 | 1690 | ||
@@ -1750,7 +1751,7 @@ int zfcp_fsf_close_physical_port(struct zfcp_erp_action *erp_action) | |||
1750 | struct zfcp_fsf_req *req; | 1751 | struct zfcp_fsf_req *req; |
1751 | int retval = -EIO; | 1752 | int retval = -EIO; |
1752 | 1753 | ||
1753 | spin_lock_bh(&adapter->req_q.lock); | 1754 | spin_lock_bh(&adapter->req_q_lock); |
1754 | if (zfcp_fsf_req_sbal_get(adapter)) | 1755 | if (zfcp_fsf_req_sbal_get(adapter)) |
1755 | goto out; | 1756 | goto out; |
1756 | 1757 | ||
@@ -1781,7 +1782,7 @@ int zfcp_fsf_close_physical_port(struct zfcp_erp_action *erp_action) | |||
1781 | erp_action->fsf_req = NULL; | 1782 | erp_action->fsf_req = NULL; |
1782 | } | 1783 | } |
1783 | out: | 1784 | out: |
1784 | spin_unlock_bh(&adapter->req_q.lock); | 1785 | spin_unlock_bh(&adapter->req_q_lock); |
1785 | return retval; | 1786 | return retval; |
1786 | } | 1787 | } |
1787 | 1788 | ||
@@ -1924,7 +1925,7 @@ int zfcp_fsf_open_unit(struct zfcp_erp_action *erp_action) | |||
1924 | struct zfcp_fsf_req *req; | 1925 | struct zfcp_fsf_req *req; |
1925 | int retval = -EIO; | 1926 | int retval = -EIO; |
1926 | 1927 | ||
1927 | spin_lock_bh(&adapter->req_q.lock); | 1928 | spin_lock_bh(&adapter->req_q_lock); |
1928 | if (zfcp_fsf_req_sbal_get(adapter)) | 1929 | if (zfcp_fsf_req_sbal_get(adapter)) |
1929 | goto out; | 1930 | goto out; |
1930 | 1931 | ||
@@ -1957,7 +1958,7 @@ int zfcp_fsf_open_unit(struct zfcp_erp_action *erp_action) | |||
1957 | erp_action->fsf_req = NULL; | 1958 | erp_action->fsf_req = NULL; |
1958 | } | 1959 | } |
1959 | out: | 1960 | out: |
1960 | spin_unlock_bh(&adapter->req_q.lock); | 1961 | spin_unlock_bh(&adapter->req_q_lock); |
1961 | return retval; | 1962 | return retval; |
1962 | } | 1963 | } |
1963 | 1964 | ||
@@ -2010,7 +2011,7 @@ int zfcp_fsf_close_unit(struct zfcp_erp_action *erp_action) | |||
2010 | struct zfcp_fsf_req *req; | 2011 | struct zfcp_fsf_req *req; |
2011 | int retval = -EIO; | 2012 | int retval = -EIO; |
2012 | 2013 | ||
2013 | spin_lock_bh(&adapter->req_q.lock); | 2014 | spin_lock_bh(&adapter->req_q_lock); |
2014 | if (zfcp_fsf_req_sbal_get(adapter)) | 2015 | if (zfcp_fsf_req_sbal_get(adapter)) |
2015 | goto out; | 2016 | goto out; |
2016 | req = zfcp_fsf_req_create(adapter, FSF_QTCB_CLOSE_LUN, | 2017 | req = zfcp_fsf_req_create(adapter, FSF_QTCB_CLOSE_LUN, |
@@ -2039,7 +2040,7 @@ int zfcp_fsf_close_unit(struct zfcp_erp_action *erp_action) | |||
2039 | erp_action->fsf_req = NULL; | 2040 | erp_action->fsf_req = NULL; |
2040 | } | 2041 | } |
2041 | out: | 2042 | out: |
2042 | spin_unlock_bh(&adapter->req_q.lock); | 2043 | spin_unlock_bh(&adapter->req_q_lock); |
2043 | return retval; | 2044 | return retval; |
2044 | } | 2045 | } |
2045 | 2046 | ||
@@ -2281,7 +2282,7 @@ int zfcp_fsf_send_fcp_command_task(struct zfcp_adapter *adapter, | |||
2281 | ZFCP_STATUS_COMMON_UNBLOCKED))) | 2282 | ZFCP_STATUS_COMMON_UNBLOCKED))) |
2282 | return -EBUSY; | 2283 | return -EBUSY; |
2283 | 2284 | ||
2284 | spin_lock(&adapter->req_q.lock); | 2285 | spin_lock(&adapter->req_q_lock); |
2285 | if (!zfcp_fsf_sbal_available(adapter)) | 2286 | if (!zfcp_fsf_sbal_available(adapter)) |
2286 | goto out; | 2287 | goto out; |
2287 | req = zfcp_fsf_req_create(adapter, FSF_QTCB_FCP_CMND, req_flags, | 2288 | req = zfcp_fsf_req_create(adapter, FSF_QTCB_FCP_CMND, req_flags, |
@@ -2380,7 +2381,7 @@ failed_scsi_cmnd: | |||
2380 | zfcp_fsf_req_free(req); | 2381 | zfcp_fsf_req_free(req); |
2381 | scsi_cmnd->host_scribble = NULL; | 2382 | scsi_cmnd->host_scribble = NULL; |
2382 | out: | 2383 | out: |
2383 | spin_unlock(&adapter->req_q.lock); | 2384 | spin_unlock(&adapter->req_q_lock); |
2384 | return retval; | 2385 | return retval; |
2385 | } | 2386 | } |
2386 | 2387 | ||
@@ -2404,7 +2405,7 @@ struct zfcp_fsf_req *zfcp_fsf_send_fcp_ctm(struct zfcp_adapter *adapter, | |||
2404 | ZFCP_STATUS_COMMON_UNBLOCKED))) | 2405 | ZFCP_STATUS_COMMON_UNBLOCKED))) |
2405 | return NULL; | 2406 | return NULL; |
2406 | 2407 | ||
2407 | spin_lock(&adapter->req_q.lock); | 2408 | spin_lock(&adapter->req_q_lock); |
2408 | if (!zfcp_fsf_sbal_available(adapter)) | 2409 | if (!zfcp_fsf_sbal_available(adapter)) |
2409 | goto out; | 2410 | goto out; |
2410 | req = zfcp_fsf_req_create(adapter, FSF_QTCB_FCP_CMND, req_flags, | 2411 | req = zfcp_fsf_req_create(adapter, FSF_QTCB_FCP_CMND, req_flags, |
@@ -2437,7 +2438,7 @@ struct zfcp_fsf_req *zfcp_fsf_send_fcp_ctm(struct zfcp_adapter *adapter, | |||
2437 | zfcp_fsf_req_free(req); | 2438 | zfcp_fsf_req_free(req); |
2438 | req = NULL; | 2439 | req = NULL; |
2439 | out: | 2440 | out: |
2440 | spin_unlock(&adapter->req_q.lock); | 2441 | spin_unlock(&adapter->req_q_lock); |
2441 | return req; | 2442 | return req; |
2442 | } | 2443 | } |
2443 | 2444 | ||
@@ -2475,7 +2476,7 @@ struct zfcp_fsf_req *zfcp_fsf_control_file(struct zfcp_adapter *adapter, | |||
2475 | return ERR_PTR(-EINVAL); | 2476 | return ERR_PTR(-EINVAL); |
2476 | } | 2477 | } |
2477 | 2478 | ||
2478 | spin_lock_bh(&adapter->req_q.lock); | 2479 | spin_lock_bh(&adapter->req_q_lock); |
2479 | if (zfcp_fsf_req_sbal_get(adapter)) | 2480 | if (zfcp_fsf_req_sbal_get(adapter)) |
2480 | goto out; | 2481 | goto out; |
2481 | 2482 | ||
@@ -2505,7 +2506,7 @@ struct zfcp_fsf_req *zfcp_fsf_control_file(struct zfcp_adapter *adapter, | |||
2505 | zfcp_fsf_start_timer(req, ZFCP_FSF_REQUEST_TIMEOUT); | 2506 | zfcp_fsf_start_timer(req, ZFCP_FSF_REQUEST_TIMEOUT); |
2506 | retval = zfcp_fsf_req_send(req); | 2507 | retval = zfcp_fsf_req_send(req); |
2507 | out: | 2508 | out: |
2508 | spin_unlock_bh(&adapter->req_q.lock); | 2509 | spin_unlock_bh(&adapter->req_q_lock); |
2509 | 2510 | ||
2510 | if (!retval) { | 2511 | if (!retval) { |
2511 | wait_event(req->completion_wq, | 2512 | wait_event(req->completion_wq, |