diff options
author | Mark Kettenis <kettenis@cvs.openbsd.org> | 2011-01-12 21:00:05 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@cvs.openbsd.org> | 2011-01-12 21:00:05 +0000 |
commit | 24c2b7a58e9c4ece7fd90ba6c6d1b97475558f1b (patch) | |
tree | 60eaeabbe618bf489d722530afe09e1806f80643 /sys/dev/ata | |
parent | 4696e70b53ec105d8493563c14339d6502cfa78e (diff) |
Reset the state member of the ata_xfer to ATA_S_SETUP before reusing it
to issue another command, since sili(4) actually checks. Fix a small
inaccuracy in a comment while I'm there.
ok dlg@
Diffstat (limited to 'sys/dev/ata')
-rw-r--r-- | sys/dev/ata/atascsi.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/dev/ata/atascsi.c b/sys/dev/ata/atascsi.c index 46a7aae003e..dbd0c6e98ad 100644 --- a/sys/dev/ata/atascsi.c +++ b/sys/dev/ata/atascsi.c @@ -1,4 +1,4 @@ -/* $OpenBSD: atascsi.c,v 1.98 2010/11/20 05:12:39 deraadt Exp $ */ +/* $OpenBSD: atascsi.c,v 1.99 2011/01/12 21:00:04 kettenis Exp $ */ /* * Copyright (c) 2007 David Gwynne <dlg@openbsd.org> @@ -1186,7 +1186,7 @@ atascsi_disk_start_stop(struct scsi_xfer *xs) } /* - * A SCSI START_STOP UNIT command with the START bit set to + * A SCSI START STOP UNIT command with the START bit set to * zero gets translated into an ATA FLUSH CACHE command * followed by an ATA STANDBY IMMEDIATE command. */ @@ -1236,6 +1236,7 @@ atascsi_disk_start_stop_done(struct ata_xfer *xa) */ xa->datalen = 0; xa->flags = ATA_F_READ; + xa->state = ATA_S_SETUP; xa->complete = atascsi_disk_cmd_done; /* Spec says flush cache can take >30 sec, so give it at least 45. */ xa->timeout = (xs->timeout < 45000) ? 45000 : xs->timeout; |