diff options
-rw-r--r-- | sys/scsi/scsi_scanner.h | 3 | ||||
-rw-r--r-- | sys/scsi/ss.c | 12 |
2 files changed, 11 insertions, 4 deletions
diff --git a/sys/scsi/scsi_scanner.h b/sys/scsi/scsi_scanner.h index 8c27ca3866c..c25f2289a33 100644 --- a/sys/scsi/scsi_scanner.h +++ b/sys/scsi/scsi_scanner.h @@ -1,4 +1,4 @@ -/* $OpenBSD: scsi_scanner.h,v 1.7 1997/03/10 02:29:39 kstailey Exp $ */ +/* $OpenBSD: scsi_scanner.h,v 1.8 1999/05/11 23:25:43 kstailey Exp $ */ /* * Copyright (c) 1995 Kenneth Stailey. All rights reserved. @@ -78,6 +78,7 @@ struct scsi_rw_scanner { }; struct scsi_start_stop { +#define START_STOP 0x1b u_int8_t opcode; u_int8_t byte2; u_int8_t unused[2]; diff --git a/sys/scsi/ss.c b/sys/scsi/ss.c index c8fc006a38f..6fc3ec3bda5 100644 --- a/sys/scsi/ss.c +++ b/sys/scsi/ss.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ss.c,v 1.36 1998/09/16 15:53:24 kstailey Exp $ */ +/* $OpenBSD: ss.c,v 1.37 1999/05/11 23:25:43 kstailey Exp $ */ /* $NetBSD: ss.c,v 1.10 1996/05/05 19:52:55 christos Exp $ */ /* @@ -525,7 +525,13 @@ ssread(dev, uio, flag) if (error) return (error); } else { - /* XXX addd code for generic trigger */ + struct scsi_start_stop trigger_cmd; + bzero(&trigger_cmd, sizeof(trigger_cmd)); + trigger_cmd.opcode = START_STOP; + trigger_cmd.how = SSS_START; + scsi_scsi_cmd(ss->sc_link, + (struct scsi_generic *)&trigger_cmd, + sizeof(trigger_cmd), 0, 0, 4, 5000, NULL, 0); } ss->flags |= SSF_TRIGGERED; } @@ -735,7 +741,7 @@ ss_set_window(ss, sio) } wd; #define window_data wd.window_data #define vendor_unique wd.vendor_unique - struct scsi_link *sc_link = ss->sc_link;; + struct scsi_link *sc_link = ss->sc_link; /* * The CDB for SET WINDOW goes in here. |