diff options
author | Jason Downs <downsj@cvs.openbsd.org> | 1996-06-16 23:53:17 +0000 |
---|---|---|
committer | Jason Downs <downsj@cvs.openbsd.org> | 1996-06-16 23:53:17 +0000 |
commit | 6e35ed29145abb8e6b5e57c17edfa2b49355420f (patch) | |
tree | eb9b12bb5b4d0e3bb49cfde321b2c9cd2ca284eb /sys | |
parent | 38fba7f3882ae1103a04c2aad72a8edfdda4cae2 (diff) |
netbsd pr#2220: add SCIOCRESET. I can't think of any reason not to.
Diffstat (limited to 'sys')
-rw-r--r-- | sys/scsi/scsi_all.h | 6 | ||||
-rw-r--r-- | sys/scsi/scsi_ioctl.c | 6 |
2 files changed, 12 insertions, 0 deletions
diff --git a/sys/scsi/scsi_all.h b/sys/scsi/scsi_all.h index f0ab11090ef..5cf1d9f75a1 100644 --- a/sys/scsi/scsi_all.h +++ b/sys/scsi/scsi_all.h @@ -1,3 +1,4 @@ +/* $OpenBSD: scsi_all.h,v 1.3 1996/06/16 23:53:15 downsj Exp $ */ /* $NetBSD: scsi_all.h,v 1.7 1996/03/19 03:06:10 mycroft Exp $ */ /* @@ -179,6 +180,11 @@ struct scsi_changedef { #define READ_ELEMENT_STATUS 0xb8 /* + * Sort of an extra one, for SCSI_RESET. + */ +#define GENRETRY 1 + +/* * sense data format */ #define T_DIRECT 0 diff --git a/sys/scsi/scsi_ioctl.c b/sys/scsi/scsi_ioctl.c index 0d77b6620e8..b951641bfe4 100644 --- a/sys/scsi/scsi_ioctl.c +++ b/sys/scsi/scsi_ioctl.c @@ -1,3 +1,4 @@ +/* $OpenBSD: scsi_ioctl.c,v 1.3 1996/06/16 23:53:16 downsj Exp $ */ /* $NetBSD: scsi_ioctl.c,v 1.20 1996/02/14 21:47:22 christos Exp $ */ /* @@ -356,6 +357,11 @@ scsi_do_ioctl(sc_link, dev, cmd, addr, flag, p) sca->lun = sc_link->lun; return 0; } + case SCIOCRESET: { + scsi_scsi_cmd(sc_link, 0, 0, 0, 0, GENRETRY, 2000, NULL, + SCSI_RESET); + return 0; + } default: return ENOTTY; } |