diff options
author | James Bottomley <jejb@titanic.(none)> | 2005-06-17 19:42:23 -0400 |
---|---|---|
committer | James Bottomley <jejb@titanic.(none)> | 2005-06-17 19:42:23 -0400 |
commit | 3237ee78fc00f786d5f5aec6f9310b0e39069f15 (patch) | |
tree | 4c94e70ab846ffcb8bb5715fb3c8d8473358a323 /drivers/scsi/lpfc | |
parent | 9ee1c939d1cb936b1f98e8d81aeffab57bae46ab (diff) | |
parent | df0ae2497ddefd72a87f3a3b34ff32455d7d4ae0 (diff) |
merge by hand (fix up qla_os.c merge error)
Diffstat (limited to 'drivers/scsi/lpfc')
-rw-r--r-- | drivers/scsi/lpfc/lpfc_scsi.c | 36 |
1 files changed, 33 insertions, 3 deletions
diff --git a/drivers/scsi/lpfc/lpfc_scsi.c b/drivers/scsi/lpfc/lpfc_scsi.c index 42fab03ad2b..f2aff3f4042 100644 --- a/drivers/scsi/lpfc/lpfc_scsi.c +++ b/drivers/scsi/lpfc/lpfc_scsi.c | |||
@@ -798,7 +798,7 @@ lpfc_queuecommand(struct scsi_cmnd *cmnd, void (*done) (struct scsi_cmnd *)) | |||
798 | } | 798 | } |
799 | 799 | ||
800 | static int | 800 | static int |
801 | lpfc_abort_handler(struct scsi_cmnd *cmnd) | 801 | __lpfc_abort_handler(struct scsi_cmnd *cmnd) |
802 | { | 802 | { |
803 | struct lpfc_hba *phba = | 803 | struct lpfc_hba *phba = |
804 | (struct lpfc_hba *)cmnd->device->host->hostdata[0]; | 804 | (struct lpfc_hba *)cmnd->device->host->hostdata[0]; |
@@ -918,7 +918,17 @@ lpfc_abort_handler(struct scsi_cmnd *cmnd) | |||
918 | } | 918 | } |
919 | 919 | ||
920 | static int | 920 | static int |
921 | lpfc_reset_lun_handler(struct scsi_cmnd *cmnd) | 921 | lpfc_abort_handler(struct scsi_cmnd *cmnd) |
922 | { | ||
923 | int rc; | ||
924 | spin_lock_irq(cmnd->device->host->host_lock); | ||
925 | rc = __lpfc_abort_handler(cmnd); | ||
926 | spin_unlock_irq(cmnd->device->host->host_lock); | ||
927 | return rc; | ||
928 | } | ||
929 | |||
930 | static int | ||
931 | __lpfc_reset_lun_handler(struct scsi_cmnd *cmnd) | ||
922 | { | 932 | { |
923 | struct Scsi_Host *shost = cmnd->device->host; | 933 | struct Scsi_Host *shost = cmnd->device->host; |
924 | struct lpfc_hba *phba = (struct lpfc_hba *)shost->hostdata[0]; | 934 | struct lpfc_hba *phba = (struct lpfc_hba *)shost->hostdata[0]; |
@@ -1030,11 +1040,21 @@ out: | |||
1030 | return ret; | 1040 | return ret; |
1031 | } | 1041 | } |
1032 | 1042 | ||
1043 | static int | ||
1044 | lpfc_reset_lun_handler(struct scsi_cmnd *cmnd) | ||
1045 | { | ||
1046 | int rc; | ||
1047 | spin_lock_irq(cmnd->device->host->host_lock); | ||
1048 | rc = __lpfc_reset_lun_handler(cmnd); | ||
1049 | spin_unlock_irq(cmnd->device->host->host_lock); | ||
1050 | return rc; | ||
1051 | } | ||
1052 | |||
1033 | /* | 1053 | /* |
1034 | * Note: midlayer calls this function with the host_lock held | 1054 | * Note: midlayer calls this function with the host_lock held |
1035 | */ | 1055 | */ |
1036 | static int | 1056 | static int |
1037 | lpfc_reset_bus_handler(struct scsi_cmnd *cmnd) | 1057 | __lpfc_reset_bus_handler(struct scsi_cmnd *cmnd) |
1038 | { | 1058 | { |
1039 | struct Scsi_Host *shost = cmnd->device->host; | 1059 | struct Scsi_Host *shost = cmnd->device->host; |
1040 | struct lpfc_hba *phba = (struct lpfc_hba *)shost->hostdata[0]; | 1060 | struct lpfc_hba *phba = (struct lpfc_hba *)shost->hostdata[0]; |
@@ -1124,6 +1144,16 @@ out: | |||
1124 | } | 1144 | } |
1125 | 1145 | ||
1126 | static int | 1146 | static int |
1147 | lpfc_reset_bus_handler(struct scsi_cmnd *cmnd) | ||
1148 | { | ||
1149 | int rc; | ||
1150 | spin_lock_irq(cmnd->device->host->host_lock); | ||
1151 | rc = __lpfc_reset_bus_handler(cmnd); | ||
1152 | spin_unlock_irq(cmnd->device->host->host_lock); | ||
1153 | return rc; | ||
1154 | } | ||
1155 | |||
1156 | static int | ||
1127 | lpfc_slave_alloc(struct scsi_device *sdev) | 1157 | lpfc_slave_alloc(struct scsi_device *sdev) |
1128 | { | 1158 | { |
1129 | struct lpfc_hba *phba = (struct lpfc_hba *)sdev->host->hostdata[0]; | 1159 | struct lpfc_hba *phba = (struct lpfc_hba *)sdev->host->hostdata[0]; |