summaryrefslogtreecommitdiff
path: root/sys/dev
diff options
context:
space:
mode:
authorKenneth R Westerback <krw@cvs.openbsd.org>2005-12-03 16:22:25 +0000
committerKenneth R Westerback <krw@cvs.openbsd.org>2005-12-03 16:22:25 +0000
commit6ad13923465463a1e1f525c04187df34597fe38e (patch)
treeda151284638a4d4a10edcf7c7c4bf9479cfca282 /sys/dev
parentb2b07fdd2571dda707777c6b00ebdea5a6c6fd36 (diff)
Don't retry unsupported SCSI commands by returning TRY_AGAIN_LATER.
They aren't going to be magically supported the next time. Elminates a long delay at boot time, since TRY_AGAIN_LATER code was recently fixed to delay a second before retrying and MODE SENSE commands were reclassified as unsupported. ok tdeval@ marco@
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/ic/gdt_common.c14
1 files changed, 5 insertions, 9 deletions
diff --git a/sys/dev/ic/gdt_common.c b/sys/dev/ic/gdt_common.c
index 1265fe729cc..edf275dc898 100644
--- a/sys/dev/ic/gdt_common.c
+++ b/sys/dev/ic/gdt_common.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: gdt_common.c,v 1.30 2005/09/15 05:33:39 krw Exp $ */
+/* $OpenBSD: gdt_common.c,v 1.31 2005/12/03 16:22:24 krw Exp $ */
/*
* Copyright (c) 1999, 2000, 2003 Niklas Hallqvist. All rights reserved.
@@ -71,7 +71,7 @@ void gdt_eval_mapping(u_int32_t, int *, int *, int *);
int gdt_exec_ccb(struct gdt_ccb *);
void gdt_free_ccb(struct gdt_softc *, struct gdt_ccb *);
struct gdt_ccb *gdt_get_ccb(struct gdt_softc *, int);
-int gdt_internal_cache_cmd(struct scsi_xfer *);
+void gdt_internal_cache_cmd(struct scsi_xfer *);
int gdt_internal_cmd(struct gdt_softc *, u_int8_t, u_int16_t,
u_int32_t, u_int32_t, u_int32_t);
#if NBIO > 0
@@ -552,10 +552,7 @@ gdt_scsi_cmd(xs)
#if 0
case VERIFY:
#endif
- if (!gdt_internal_cache_cmd(xs)) {
- GDT_UNLOCK_GDT(gdt, lock);
- return (TRY_AGAIN_LATER);
- }
+ gdt_internal_cache_cmd(xs);
xs->flags |= ITSDONE;
scsi_done(xs);
goto ready;
@@ -845,7 +842,7 @@ gdt_copy_internal_data(xs, data, size)
}
/* Emulated SCSI operation on cache device */
-int
+void
gdt_internal_cache_cmd(xs)
struct scsi_xfer *xs;
{
@@ -909,11 +906,10 @@ gdt_internal_cache_cmd(xs)
GDT_DPRINTF(GDT_D_CMD, ("unsupported scsi command %#x tgt %d ",
xs->cmd->opcode, target));
xs->error = XS_DRIVER_STUFFUP;
- return (0);
+ return;
}
xs->error = XS_NOERROR;
- return (1);
}
/* Start a raw SCSI operation */