diff options
author | James Bottomley <jejb@mulgrave.il.steeleye.com> | 2006-07-03 10:41:12 -0400 |
---|---|---|
committer | James Bottomley <jejb@mulgrave.il.steeleye.com> | 2006-07-03 10:41:12 -0400 |
commit | c4e00fac42f268ed0a547cdd1d12bb8399864040 (patch) | |
tree | 1a54d87be2066c49b71a03764fcb4fc7f9c68c41 /drivers/scsi/lpfc | |
parent | 29454dde27d8e340bb1987bad9aa504af7081eba (diff) | |
parent | d6b0c53723753fc0cfda63f56735b225c43e1e9a (diff) |
Merge ../scsi-misc-2.6
Conflicts:
drivers/scsi/nsp32.c
drivers/scsi/pcmcia/nsp_cs.c
Removal of randomness flag conflicts with SA_ -> IRQF_ global
replacement.
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/lpfc')
-rw-r--r-- | drivers/scsi/lpfc/lpfc.h | 1 | ||||
-rw-r--r-- | drivers/scsi/lpfc/lpfc_els.c | 6 | ||||
-rw-r--r-- | drivers/scsi/lpfc/lpfc_init.c | 5 | ||||
-rw-r--r-- | drivers/scsi/lpfc/lpfc_scsi.c | 20 |
4 files changed, 5 insertions, 27 deletions
diff --git a/drivers/scsi/lpfc/lpfc.h b/drivers/scsi/lpfc/lpfc.h index 087c44539a16..f81691fcf177 100644 --- a/drivers/scsi/lpfc/lpfc.h +++ b/drivers/scsi/lpfc/lpfc.h | |||
@@ -174,7 +174,6 @@ struct lpfc_hba { | |||
174 | dma_addr_t slim2p_mapping; | 174 | dma_addr_t slim2p_mapping; |
175 | uint16_t pci_cfg_value; | 175 | uint16_t pci_cfg_value; |
176 | 176 | ||
177 | struct semaphore hba_can_block; | ||
178 | int32_t hba_state; | 177 | int32_t hba_state; |
179 | 178 | ||
180 | #define LPFC_STATE_UNKNOWN 0 /* HBA state is unknown */ | 179 | #define LPFC_STATE_UNKNOWN 0 /* HBA state is unknown */ |
diff --git a/drivers/scsi/lpfc/lpfc_els.c b/drivers/scsi/lpfc/lpfc_els.c index 283b7d824c34..4126fd87956f 100644 --- a/drivers/scsi/lpfc/lpfc_els.c +++ b/drivers/scsi/lpfc/lpfc_els.c | |||
@@ -821,7 +821,7 @@ lpfc_issue_els_plogi(struct lpfc_hba * phba, uint32_t did, uint8_t retry) | |||
821 | pring = &psli->ring[LPFC_ELS_RING]; /* ELS ring */ | 821 | pring = &psli->ring[LPFC_ELS_RING]; /* ELS ring */ |
822 | 822 | ||
823 | cmdsize = (sizeof (uint32_t) + sizeof (struct serv_parm)); | 823 | cmdsize = (sizeof (uint32_t) + sizeof (struct serv_parm)); |
824 | elsiocb = lpfc_prep_els_iocb(phba, 1, cmdsize, retry, 0, did, | 824 | elsiocb = lpfc_prep_els_iocb(phba, 1, cmdsize, retry, NULL, did, |
825 | ELS_CMD_PLOGI); | 825 | ELS_CMD_PLOGI); |
826 | if (!elsiocb) | 826 | if (!elsiocb) |
827 | return 1; | 827 | return 1; |
@@ -2791,8 +2791,8 @@ lpfc_els_rsp_rps_acc(struct lpfc_hba * phba, LPFC_MBOXQ_t * pmb) | |||
2791 | 2791 | ||
2792 | ndlp = (struct lpfc_nodelist *) pmb->context2; | 2792 | ndlp = (struct lpfc_nodelist *) pmb->context2; |
2793 | xri = (uint16_t) ((unsigned long)(pmb->context1)); | 2793 | xri = (uint16_t) ((unsigned long)(pmb->context1)); |
2794 | pmb->context1 = 0; | 2794 | pmb->context1 = NULL; |
2795 | pmb->context2 = 0; | 2795 | pmb->context2 = NULL; |
2796 | 2796 | ||
2797 | if (mb->mbxStatus) { | 2797 | if (mb->mbxStatus) { |
2798 | mempool_free( pmb, phba->mbox_mem_pool); | 2798 | mempool_free( pmb, phba->mbox_mem_pool); |
diff --git a/drivers/scsi/lpfc/lpfc_init.c b/drivers/scsi/lpfc/lpfc_init.c index 5a28d9bf8e4d..81755a3f7c68 100644 --- a/drivers/scsi/lpfc/lpfc_init.c +++ b/drivers/scsi/lpfc/lpfc_init.c | |||
@@ -939,12 +939,12 @@ lpfc_get_hba_model_desc(struct lpfc_hba * phba, uint8_t * mdp, uint8_t * descp) | |||
939 | "10-port ", "PCIe"}; | 939 | "10-port ", "PCIe"}; |
940 | break; | 940 | break; |
941 | default: | 941 | default: |
942 | m = (typeof(m)){ 0 }; | 942 | m = (typeof(m)){ NULL }; |
943 | break; | 943 | break; |
944 | } | 944 | } |
945 | break; | 945 | break; |
946 | default: | 946 | default: |
947 | m = (typeof(m)){ 0 }; | 947 | m = (typeof(m)){ NULL }; |
948 | break; | 948 | break; |
949 | } | 949 | } |
950 | 950 | ||
@@ -1451,7 +1451,6 @@ lpfc_pci_probe_one(struct pci_dev *pdev, const struct pci_device_id *pid) | |||
1451 | goto out_put_host; | 1451 | goto out_put_host; |
1452 | 1452 | ||
1453 | host->unique_id = phba->brd_no; | 1453 | host->unique_id = phba->brd_no; |
1454 | init_MUTEX(&phba->hba_can_block); | ||
1455 | INIT_LIST_HEAD(&phba->ctrspbuflist); | 1454 | INIT_LIST_HEAD(&phba->ctrspbuflist); |
1456 | INIT_LIST_HEAD(&phba->rnidrspbuflist); | 1455 | INIT_LIST_HEAD(&phba->rnidrspbuflist); |
1457 | INIT_LIST_HEAD(&phba->freebufList); | 1456 | INIT_LIST_HEAD(&phba->freebufList); |
diff --git a/drivers/scsi/lpfc/lpfc_scsi.c b/drivers/scsi/lpfc/lpfc_scsi.c index 7dc4c2e6bed2..aea1ee472f3d 100644 --- a/drivers/scsi/lpfc/lpfc_scsi.c +++ b/drivers/scsi/lpfc/lpfc_scsi.c | |||
@@ -41,20 +41,6 @@ | |||
41 | #define LPFC_ABORT_WAIT 2 | 41 | #define LPFC_ABORT_WAIT 2 |
42 | 42 | ||
43 | 43 | ||
44 | static inline void | ||
45 | lpfc_block_requests(struct lpfc_hba * phba) | ||
46 | { | ||
47 | down(&phba->hba_can_block); | ||
48 | scsi_block_requests(phba->host); | ||
49 | } | ||
50 | |||
51 | static inline void | ||
52 | lpfc_unblock_requests(struct lpfc_hba * phba) | ||
53 | { | ||
54 | scsi_unblock_requests(phba->host); | ||
55 | up(&phba->hba_can_block); | ||
56 | } | ||
57 | |||
58 | /* | 44 | /* |
59 | * This routine allocates a scsi buffer, which contains all the necessary | 45 | * This routine allocates a scsi buffer, which contains all the necessary |
60 | * information needed to initiate a SCSI I/O. The non-DMAable buffer region | 46 | * information needed to initiate a SCSI I/O. The non-DMAable buffer region |
@@ -859,7 +845,6 @@ lpfc_abort_handler(struct scsi_cmnd *cmnd) | |||
859 | unsigned int loop_count = 0; | 845 | unsigned int loop_count = 0; |
860 | int ret = SUCCESS; | 846 | int ret = SUCCESS; |
861 | 847 | ||
862 | lpfc_block_requests(phba); | ||
863 | spin_lock_irq(shost->host_lock); | 848 | spin_lock_irq(shost->host_lock); |
864 | 849 | ||
865 | lpfc_cmd = (struct lpfc_scsi_buf *)cmnd->host_scribble; | 850 | lpfc_cmd = (struct lpfc_scsi_buf *)cmnd->host_scribble; |
@@ -945,7 +930,6 @@ lpfc_abort_handler(struct scsi_cmnd *cmnd) | |||
945 | cmnd->device->lun, cmnd->serial_number); | 930 | cmnd->device->lun, cmnd->serial_number); |
946 | 931 | ||
947 | spin_unlock_irq(shost->host_lock); | 932 | spin_unlock_irq(shost->host_lock); |
948 | lpfc_unblock_requests(phba); | ||
949 | 933 | ||
950 | return ret; | 934 | return ret; |
951 | } | 935 | } |
@@ -963,7 +947,6 @@ lpfc_reset_lun_handler(struct scsi_cmnd *cmnd) | |||
963 | int ret = FAILED; | 947 | int ret = FAILED; |
964 | int cnt, loopcnt; | 948 | int cnt, loopcnt; |
965 | 949 | ||
966 | lpfc_block_requests(phba); | ||
967 | spin_lock_irq(shost->host_lock); | 950 | spin_lock_irq(shost->host_lock); |
968 | /* | 951 | /* |
969 | * If target is not in a MAPPED state, delay the reset until | 952 | * If target is not in a MAPPED state, delay the reset until |
@@ -1065,7 +1048,6 @@ out_free_scsi_buf: | |||
1065 | 1048 | ||
1066 | out: | 1049 | out: |
1067 | spin_unlock_irq(shost->host_lock); | 1050 | spin_unlock_irq(shost->host_lock); |
1068 | lpfc_unblock_requests(phba); | ||
1069 | return ret; | 1051 | return ret; |
1070 | } | 1052 | } |
1071 | 1053 | ||
@@ -1080,7 +1062,6 @@ lpfc_reset_bus_handler(struct scsi_cmnd *cmnd) | |||
1080 | int cnt, loopcnt; | 1062 | int cnt, loopcnt; |
1081 | struct lpfc_scsi_buf * lpfc_cmd; | 1063 | struct lpfc_scsi_buf * lpfc_cmd; |
1082 | 1064 | ||
1083 | lpfc_block_requests(phba); | ||
1084 | spin_lock_irq(shost->host_lock); | 1065 | spin_lock_irq(shost->host_lock); |
1085 | 1066 | ||
1086 | lpfc_cmd = lpfc_get_scsi_buf(phba); | 1067 | lpfc_cmd = lpfc_get_scsi_buf(phba); |
@@ -1163,7 +1144,6 @@ lpfc_reset_bus_handler(struct scsi_cmnd *cmnd) | |||
1163 | phba->brd_no, ret); | 1144 | phba->brd_no, ret); |
1164 | out: | 1145 | out: |
1165 | spin_unlock_irq(shost->host_lock); | 1146 | spin_unlock_irq(shost->host_lock); |
1166 | lpfc_unblock_requests(phba); | ||
1167 | return ret; | 1147 | return ret; |
1168 | } | 1148 | } |
1169 | 1149 | ||