summaryrefslogtreecommitdiffstats
path: root/sys/dev/fdc/fdcvar.h
diff options
context:
space:
mode:
authornjl <njl@FreeBSD.org>2004-07-12 20:49:26 +0000
committernjl <njl@FreeBSD.org>2004-07-12 20:49:26 +0000
commit7b5fb1c0fe7951487bba2244d8e9f2bee0f7c77c (patch)
treea20b1854c8515a1c3ce89b0e657b0ae22b62080a /sys/dev/fdc/fdcvar.h
parent91e23d98c534a497b70a4087007fa9d56902f65c (diff)
downloadFreeBSD-src-7b5fb1c0fe7951487bba2244d8e9f2bee0f7c77c.zip
FreeBSD-src-7b5fb1c0fe7951487bba2244d8e9f2bee0f7c77c.tar.gz
Update in preparation for adding the ACPI attachment.
* Add an fdtype ivar. This will be the equivalent of fd->type. * Move enabling the FIFO to the end of attach. * Unify reset code into fdc_initial_reset(). * Add fdc_write_ivar(). * Update isa and pccard attachments accordingly. * Set the flags unconditionally in probe since they may be overridden by other probe routines. Both before and now, we're depending on probe being called a final time on the winning driver so the flags we get are the ones we intended. * Use the bus accessor macros instead of defining our own. * Remove duplicate assigns of fd->type.
Diffstat (limited to 'sys/dev/fdc/fdcvar.h')
-rw-r--r--sys/dev/fdc/fdcvar.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/sys/dev/fdc/fdcvar.h b/sys/dev/fdc/fdcvar.h
index 4271b7a..30dd825 100644
--- a/sys/dev/fdc/fdcvar.h
+++ b/sys/dev/fdc/fdcvar.h
@@ -124,11 +124,21 @@ typedef enum fdc_type fdc_t;
extern devclass_t fdc_devclass;
+enum fdc_device_ivars {
+ FDC_IVAR_FDUNIT,
+ FDC_IVAR_FDTYPE,
+};
+
+__BUS_ACCESSOR(fdc, fdunit, FDC, FDUNIT, int);
+__BUS_ACCESSOR(fdc, fdtype, FDC, FDTYPE, int);
+
int fdc_alloc_resources(struct fdc_data *);
void fdout_wr(fdc_p, u_int8_t);
int fd_cmd(struct fdc_data *, int, ...);
void fdc_release_resources(struct fdc_data *);
int fdc_attach(device_t);
int fdc_detach(device_t dev);
+int fdc_initial_reset(struct fdc_data *);
int fdc_print_child(device_t, device_t);
int fdc_read_ivar(device_t, device_t, int, uintptr_t *);
+int fdc_write_ivar(device_t, device_t, int, uintptr_t);
OpenPOWER on IntegriCloud