aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/message
diff options
context:
space:
mode:
authorMoore, Eric <Eric.Moore@lsil.com>2006-02-02 19:19:37 -0500
committer <jejb@mulgrave.il.steeleye.com>2006-02-04 17:31:50 -0500
commit86a7dcaae9c67a344e51190734b98684072d181c (patch)
tree7de380c56e4f0ec2235e92633e6285fe226e62dd /drivers/message
parent9cc1cfbc67d77164f5b612fcf833460eca4d81e9 (diff)
[SCSI] fusion - mtctl - change to wait_event_timeout
Change from using wait_event_interruptible_timeout to wait_event_timeout. Also delete white space and duplicate line of code. Signed-off-by: Eric Moore <Eric.Moore@lsil.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/message')
-rw-r--r--drivers/message/fusion/mptctl.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/drivers/message/fusion/mptctl.c b/drivers/message/fusion/mptctl.c
index 1a1bc66c8e9c..8e2369ff3322 100644
--- a/drivers/message/fusion/mptctl.c
+++ b/drivers/message/fusion/mptctl.c
@@ -385,18 +385,18 @@ static int mptctl_bus_reset(MPT_IOCTL *ioctl)
385 } 385 }
386 386
387 /* Now wait for the command to complete */ 387 /* Now wait for the command to complete */
388 ii = wait_event_interruptible_timeout(mptctl_wait, 388 ii = wait_event_timeout(mptctl_wait,
389 ioctl->wait_done == 1, 389 ioctl->wait_done == 1,
390 HZ*5 /* 5 second timeout */); 390 HZ*5 /* 5 second timeout */);
391 391
392 if(ii <=0 && (ioctl->wait_done != 1 )) { 392 if(ii <=0 && (ioctl->wait_done != 1 )) {
393 mpt_free_msg_frame(hd->ioc, mf);
393 ioctl->wait_done = 0; 394 ioctl->wait_done = 0;
394 retval = -1; /* return failure */ 395 retval = -1; /* return failure */
395 } 396 }
396 397
397mptctl_bus_reset_done: 398mptctl_bus_reset_done:
398 399
399 mpt_free_msg_frame(hd->ioc, mf);
400 mptctl_free_tm_flags(ioctl->ioc); 400 mptctl_free_tm_flags(ioctl->ioc);
401 return retval; 401 return retval;
402} 402}
@@ -807,7 +807,7 @@ mptctl_do_fw_download(int ioc, char __user *ufwbuf, size_t fwlen)
807 mpt_put_msg_frame(mptctl_id, iocp, mf); 807 mpt_put_msg_frame(mptctl_id, iocp, mf);
808 808
809 /* Now wait for the command to complete */ 809 /* Now wait for the command to complete */
810 ret = wait_event_interruptible_timeout(mptctl_wait, 810 ret = wait_event_timeout(mptctl_wait,
811 iocp->ioctl->wait_done == 1, 811 iocp->ioctl->wait_done == 1,
812 HZ*60); 812 HZ*60);
813 813
@@ -1172,12 +1172,11 @@ mptctl_getiocinfo (unsigned long arg, unsigned int data_size)
1172 karg->pciInfo.u.bits.deviceNumber = PCI_SLOT( pdev->devfn ); 1172 karg->pciInfo.u.bits.deviceNumber = PCI_SLOT( pdev->devfn );
1173 karg->pciInfo.u.bits.functionNumber = PCI_FUNC( pdev->devfn ); 1173 karg->pciInfo.u.bits.functionNumber = PCI_FUNC( pdev->devfn );
1174 } else if (cim_rev == 2) { 1174 } else if (cim_rev == 2) {
1175 /* Get the PCI bus, device, function and segment ID numbers 1175 /* Get the PCI bus, device, function and segment ID numbers
1176 for the IOC */ 1176 for the IOC */
1177 karg->pciInfo.u.bits.busNumber = pdev->bus->number; 1177 karg->pciInfo.u.bits.busNumber = pdev->bus->number;
1178 karg->pciInfo.u.bits.deviceNumber = PCI_SLOT( pdev->devfn ); 1178 karg->pciInfo.u.bits.deviceNumber = PCI_SLOT( pdev->devfn );
1179 karg->pciInfo.u.bits.functionNumber = PCI_FUNC( pdev->devfn ); 1179 karg->pciInfo.u.bits.functionNumber = PCI_FUNC( pdev->devfn );
1180 karg->pciInfo.u.bits.functionNumber = PCI_FUNC( pdev->devfn );
1181 karg->pciInfo.segmentID = pci_domain_nr(pdev->bus); 1180 karg->pciInfo.segmentID = pci_domain_nr(pdev->bus);
1182 } 1181 }
1183 1182
@@ -2153,7 +2152,7 @@ mptctl_do_mpt_command (struct mpt_ioctl_command karg, void __user *mfPtr)
2153 2152
2154 /* Now wait for the command to complete */ 2153 /* Now wait for the command to complete */
2155 timeout = (karg.timeout > 0) ? karg.timeout : MPT_IOCTL_DEFAULT_TIMEOUT; 2154 timeout = (karg.timeout > 0) ? karg.timeout : MPT_IOCTL_DEFAULT_TIMEOUT;
2156 timeout = wait_event_interruptible_timeout(mptctl_wait, 2155 timeout = wait_event_timeout(mptctl_wait,
2157 ioc->ioctl->wait_done == 1, 2156 ioc->ioctl->wait_done == 1,
2158 HZ*timeout); 2157 HZ*timeout);
2159 2158