From 80909a7db8ce8bced9fe84abcd4c44126b9d4b0a Mon Sep 17 00:00:00 2001 From: Joerg Wunsch Date: Wed, 20 Jun 2001 20:21:55 +0000 Subject: Cosmetics: . staticize out_fdc(), there's no longer an ft(4) driver sharing its use . remove in_fdc(), has been used by ft(4) last time, long since obsoleted by fd_in() . move the declaration of fd_clone() to where most of the other function declarations are . de-__P()ify fd_clone(), it's been the only _P()ed function in the entire file --- sys/dev/fdc/fdc.c | 36 +++--------------------------------- 1 file changed, 3 insertions(+), 33 deletions(-) (limited to 'sys/dev/fdc/fdc.c') diff --git a/sys/dev/fdc/fdc.c b/sys/dev/fdc/fdc.c index d29240e69224..21c3d9a5a232 100644 --- a/sys/dev/fdc/fdc.c +++ b/sys/dev/fdc/fdc.c @@ -188,10 +188,6 @@ static devclass_t fd_devclass; * fdsu is the floppy drive unit number on that controller. (sub-unit) * \***********************************************************************/ -/* needed for ft driver, thus exported */ -int in_fdc(struct fdc_data *); -int out_fdc(struct fdc_data *, int); - /* internal functions */ static void fdc_intr(void *); static void set_motor(struct fdc_data *, int, int); @@ -202,6 +198,7 @@ static timeout_t fd_motor_on; static void fd_turnon(struct fd_data *); static void fdc_reset(fdc_p); static int fd_in(struct fdc_data *, int *); +static int out_fdc(struct fdc_data *, int); static void fdstart(struct fdc_data *); static timeout_t fd_iotimeout; static timeout_t fd_pseudointr; @@ -210,6 +207,7 @@ static int retrier(struct fdc_data *); static int fdformat(dev_t, struct fd_formb *, struct proc *); static int enable_fifo(fdc_p fdc); +static void fd_clone (void *arg, char *name, int namelen, dev_t *dev); static int fifo_threshold = 8; /* XXX: should be accessible via sysctl */ @@ -929,8 +927,6 @@ DRIVER_MODULE(fdc, pccard, fdc_pccard_driver, fdc_devclass, 0, 0); #endif /* NCARD > 0 */ -static void fd_clone __P((void *arg, char *name, int namelen, dev_t *dev)); - static struct { char *match; int minor; @@ -957,11 +953,7 @@ static struct { { 0, 0 } }; static void -fd_clone(arg, name, namelen, dev) - void *arg; - char *name; - int namelen; - dev_t *dev; +fd_clone (void *arg, char *name, int namelen, dev_t *dev) { int u, d, i; char *n; @@ -1318,28 +1310,6 @@ fdc_reset(fdc_p fdc) /****************************************************************************/ /* fdc in/out */ /****************************************************************************/ -int -in_fdc(struct fdc_data *fdc) -{ - int i, j = 100000; - while ((i = fdsts_rd(fdc) & (NE7_DIO|NE7_RQM)) - != (NE7_DIO|NE7_RQM) && j-- > 0) - if (i == NE7_RQM) - return fdc_err(fdc, "ready for output in input\n"); - if (j <= 0) - return fdc_err(fdc, bootverbose? "input ready timeout\n": 0); -#ifdef FDC_DEBUG - i = fddata_rd(fdc); - TRACE1("[FDDATA->0x%x]", (unsigned char)i); - return(i); -#else /* !FDC_DEBUG */ - return fddata_rd(fdc); -#endif /* FDC_DEBUG */ -} - -/* - * fd_in: Like in_fdc, but allows you to see if it worked. - */ static int fd_in(struct fdc_data *fdc, int *ptr) { -- cgit v1.2.3