diff options
author | Christopher Pascoe <pascoe@cvs.openbsd.org> | 2007-03-20 13:00:43 +0000 |
---|---|---|
committer | Christopher Pascoe <pascoe@cvs.openbsd.org> | 2007-03-20 13:00:43 +0000 |
commit | 47efffb371aa3ba598c34cf3cbfd6bf0ec9ffdc3 (patch) | |
tree | 9f2a1ba4f88d1ed9239bda46d132164172d8b6ec /sys/dev | |
parent | 8ad3dd287f167abc9db0881cabd3310329c6cfd1 (diff) |
Our timeout and error handlers complete the commands for us, so we should
always return ATA_COMPLETE in the polled transfer case. Also, respect the
passed in timeout value when polling.
Diffstat (limited to 'sys/dev')
-rw-r--r-- | sys/dev/pci/ahci.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/sys/dev/pci/ahci.c b/sys/dev/pci/ahci.c index c867d6ff5ca..b9522a46cab 100644 --- a/sys/dev/pci/ahci.c +++ b/sys/dev/pci/ahci.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ahci.c,v 1.88 2007/03/20 12:46:26 dlg Exp $ */ +/* $OpenBSD: ahci.c,v 1.89 2007/03/20 13:00:42 pascoe Exp $ */ /* * Copyright (c) 2006 David Gwynne <dlg@openbsd.org> @@ -1802,8 +1802,7 @@ ahci_ata_cmd(struct ata_xfer *xa) xa->state = ATA_S_PENDING; if (xa->flags & ATA_F_POLL) { - if (ahci_poll(ccb, 1000, ahci_ata_cmd_timeout) != 0) - return (ATA_ERROR); + ahci_poll(ccb, xa->timeout, ahci_ata_cmd_timeout); return (ATA_COMPLETE); } |