diff options
author | Kenneth R Westerback <krw@cvs.openbsd.org> | 2005-05-23 07:06:17 +0000 |
---|---|---|
committer | Kenneth R Westerback <krw@cvs.openbsd.org> | 2005-05-23 07:06:17 +0000 |
commit | 7e803234e0920a8f5b5ecfb63c99ab9895709888 (patch) | |
tree | 8b1279f26b92580f60518487684f810524827ce4 /sys/scsi/sd_scsi.c | |
parent | 51f7e1263318c3fc9c7dc79d89556d7cde372dd1 (diff) |
Don't bzero() data before calling scsi_mode_sense[_big]() since
scsi_mode_sense[_big] bzero()'s it.
Diffstat (limited to 'sys/scsi/sd_scsi.c')
-rw-r--r-- | sys/scsi/sd_scsi.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/sys/scsi/sd_scsi.c b/sys/scsi/sd_scsi.c index d6498e66943..a29b4688eeb 100644 --- a/sys/scsi/sd_scsi.c +++ b/sys/scsi/sd_scsi.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sd_scsi.c,v 1.9 2005/05/14 00:20:43 krw Exp $ */ +/* $OpenBSD: sd_scsi.c,v 1.10 2005/05/23 07:06:16 krw Exp $ */ /* $NetBSD: sd_scsi.c,v 1.8 1998/10/08 20:21:13 thorpej Exp $ */ /*- @@ -107,7 +107,6 @@ sd_scsibus_get_optparms(sd, dp, flags) * However, there are stupid optical devices which does NOT * support the page 6. Ask for all (0x3f) pages. Ghaa.... */ - bzero(&scsi_sense, sizeof(scsi_sense)); error = scsi_mode_sense(sd->sc_link, 0, 0x3f, (struct scsi_mode_header *)&scsi_sense, sizeof(scsi_sense), flags, 6000); @@ -152,7 +151,6 @@ sd_scsibus_get_parms(sd, dp, flags) if (sd->type == T_OPTICAL) return (sd_scsibus_get_optparms(sd, dp, flags)); - bzero(&scsi_sense, sizeof(scsi_sense)); error = scsi_mode_sense(sd->sc_link, 0, page = 4, (struct scsi_mode_header *)&scsi_sense, sizeof(scsi_sense), flags | SCSI_SILENT, 6000); @@ -201,7 +199,6 @@ sd_scsibus_get_parms(sd, dp, flags) return (SDGP_RESULT_OK); } - bzero(&scsi_sense, sizeof(scsi_sense)); error = scsi_mode_sense(sd->sc_link, 0, page = 5, (struct scsi_mode_header *)&scsi_sense, sizeof(scsi_sense), flags | SCSI_SILENT, 6000); @@ -229,7 +226,6 @@ sd_scsibus_get_parms(sd, dp, flags) } /* T_RDIRECT define page 6. */ - bzero(&scsi_sense, sizeof(scsi_sense)); error = scsi_mode_sense(sd->sc_link, 0, page = 6, (struct scsi_mode_header *)&scsi_sense, sizeof(scsi_sense), flags | SCSI_SILENT, 6000); |