Fix or add protection for mutiple inclusion.

This commit is contained in:
enami 1998-02-13 04:19:13 +00:00
parent 7d9acb9bb6
commit ef09ae656f
22 changed files with 115 additions and 77 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: atapi_all.h,v 1.1 1998/01/15 02:21:27 cgd Exp $ */
/* $NetBSD: atapi_all.h,v 1.2 1998/02/13 04:19:13 enami Exp $ */
/*
* Copyright (c) 1996 Manuel Bouyer. All rights reserved.
@ -29,6 +29,9 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef _DEV_SCSIPI_ATAPI_ALL_H_
#define _DEV_SCSIPI_ATAPI_ALL_H_
#define ATAPI_MODE_SELECT 0x55
struct atapi_mode_select {
u_int8_t opcode;
@ -67,3 +70,5 @@ struct atapi_mode_header {
#define MDT_FMT_ERROR 0x72
u_int8_t reserved[5];
};
#endif /* _DEV_SCSIPI_ATAPI_ALL_H_ */

View File

@ -1,4 +1,4 @@
/* $NetBSD: atapi_cd.h,v 1.5 1998/01/15 02:21:28 cgd Exp $ */
/* $NetBSD: atapi_cd.h,v 1.6 1998/02/13 04:19:14 enami Exp $ */
/*
* Copyright (c) 1996 Manuel Bouyer. All rights reserved.
@ -29,6 +29,9 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef _DEV_SCSIPI_ATAPI_CD_H_
#define _DEV_SCSIPI_ATAPI_CD_H_
struct atapi_cdrom_page {
u_int8_t page;
u_int8_t length;
@ -109,3 +112,5 @@ struct atapi_cd_mode_data {
(sizeof(struct atapi_mode_header) + sizeof(struct atapi_cdrom_page))
#define CAPPAGESIZE \
(sizeof(struct atapi_mode_header) + sizeof(struct atapi_cap_page))
#endif /* _DEV_SCSIPI_ATAPI_CD_H_ */

View File

@ -1,4 +1,4 @@
/* $NetBSD: atapi_disk.h,v 1.1 1998/01/15 02:21:29 cgd Exp $ */
/* $NetBSD: atapi_disk.h,v 1.2 1998/02/13 04:19:15 enami Exp $ */
/*
* Copyright 1998
@ -33,6 +33,9 @@
* even if advised of the possibility of such damage.
*/
#ifndef _DEV_SCSIPI_ATAPI_DISK_H_
#define _DEV_SCSIPI_ATAPI_DISK_H_
/*
* Definitions of commands and structures specific to ATAPI disks.
*
@ -98,3 +101,5 @@ struct atapi_sd_mode_data {
#define FLEXGEOMETRYPAGESIZE \
(sizeof(struct atapi_mode_header) + sizeof(struct atapi_flex_geometry_page))
#endif /* _DEV_SCSIPI_ATAPI_DISK_H_ */

View File

@ -1,4 +1,4 @@
/* $NetBSD: atapiconf.h,v 1.4 1998/01/15 02:21:30 cgd Exp $ */
/* $NetBSD: atapiconf.h,v 1.5 1998/02/13 04:19:16 enami Exp $ */
/*
* Copyright (c) 1996 Manuel Bouyer. All rights reserved.
@ -29,8 +29,8 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef SCSI_ATAPICONF_H
#define SCSI_ATAPICONF_H
#ifndef _DEV_SCSIPI_ATAPICONF_H_
#define _DEV_SCSIPI_ATAPICONF_H_
#include <dev/scsipi/scsipiconf.h>
@ -141,4 +141,4 @@ int atapi_mode_select __P((struct scsipi_link *,
int atapi_mode_sense __P((struct scsipi_link *, int,
struct atapi_mode_header *, int, int, int, int));
#endif /* SCSI_ATAPICONF_H */
#endif /* _DEV_SCSIPI_ATAPICONF_H_ */

View File

@ -1,4 +1,4 @@
/* $NetBSD: cdvar.h,v 1.5 1998/01/15 02:21:34 cgd Exp $ */
/* $NetBSD: cdvar.h,v 1.6 1998/02/13 04:19:17 enami Exp $ */
/*
* Copyright (c) 1997 Manuel Bouyer. All rights reserved.
@ -29,6 +29,9 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef _DEV_SCSIPI_CDVAR_H_
#define _DEV_SCSIPI_CDVAR_H_
#define CDRETRIES 1
struct cd_ops;
@ -67,3 +70,5 @@ struct cd_ops {
void cdattach __P((struct device *, struct cd_softc *, struct scsipi_link *,
const struct cd_ops *));
#endif /* _DEV_SCSIPI_CDVAR_H_ */

