summaryrefslogtreecommitdiff
path: root/sys/dev/ata
diff options
context:
space:
mode:
authorthorpej <thorpej@NetBSD.org>2003-12-14 05:10:19 +0000
committerthorpej <thorpej@NetBSD.org>2003-12-14 05:10:19 +0000
commit09bbcae770a2a542abc61d4ab116aeb47b71b151 (patch)
tree79bd899b8fb81c90bac1fadefb95969196400faf /sys/dev/ata
parentbe3146e7b3cee90297b7d8086599655ab20e53a7 (diff)
Move struct ata_bustype from wdvar.h to atavar.h.
Diffstat (limited to 'sys/dev/ata')
-rw-r--r--sys/dev/ata/atavar.h31
-rw-r--r--sys/dev/ata/wdvar.h27
2 files changed, 31 insertions, 27 deletions
diff --git a/sys/dev/ata/atavar.h b/sys/dev/ata/atavar.h
index 352f85fa18d..54634587993 100644
--- a/sys/dev/ata/atavar.h
+++ b/sys/dev/ata/atavar.h
@@ -1,4 +1,4 @@
-/* $NetBSD: atavar.h,v 1.32 2003/12/14 05:03:28 thorpej Exp $ */
+/* $NetBSD: atavar.h,v 1.33 2003/12/14 05:10:19 thorpej Exp $ */
/*
* Copyright (c) 1998, 2001 Manuel Bouyer.
@@ -34,6 +34,8 @@
/* High-level functions and structures used by both ATA and ATAPI devices */
+struct ataparams;
+
/* Datas common to drives and controller drivers */
struct ata_drive_datas {
u_int8_t drive; /* drive number */
@@ -178,6 +180,33 @@ struct wdc_command {
};
/*
+ * ata_bustype. The first field must be compatible with scsipi_bustype,
+ * as it's used for autoconfig by both ata and atapi drivers.
+ */
+struct ata_bustype {
+ int bustype_type; /* symbolic name of type */
+ int (*ata_bio)(struct ata_drive_datas *, struct ata_bio *);
+ void (*ata_reset_channel)(struct ata_drive_datas *, int);
+ int (*ata_exec_command)(struct ata_drive_datas *,
+ struct wdc_command *);
+
+#define WDC_COMPLETE 0x01
+#define WDC_QUEUED 0x02
+#define WDC_TRY_AGAIN 0x03
+
+ int (*ata_get_params)(struct ata_drive_datas *, u_int8_t,
+ struct ataparams *);
+ int (*ata_addref)(struct ata_drive_datas *);
+ void (*ata_delref)(struct ata_drive_datas *);
+ void (*ata_killpending)(struct ata_drive_datas *);
+};
+
+/* bustype_type */ /* XXX XXX XXX */
+/* #define SCSIPI_BUSTYPE_SCSI 0 */
+/* #define SCSIPI_BUSTYPE_ATAPI 1 */
+#define SCSIPI_BUSTYPE_ATA 2
+
+/*
* If WDSM_ATTR_ADVISORY, device exceeded intended design life period.
* If not WDSM_ATTR_ADVISORY, imminent data loss predicted.
*/
diff --git a/sys/dev/ata/wdvar.h b/sys/dev/ata/wdvar.h
index c92024242e4..1a18e392465 100644
--- a/sys/dev/ata/wdvar.h
+++ b/sys/dev/ata/wdvar.h
@@ -1,4 +1,4 @@
-/* $NetBSD: wdvar.h,v 1.22 2003/12/14 05:03:28 thorpej Exp $ */
+/* $NetBSD: wdvar.h,v 1.23 2003/12/14 05:10:19 thorpej Exp $ */
/*
* Copyright (c) 1998, 2001 Manuel Bouyer.
@@ -31,31 +31,6 @@
*/
/*
- * ata_bustype. The first field has to be compatible with scsipi_bustype,
- * as it's used for autoconfig by both ata and atapi drivers
- */
-
-struct ata_bustype {
- int bustype_type; /* symbolic name of type */
- int (*ata_bio) __P((struct ata_drive_datas*, struct ata_bio *));
- void (*ata_reset_channel) __P((struct ata_drive_datas *, int));
- int (*ata_exec_command) __P((struct ata_drive_datas *,
- struct wdc_command *));
-#define WDC_COMPLETE 0x01
-#define WDC_QUEUED 0x02
-#define WDC_TRY_AGAIN 0x03
- int (*ata_get_params) __P((struct ata_drive_datas*, u_int8_t,
- struct ataparams *));
- int (*ata_addref) __P((struct ata_drive_datas *));
- void (*ata_delref) __P((struct ata_drive_datas *));
- void (*ata_killpending) __P((struct ata_drive_datas *));
-};
-/* bustype_type */
-/* #define SCSIPI_BUSTYPE_SCSI 0 */
-/* #define SCSIPI_BUSTYPE_ATAPI 1 */
-#define SCSIPI_BUSTYPE_ATA 2
-
-/*
* describe an ATA device. Has to be compatible with scsipi_channel, so start
* with a pointer to ata_bustype
*/