summaryrefslogtreecommitdiffstats
path: root/sys/dev/firewire
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2004-06-16 09:47:26 +0000
committerphk <phk@FreeBSD.org>2004-06-16 09:47:26 +0000
commitdfd1f7fd50fffaf75541921fcf86454cd8eb3614 (patch)
tree624c885995e84df6decddd3291c60a15e50e3c85 /sys/dev/firewire
parentcafb94bcea1cdf048e81b7eb2d24808e1a8c5280 (diff)
downloadFreeBSD-src-dfd1f7fd50fffaf75541921fcf86454cd8eb3614.zip
FreeBSD-src-dfd1f7fd50fffaf75541921fcf86454cd8eb3614.tar.gz
Do the dreaded s/dev_t/struct cdev */
Bump __FreeBSD_version accordingly.
Diffstat (limited to 'sys/dev/firewire')
-rw-r--r--sys/dev/firewire/firewirereg.h6
-rw-r--r--sys/dev/firewire/fwdev.c22
-rw-r--r--sys/dev/firewire/fwmem.c14
-rw-r--r--sys/dev/firewire/fwohci.c2
4 files changed, 22 insertions, 22 deletions
diff --git a/sys/dev/firewire/firewirereg.h b/sys/dev/firewire/firewirereg.h
index 5b43387..3c44a55 100644
--- a/sys/dev/firewire/firewirereg.h
+++ b/sys/dev/firewire/firewirereg.h
@@ -72,7 +72,7 @@ struct fw_device{
struct firewire_softc {
#if defined(__FreeBSD__) && __FreeBSD_version >= 500000
- dev_t dev;
+ struct cdev *dev;
#endif
struct firewire_comm *fc;
};
@@ -156,7 +156,7 @@ struct firewire_comm{
uint32_t (*cyctimer) (struct firewire_comm *);
void (*ibr) (struct firewire_comm *);
uint32_t (*set_bmr) (struct firewire_comm *, uint32_t);
- int (*ioctl) (dev_t, u_long, caddr_t, int, fw_proc *);
+ int (*ioctl) (struct cdev *, u_long, caddr_t, int, fw_proc *);
int (*irx_enable) (struct firewire_comm *, int);
int (*irx_disable) (struct firewire_comm *, int);
int (*itx_enable) (struct firewire_comm *, int);
@@ -303,7 +303,7 @@ struct fw_bind *fw_bindlookup (struct firewire_comm *, uint16_t, uint32_t);
void fw_drain_txq (struct firewire_comm *);
int fwdev_makedev (struct firewire_softc *);
int fwdev_destroydev (struct firewire_softc *);
-void fwdev_clone (void *, char *, int, dev_t *);
+void fwdev_clone (void *, char *, int, struct cdev **);
extern int firewire_debug;
extern devclass_t firewire_devclass;
diff --git a/sys/dev/firewire/fwdev.c b/sys/dev/firewire/fwdev.c
index 7cf7dc9..5d10415 100644
--- a/sys/dev/firewire/fwdev.c
+++ b/sys/dev/firewire/fwdev.c
@@ -178,7 +178,7 @@ fwdev_freebuf(struct fw_xferq *q)
static int
-fw_open (dev_t dev, int flags, int fmt, fw_proc *td)
+fw_open (struct cdev *dev, int flags, int fmt, fw_proc *td)
{
int err = 0;
@@ -205,7 +205,7 @@ fw_open (dev_t dev, int flags, int fmt, fw_proc *td)
}
static int
-fw_close (dev_t dev, int flags, int fmt, fw_proc *td)
+fw_close (struct cdev *dev, int flags, int fmt, fw_proc *td)
{
struct firewire_softc *sc;
struct firewire_comm *fc;
@@ -279,7 +279,7 @@ fw_close (dev_t dev, int flags, int fmt, fw_proc *td)
* read request.
*/
static int
-fw_read (dev_t dev, struct uio *uio, int ioflag)
+fw_read (struct cdev *dev, struct uio *uio, int ioflag)
{
struct firewire_softc *sc;
struct fw_xferq *ir;
@@ -365,7 +365,7 @@ readloop:
}
static int
-fw_write (dev_t dev, struct uio *uio, int ioflag)
+fw_write (struct cdev *dev, struct uio *uio, int ioflag)
{
int err = 0;
struct firewire_softc *sc;
@@ -428,7 +428,7 @@ isoloop:
* ioctl support.
*/
int
-fw_ioctl (dev_t dev, u_long cmd, caddr_t data, int flag, fw_proc *td)
+fw_ioctl (struct cdev *dev, u_long cmd, caddr_t data, int flag, fw_proc *td)
{
struct firewire_softc *sc;
struct firewire_comm *fc;
@@ -728,7 +728,7 @@ out:
return err;
}
int
-fw_poll(dev_t dev, int events, fw_proc *td)
+fw_poll(struct cdev *dev, int events, fw_proc *td)
{
struct firewire_softc *sc;
struct fw_xferq *ir;
@@ -760,9 +760,9 @@ fw_poll(dev_t dev, int events, fw_proc *td)
static int
#if defined(__DragonFly__) || __FreeBSD_version < 500102
-fw_mmap (dev_t dev, vm_offset_t offset, int nproto)
+fw_mmap (struct cdev *dev, vm_offset_t offset, int nproto)
#else
-fw_mmap (dev_t dev, vm_offset_t offset, vm_paddr_t *paddr, int nproto)
+fw_mmap (struct cdev *dev, vm_offset_t offset, vm_paddr_t *paddr, int nproto)
#endif
{
struct firewire_softc *sc;
@@ -783,7 +783,7 @@ fw_mmap (dev_t dev, vm_offset_t offset, vm_paddr_t *paddr, int nproto)
static void
fw_strategy(struct bio *bp)
{
- dev_t dev;
+ struct cdev *dev;
dev = bp->bio_dev;
if (DEV_FWMEM(dev)) {
@@ -805,7 +805,7 @@ fwdev_makedev(struct firewire_softc *sc)
#if defined(__DragonFly__) || __FreeBSD_version < 500000
cdevsw_add(&firewire_cdevsw);
#else
- dev_t d;
+ struct cdev *d;
int unit;
unit = device_get_unit(sc->fc->bdev);
@@ -840,7 +840,7 @@ fwdev_destroydev(struct firewire_softc *sc)
#if defined(__FreeBSD__) && __FreeBSD_version >= 500000
#define NDEVTYPE 2
void
-fwdev_clone(void *arg, char *name, int namelen, dev_t *dev)
+fwdev_clone(void *arg, char *name, int namelen, struct cdev **dev)
{
struct firewire_softc *sc;
char *devnames[NDEVTYPE] = {"fw", "fwmem"};
diff --git a/sys/dev/firewire/fwmem.c b/sys/dev/firewire/fwmem.c
index c10a078..a2e81e3 100644
--- a/sys/dev/firewire/fwmem.c
+++ b/sys/dev/firewire/fwmem.c
@@ -274,7 +274,7 @@ fwmem_write_block(
int
-fwmem_open (dev_t dev, int flags, int fmt, fw_proc *td)
+fwmem_open (struct cdev *dev, int flags, int fmt, fw_proc *td)
{
struct fwmem_softc *fms;
@@ -300,7 +300,7 @@ fwmem_open (dev_t dev, int flags, int fmt, fw_proc *td)
}
int
-fwmem_close (dev_t dev, int flags, int fmt, fw_proc *td)
+fwmem_close (struct cdev *dev, int flags, int fmt, fw_proc *td)
{
struct fwmem_softc *fms;
@@ -343,7 +343,7 @@ fwmem_strategy(struct bio *bp)
struct fwmem_softc *fms;
struct fw_device *fwdev;
struct fw_xfer *xfer;
- dev_t dev;
+ struct cdev *dev;
int unit, err=0, s, iolen;
dev = bp->bio_dev;
@@ -406,7 +406,7 @@ error:
}
int
-fwmem_ioctl (dev_t dev, u_long cmd, caddr_t data, int flag, fw_proc *td)
+fwmem_ioctl (struct cdev *dev, u_long cmd, caddr_t data, int flag, fw_proc *td)
{
struct fwmem_softc *fms;
int err = 0;
@@ -425,15 +425,15 @@ fwmem_ioctl (dev_t dev, u_long cmd, caddr_t data, int flag, fw_proc *td)
return(err);
}
int
-fwmem_poll (dev_t dev, int events, fw_proc *td)
+fwmem_poll (struct cdev *dev, int events, fw_proc *td)
{
return EINVAL;
}
int
#if defined(__DragonFly__) || __FreeBSD_version < 500102
-fwmem_mmap (dev_t dev, vm_offset_t offset, int nproto)
+fwmem_mmap (struct cdev *dev, vm_offset_t offset, int nproto)
#else
-fwmem_mmap (dev_t dev, vm_offset_t offset, vm_paddr_t *paddr, int nproto)
+fwmem_mmap (struct cdev *dev, vm_offset_t offset, vm_paddr_t *paddr, int nproto)
#endif
{
return EINVAL;
diff --git a/sys/dev/firewire/fwohci.c b/sys/dev/firewire/fwohci.c
index c6e58c5..6c99909 100644
--- a/sys/dev/firewire/fwohci.c
+++ b/sys/dev/firewire/fwohci.c
@@ -345,7 +345,7 @@ again:
}
/* Device specific ioctl. */
int
-fwohci_ioctl (dev_t dev, u_long cmd, caddr_t data, int flag, fw_proc *td)
+fwohci_ioctl (struct cdev *dev, u_long cmd, caddr_t data, int flag, fw_proc *td)
{
struct firewire_softc *sc;
struct fwohci_softc *fc;
OpenPOWER on IntegriCloud