View File

@ -1,9 +1,12 @@
/* $NetBSD: scsi_all.h,v 1.12 1997/10/01 01:18:54 enami Exp $ */
/* $NetBSD: scsi_all.h,v 1.13 1998/02/13 04:19:18 enami Exp $ */
/*
* SCSI-specific insterface description.
*/
#ifndef _DEV_SCSIPI_SCSI_ALL_H_
#define _DEV_SCSIPI_SCSI_ALL_H_
/*
* Largely written by Julian Elischer (julian@tfs.com)
* for TRW Financial Systems.
@ -21,9 +24,6 @@
* Ported to run under 386BSD by Julian Elischer (julian@tfs.com) Sept 1992
*/
#ifndef _SCSI_SCSI_ALL_H
#define _SCSI_SCSI_ALL_H 1
/*
* SCSI command format
*/
@ -177,4 +177,4 @@ struct scsi_mode_header_big {
#define SCSI_INTERM 0x10
#define SCSI_QUEUE_FULL 0x28
#endif /* _SCSI_SCSI_ALL_H */
#endif /* _DEV_SCSIPI_SCSI_ALL_H_ */

View File

@ -1,4 +1,4 @@
/* $NetBSD: scsi_cd.h,v 1.10 1997/10/17 17:54:37 bouyer Exp $ */
/* $NetBSD: scsi_cd.h,v 1.11 1998/02/13 04:19:19 enami Exp $ */
/*
* Written by Julian Elischer (julian@tfs.com)
@ -16,8 +16,9 @@
*
* Ported to run under 386BSD by Julian Elischer (julian@tfs.com) Sept 1992
*/
#ifndef _SCSI_SCSI_CD_H
#define _SCSI_SCSI_CD_H 1
#ifndef _DEV_SCSIPI_SCSI_CD_H_
#define _DEV_SCSIPI_SCSI_CD_H_
/*
* SCSI specific command format
@ -88,4 +89,4 @@ struct scsi_cd_mode_data {
(sizeof(struct scsi_mode_header) + sizeof(struct scsi_blk_desc) \
+ sizeof(struct cd_audio_page))
#endif /*_SCSI_SCSI_CD_H*/
#endif /* _DEV_SCSIPI_SCSI_CD_H_ */

View File

@ -1,4 +1,4 @@
/* $NetBSD: scsi_changer.h,v 1.9 1997/09/29 00:55:26 mjacob Exp $ */
/* $NetBSD: scsi_changer.h,v 1.10 1998/02/13 04:19:21 enami Exp $ */
/*
* Copyright (c) 1996 Jason R. Thorpe <thorpej@and.com>
@ -36,6 +36,9 @@
* SUCH DAMAGE.
*/
#ifndef _DEV_SCSIPI_SCSI_CHANGER_H_
#define _DEV_SCSIPI_SCSI_CHANGER_H_
/*
* SCSI changer interface description
*/
@ -59,9 +62,6 @@
* Ported to run under 386BSD by Julian Elischer (julian@tfs.com) Sept 1992
*/
#ifndef _SCSI_SCSI_CHANGER_H
#define _SCSI_SCSI_CHANGER_H 1
/*
* SCSI command format
*/
@ -397,4 +397,4 @@ struct page_transport_geometry_parameters {
u_int8_t member;
};
#endif /* _SCSI_SCSI_CHANGER_H */
#endif /* _DEV_SCSIPI_SCSI_CHANGER_H_ */

View File

@ -1,17 +1,17 @@
/* $NetBSD: scsi_ctron_ether.h,v 1.4 1997/08/27 11:26:38 bouyer Exp $ */
/* $NetBSD: scsi_ctron_ether.h,v 1.5 1998/02/13 04:19:22 enami Exp $ */
/*
* SCSI interface description
*/
#ifndef _DEV_SCSIPI_SCSI_CTRON_ETHER_H_
#define _DEV_SCSIPI_SCSI_CTRON_ETHER_H_
/*
* SCSI command format
*/
#ifndef _SCSI_CTRON_ETHER_H
#define _SCSI_CTRON_ETHER_H 1
#define CTRON_ETHERCMD2(OP, SUB) {OP, SUB}
#define CTRON_ETHER_SEND CTRON_ETHERCMD2(0xc, 0x1)
#define CTRON_ETHER_RECV 0xe1
@ -105,4 +105,4 @@ enum scsi_ctron_ether_media {
CMEDIA_AUTOSENSE=2 /* set_media command only */
};
#endif /* _SCSI_CTRON_ETHER_H */
#endif /* _DEV_SCSIPI_SCSI_CTRON_ETHER_H_ */

View File

@ -1,9 +1,12 @@
/* $NetBSD: scsi_disk.h,v 1.13 1997/10/03 01:56:52 thorpej Exp $ */
/* $NetBSD: scsi_disk.h,v 1.14 1998/02/13 04:19:23 enami Exp $ */
/*
* SCSI-specific interface description
*/
#ifndef _DEV_SCSIPI_SCSI_DISK_H_
#define _DEV_SCSIPI_SCSI_DISK_H_
/*
* Some lines of this file come from a file of the name "scsi.h"
* distributed by OSF as part of mach2.5,
@ -53,9 +56,6 @@
* SCSI command format
*/
#ifndef _SCSI_SCSI_DISK_H
#define _SCSI_SCSI_DISK_H 1
/*
* XXX for now this isn't in the ATAPI specs, but if there are on day
* ATAPI hard disks, it is likely that they implement this command (or a
@ -175,4 +175,4 @@ union scsi_disk_pages {
} flex_geometry;
};
#endif /* _SCSI_SCSI_DISK_H */
#endif /* _DEV_SCSIPI_SCSI_DISK_H_ */

View File

@ -1,4 +1,4 @@
/* $NetBSD: scsi_scanner.h,v 1.4 1998/01/05 07:31:14 perry Exp $ */
/* $NetBSD: scsi_scanner.h,v 1.5 1998/02/13 04:19:24 enami Exp $ */
/*
* Copyright (c) 1995 Kenneth Stailey. All rights reserved.
@ -30,13 +30,13 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef _DEV_SCSIPI_SCSI_SCANNER_H_
#define _DEV_SCSIPI_SCSI_SCANNER_H_
/*
* SCSI scanner interface description
*/
#ifndef _SCSI_SCANNER_H_
#define _SCSI_SCANNER_H_
/* SCSI scanner commands */
#define GET_IMAGE_STATUS 0x0f
#define READ_BIG 0x28
@ -113,4 +113,4 @@ struct scsi_window_data {
#define MUSTEK_ADF 0x10 /* ADF and backtracking selection */
#define MUSTEK_LUT 0x55 /* look up table download */
#endif /* _SCSI_SCANNER_H_ */
#endif /* _DEV_SCSIPI_SCSI_SCANNER_H_ */

View File

@ -1,4 +1,4 @@
/* $NetBSD: scsi_tape.h,v 1.12 1997/10/01 01:19:01 enami Exp $ */
/* $NetBSD: scsi_tape.h,v 1.13 1998/02/13 04:19:26 enami Exp $ */
/*
* Copyright (c) 1994 Charles Hannum. All rights reserved.
@ -29,6 +29,9 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef _DEV_SCSIPI_SCSI_TAPE_H_
#define _DEV_SCSIPI_SCSI_TAPE_H_
/*
* Originally written by Julian Elischer (julian@tfs.com)
* for TRW Financial Systems.
@ -50,9 +53,6 @@
* SCSI tape interface description
*/
#ifndef _SCSI_TAPE_H_
#define _SCSI_TAPE_H_ 1
/*
* SCSI command formats
*/
@ -276,4 +276,4 @@ struct scsi_tape_read_position {
#define DAT_1 0x13
#define QIC_3095 0x45
#endif /* _SCSI_TAPE_H_ */
#endif /* _DEV_SCSIPI_SCSI_TAPE_H_ */

View File

@ -1,4 +1,4 @@
/* $NetBSD: scsiconf.h,v 1.39 1997/10/01 01:19:04 enami Exp $ */
/* $NetBSD: scsiconf.h,v 1.40 1998/02/13 04:19:27 enami Exp $ */
/*
* Copyright (c) 1993, 1994, 1995 Charles Hannum. All rights reserved.
@ -29,6 +29,9 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef _DEV_SCSIPI_SCSICONF_H_
#define _DEV_SCSIPI_SCSICONF_H_
/*
* Originally written by Julian Elischer (julian@tfs.com)
* for TRW Financial Systems for use under the MACH(2.5) operating system.
@ -46,9 +49,6 @@
* Ported to run under 386BSD by Julian Elischer (julian@tfs.com) Sept 1992
*/
#ifndef SCSI_SCSICONF_H
#define SCSI_SCSICONF_H 1
#include <dev/scsipi/scsipiconf.h>
/*
@ -89,4 +89,4 @@ int scsi_scsipi_cmd __P((struct scsipi_link *, struct scsipi_generic *,
int cmdlen, u_char *data_addr, int datalen, int retries,
int timeout, struct buf *bp, int flags));
#endif /* SCSI_SCSICONF_H */
#endif /* _DEV_SCSIPI_SCSICONF_H_ */

View File

@ -1,9 +1,12 @@
/* $NetBSD: scsipi_all.h,v 1.5 1997/10/03 02:04:19 thorpej Exp $ */
/* $NetBSD: scsipi_all.h,v 1.6 1998/02/13 04:19:28 enami Exp $ */
/*
* SCSI and SCSI-like general interface description
*/
#ifndef _DEV_SCSIPI_SCSIPI_ALL_H_
#define _DEV_SCSIPI_SCSIPI_ALL_H_
/*
* Largely written by Julian Elischer (julian@tfs.com)
* for TRW Financial Systems.
@ -21,9 +24,6 @@
* Ported to run under 386BSD by Julian Elischer (julian@tfs.com) Sept 1992
*/
#ifndef _SCSI_PI_ALL_H
#define _SCSI_PI_ALL_H 1
/*
* SCSI-like command format and opcode
*/
@ -163,4 +163,4 @@ struct scsipi_inquiry_data {
u_int8_t extra[8];
};
#endif /* _SCSI_PI_ALL_H */
#endif /* _DEV_SCSIPI_SCSIPI_ALL_H_ */

View File

@ -1,4 +1,4 @@
/* $NetBSD: scsipi_base.h,v 1.5 1998/01/15 02:21:36 cgd Exp $ */
/* $NetBSD: scsipi_base.h,v 1.6 1998/02/13 04:19:29 enami Exp $ */
/*
* Copyright (c) 1994, 1995, 1997 Charles M. Hannum. All rights reserved.
@ -29,6 +29,9 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef _DEV_SCSIPI_SCSIPI_BASE_H_
#define _DEV_SCSIPI_SCSIPI_BASE_H_
/*
* Originally written by Julian Elischer (julian@dialix.oz.au)
*/
@ -81,3 +84,5 @@ scsipi_make_xs(sc_link, scsipi_cmd, cmdlen, data_addr, datalen,
return (xs);
}
#endif /* _DEV_SCSIPI_SCSIPI_BASE_H_ */

View File

@ -1,4 +1,4 @@
/* $NetBSD: scsipi_cd.h,v 1.3 1997/10/01 01:19:09 enami Exp $ */
/* $NetBSD: scsipi_cd.h,v 1.4 1998/02/13 04:19:30 enami Exp $ */
/*
* Written by Julian Elischer (julian@tfs.com)
@ -16,8 +16,9 @@
*
* Ported to run under 386BSD by Julian Elischer (julian@tfs.com) Sept 1992
*/
#ifndef _SCSI_PI_CD_H
#define _SCSI_PI_CD_H 1
#ifndef _DEV_SCSIPI_SCSIPI_CD_H_
#define _DEV_SCSIPI_SCSIPI_CD_H_
/*
* Define two bits always in the same place in byte 2 (flag byte)
@ -144,4 +145,4 @@ struct cd_audio_page {
#define RIGHT_PORT 1
};
#endif /* _SCSI_PI_CD_H */
#endif /* _DEV_SCSIPI_SCSIPI_CD_H_ */

View File

@ -1,10 +1,11 @@
/* $NetBSD: scsipi_debug.h,v 1.10 1997/10/24 15:44:42 christos Exp $ */
/* $NetBSD: scsipi_debug.h,v 1.11 1998/02/13 04:19:31 enami Exp $ */
/*
* Written by Julian Elischer (julian@tfs.com)
*/
#ifndef _SCSI_PI_DEBUG_H
#define _SCSI_PI_DEBUG_H 1
#ifndef _DEV_SCSIPI_SCSIPI_DEBUG_H_
#define _DEV_SCSIPI_SCSIPI_DEBUG_H_
/*
* These are the new debug bits. (Sat Oct 2 12:46:46 WST 1993)
@ -46,4 +47,4 @@ do { \
#define SC_DEBUGN(A,B,C)
#endif
#endif /* _SCSI_PI_DEBUG_H */
#endif /* _DEV_SCSIPI_SCSIPI_DEBUG_H_ */

View File

@ -1,9 +1,12 @@
/* $NetBSD: scsipi_disk.h,v 1.3 1997/10/01 01:19:10 enami Exp $ */
/* $NetBSD: scsipi_disk.h,v 1.4 1998/02/13 04:19:32 enami Exp $ */
/*
* SCSI and SCSI-like interfaces description
*/
#ifndef _DEV_SCSIPI_SCSIPI_DISK_H_
#define _DEV_SCSIPI_SCSIPI_DISK_H_
/*
* Some lines of this file come from a file of the name "scsi.h"
* distributed by OSF as part of mach2.5,
@ -53,9 +56,6 @@
* SCSI command format
*/
#ifndef _SCSI_PI_DISK_H
#define _SCSI_PI_DISK_H 1
#define READ_BIG 0x28
#define WRITE_BIG 0x2a
struct scsipi_rw_big {
@ -97,4 +97,4 @@ struct scsipi_read_cap_data {
u_int8_t length[4];
};
#endif /* _SCSI_PI_DISK_H */
#endif /* _DEV_SCSIPI_SCSIPI_DISK_H_ */

View File

@ -1,4 +1,4 @@
/* $NetBSD: scsipiconf.h,v 1.7 1998/01/15 02:21:37 cgd Exp $ */
/* $NetBSD: scsipiconf.h,v 1.8 1998/02/13 04:19:33 enami Exp $ */
/*
* Copyright (c) 1993, 1994, 1995 Charles Hannum. All rights reserved.
@ -29,6 +29,9 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef _DEV_SCSIPI_SCSIPICONF_H_
#define _DEV_SCSIPI_SCSIPICONF_H_
/*
* Originally written by Julian Elischer (julian@tfs.com)
* for TRW Financial Systems for use under the MACH(2.5) operating system.
@ -46,9 +49,6 @@
* Ported to run under 386BSD by Julian Elischer (julian@tfs.com) Sept 1992
*/
#ifndef SCSI_BUSCONF_H
#define SCSI_BUSCONF_H 1
typedef int boolean;
#include <sys/queue.h>
@ -524,4 +524,4 @@ bswap (buf, len)
*p = (*p & 0xff) << 8 | (*p >> 8 & 0xff);
}
#endif /* SCSI_BUSCONF_H */
#endif /* _DEV_SCSIPI_SCSIPICONF_H_ */

View File

@ -1,4 +1,4 @@
/* $NetBSD: sdvar.h,v 1.1 1998/01/15 02:21:40 cgd Exp $ */
/* $NetBSD: sdvar.h,v 1.2 1998/02/13 04:19:35 enami Exp $ */
/*
* Copyright (c) 1994, 1995, 1997 Charles M. Hannum. All rights reserved.
@ -29,6 +29,9 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef _DEV_SCSIPI_SDVAR_H_
#define _DEV_SCSIPI_SDVAR_H_
/*
* Originally written by Julian Elischer (julian@dialix.oz.au)
* for TRW Financial Systems for use under the MACH(2.5) operating system.
@ -88,3 +91,5 @@ struct sd_ops {
void sdattach __P((struct device *, struct sd_softc *, struct scsipi_link *,
const struct sd_ops *));
#endif /* _DEV_SCSIPI_SDVAR_H_ */

View File

@ -1,4 +1,4 @@
/* $NetBSD: ss_mustek.h,v 1.3 1997/08/27 11:27:07 bouyer Exp $ */
/* $NetBSD: ss_mustek.h,v 1.4 1998/02/13 04:19:36 enami Exp $ */
/*
* Copyright (c) 1995 Joachim Koenig-Baltes. All rights reserved.
@ -29,8 +29,8 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef _SS_MUSTEK_H_
#define _SS_MUSTEK_H_ 1
#ifndef _DEV_SCSIPI_SS_MUSTEK_H_
#define _DEV_SCSIPI_SS_MUSTEK_H_
/*
* support for MUSTEK flatbed SCSI scanners MFS-06000CX and MFS-12000CX
@ -176,4 +176,4 @@ struct mustek_start_scan_cmd {
u_int8_t control;
};
#endif /* _SS_MUSTEK_H_ */
#endif /* _DEV_SCSIPI_SS_MUSTEK_H_ */

View File

@ -1,4 +1,4 @@
/* $NetBSD: ssvar.h,v 1.3 1997/08/27 11:27:12 bouyer Exp $ */
/* $NetBSD: ssvar.h,v 1.4 1998/02/13 04:19:36 enami Exp $ */
/*
* Copyright (c) 1995 Kenneth Stailey. All rights reserved.
@ -30,6 +30,9 @@
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifndef _DEV_SCSIPI_SSVAR_H_
#define _DEV_SCSIPI_SSVAR_H_
/*
* SCSI scanner interface description
*/
@ -81,3 +84,5 @@ struct ss_softc {
*/
void mustek_attach __P((struct ss_softc *, struct scsipibus_attach_args *));
void scanjet_attach __P((struct ss_softc *, struct scsipibus_attach_args *));
#endif /* _DEV_SCSIPI_SSVAR_H_ */