Kill some more extern struct cfdriver declarations.

Down with externs in .c!
This commit is contained in:
riastradh 2017-10-28 04:53:54 +00:00
parent 786714f50f
commit 82b8caba92
52 changed files with 188 additions and 198 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: acpi.c,v 1.263 2017/06/01 02:45:09 chs Exp $ */
/* $NetBSD: acpi.c,v 1.264 2017/10/28 04:53:55 riastradh Exp $ */
/*-
* Copyright (c) 2003, 2007 The NetBSD Foundation, Inc.
@ -100,7 +100,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: acpi.c,v 1.263 2017/06/01 02:45:09 chs Exp $");
__KERNEL_RCSID(0, "$NetBSD: acpi.c,v 1.264 2017/10/28 04:53:55 riastradh Exp $");
#include "opt_acpi.h"
#include "opt_pcifixup.h"
@ -127,6 +127,8 @@ __KERNEL_RCSID(0, "$NetBSD: acpi.c,v 1.263 2017/06/01 02:45:09 chs Exp $");
#include <machine/acpi_machdep.h>
#include "ioconf.h"
#define _COMPONENT ACPI_BUS_COMPONENT
ACPI_MODULE_NAME ("acpi")
@ -143,7 +145,6 @@ int acpi_verbose_loaded = 0;
struct acpi_softc *acpi_softc = NULL;
static uint64_t acpi_root_pointer;
extern kmutex_t acpi_interrupt_list_mtx;
extern struct cfdriver acpi_cd;
static ACPI_HANDLE acpi_scopes[4];
ACPI_TABLE_HEADER *madt_header;

View File

@ -1,4 +1,4 @@
/* $NetBSD: pckbc_acpi.c,v 1.35 2016/10/18 22:08:30 jdolecek Exp $ */
/* $NetBSD: pckbc_acpi.c,v 1.36 2017/10/28 04:53:55 riastradh Exp $ */
/*-
* Copyright (c) 2000 The NetBSD Foundation, Inc.
@ -42,7 +42,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: pckbc_acpi.c,v 1.35 2016/10/18 22:08:30 jdolecek Exp $");
__KERNEL_RCSID(0, "$NetBSD: pckbc_acpi.c,v 1.36 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/callout.h>
@ -57,6 +57,8 @@ __KERNEL_RCSID(0, "$NetBSD: pckbc_acpi.c,v 1.35 2016/10/18 22:08:30 jdolecek Exp
#include <dev/ic/i8042reg.h>
#include <dev/ic/pckbcvar.h>
#include "ioconf.h"
static int pckbc_acpi_match(device_t, cfdata_t, void *);
static void pckbc_acpi_attach(device_t, device_t, void *);
@ -72,8 +74,6 @@ struct pckbc_acpi_softc {
/* Save first port: */
static struct pckbc_acpi_softc *first;
extern struct cfdriver pckbc_cd;
CFATTACH_DECL_NEW(pckbc_acpi, sizeof(struct pckbc_acpi_softc),
pckbc_acpi_match, pckbc_acpi_attach, NULL, NULL);

View File

@ -1,4 +1,4 @@
/* $NetBSD: tpm_acpi.c,v 1.4 2014/03/01 16:59:41 maxv Exp $ */
/* $NetBSD: tpm_acpi.c,v 1.5 2017/10/28 04:53:55 riastradh Exp $ */
/*-
* Copyright (c) 2012 The NetBSD Foundation, Inc.
@ -52,7 +52,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: tpm_acpi.c,v 1.4 2014/03/01 16:59:41 maxv Exp $");
__KERNEL_RCSID(0, "$NetBSD: tpm_acpi.c,v 1.5 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/device.h>
@ -69,6 +69,8 @@ __KERNEL_RCSID(0, "$NetBSD: tpm_acpi.c,v 1.4 2014/03/01 16:59:41 maxv Exp $");
#include <dev/isa/isavar.h>
#include "ioconf.h"
#define _COMPONENT ACPI_RESOURCE_COMPONENT
ACPI_MODULE_NAME ("tpm_acpi")
@ -89,8 +91,6 @@ static const char * const tpm_acpi_ids[] = {
NULL
};
extern struct cfdriver tpm_cd;
static int
tpm_acpi_match(device_t parent, cfdata_t match, void *aux)
{

View File

@ -1,4 +1,4 @@
/* $NetBSD: adb_bt.c,v 1.6 2010/09/08 04:48:03 macallan Exp $ */
/* $NetBSD: adb_bt.c,v 1.7 2017/10/28 04:53:55 riastradh Exp $ */
/*-
* Copyright (c) 2006 Michael Lorenz
@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: adb_bt.c,v 1.6 2010/09/08 04:48:03 macallan Exp $");
__KERNEL_RCSID(0, "$NetBSD: adb_bt.c,v 1.7 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -41,6 +41,8 @@ __KERNEL_RCSID(0, "$NetBSD: adb_bt.c,v 1.6 2010/09/08 04:48:03 macallan Exp $");
#include <dev/adb/adbvar.h>
#include "ioconf.h"
#include "opt_wsdisplay_compat.h"
#include "adbdebug.h"
@ -76,8 +78,6 @@ struct adbbt_softc {
CFATTACH_DECL_NEW(adbbt, sizeof(struct adbbt_softc),
adbbt_match, adbbt_attach, NULL, NULL);
extern struct cfdriver adbbt_cd;
static void adbbt_handler(void *, int, uint8_t *);
static int

View File

@ -1,4 +1,4 @@
/* $NetBSD: adb_kbd.c,v 1.26 2015/07/29 08:45:28 christos Exp $ */
/* $NetBSD: adb_kbd.c,v 1.27 2017/10/28 04:53:55 riastradh Exp $ */
/*
* Copyright (C) 1998 Colin Wood
@ -32,7 +32,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: adb_kbd.c,v 1.26 2015/07/29 08:45:28 christos Exp $");
__KERNEL_RCSID(0, "$NetBSD: adb_kbd.c,v 1.27 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/device.h>
@ -60,6 +60,8 @@ __KERNEL_RCSID(0, "$NetBSD: adb_kbd.c,v 1.26 2015/07/29 08:45:28 christos Exp $"
#include <dev/adb/adbvar.h>
#include <dev/adb/adb_keymap.h>
#include "ioconf.h"
#include "opt_wsdisplay_compat.h"
#include "opt_adbkbd.h"
#include "adbdebug.h"
@ -111,8 +113,6 @@ static int adbkbd_wait(struct adbkbd_softc *, int);
CFATTACH_DECL_NEW(adbkbd, sizeof(struct adbkbd_softc),
adbkbd_match, adbkbd_attach, NULL, NULL);
extern struct cfdriver adbkbd_cd;
static int adbkbd_enable(void *, int);
static int adbkbd_ioctl(void *, u_long, void *, int, struct lwp *);
static void adbkbd_set_leds(void *, int);

View File

@ -1,4 +1,4 @@
/* $NetBSD: altmem.c,v 1.5 2015/04/26 15:15:20 mlelstv Exp $ */
/* $NetBSD: altmem.c,v 1.6 2017/10/28 04:53:55 riastradh Exp $ */
/*-
* Copyright (c) 2009 Jared D. McNeill <jmcneill@invisible.ca>
@ -26,7 +26,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: altmem.c,v 1.5 2015/04/26 15:15:20 mlelstv Exp $");
__KERNEL_RCSID(0, "$NetBSD: altmem.c,v 1.6 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/types.h>
#include <sys/device.h>
@ -37,6 +37,8 @@ __KERNEL_RCSID(0, "$NetBSD: altmem.c,v 1.5 2015/04/26 15:15:20 mlelstv Exp $");
#include <dev/altmem/altmemvar.h>
#include "ioconf.h"
struct altmem_softc {
device_t sc_dev;
@ -87,7 +89,6 @@ static struct dkdriver altmemdkdriver = {
.d_strategy = altmemstrategy,
.d_minphys = minphys
};
extern struct cfdriver altmem_cd;
CFATTACH_DECL_NEW(altmem, sizeof(struct altmem_softc), altmem_match,
altmem_attach, NULL, NULL);

View File

@ -1,4 +1,4 @@
/* $NetBSD: apm.c,v 1.32 2017/10/25 08:12:38 maya Exp $ */
/* $NetBSD: apm.c,v 1.33 2017/10/28 04:53:54 riastradh Exp $ */
/*-
* Copyright (c) 1996, 1997 The NetBSD Foundation, Inc.
@ -33,7 +33,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: apm.c,v 1.32 2017/10/25 08:12:38 maya Exp $");
__KERNEL_RCSID(0, "$NetBSD: apm.c,v 1.33 2017/10/28 04:53:54 riastradh Exp $");
#include "opt_apm.h"
@ -57,6 +57,8 @@ __KERNEL_RCSID(0, "$NetBSD: apm.c,v 1.32 2017/10/25 08:12:38 maya Exp $");
#include <dev/apm/apmvar.h>
#include "ioconf.h"
#ifdef APMDEBUG
#define DPRINTF(f, x) do { if (apmdebug & (f)) printf x; } while (0)
@ -105,8 +107,6 @@ static void apm_standby(struct apm_softc *);
static void apm_suspend(struct apm_softc *);
static void apm_resume(struct apm_softc *, u_int, u_int);
extern struct cfdriver apm_cd;
dev_type_open(apmopen);
dev_type_close(apmclose);
dev_type_ioctl(apmioctl);

View File

@ -1,4 +1,4 @@
/* $NetBSD: ata.c,v 1.140 2017/10/20 07:06:07 jdolecek Exp $ */
/* $NetBSD: ata.c,v 1.141 2017/10/28 04:53:54 riastradh Exp $ */
/*
* Copyright (c) 1998, 2001 Manuel Bouyer. All rights reserved.
@ -25,7 +25,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: ata.c,v 1.140 2017/10/20 07:06:07 jdolecek Exp $");
__KERNEL_RCSID(0, "$NetBSD: ata.c,v 1.141 2017/10/28 04:53:54 riastradh Exp $");
#include "opt_ata.h"
@ -53,6 +53,7 @@ __KERNEL_RCSID(0, "$NetBSD: ata.c,v 1.140 2017/10/20 07:06:07 jdolecek Exp $");
#include <dev/ata/atavar.h>
#include <dev/ic/wdcvar.h> /* for PIOBM */
#include "ioconf.h"
#include "locators.h"
#include "atapibus.h"
@ -121,8 +122,6 @@ const struct cdevsw atabus_cdevsw = {
.d_flag = D_OTHER
};
extern struct cfdriver atabus_cd;
static void atabus_childdetached(device_t, device_t);
static int atabus_rescan(device_t, const char *, const int *);
static bool atabus_resume(device_t, const pmf_qual_t *);

View File

@ -1,4 +1,4 @@
/* $NetBSD: vsxxx.c,v 1.11 2009/03/14 21:04:19 dsl Exp $ */
/* $NetBSD: vsxxx.c,v 1.12 2017/10/28 04:53:54 riastradh Exp $ */
/*-
* Copyright (c) 1999 The NetBSD Foundation, Inc.
@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: vsxxx.c,v 1.11 2009/03/14 21:04:19 dsl Exp $");
__KERNEL_RCSID(0, "$NetBSD: vsxxx.c,v 1.12 2017/10/28 04:53:54 riastradh Exp $");
/*
* Common machinary for VSXXX mice and tablet
@ -45,6 +45,8 @@ __KERNEL_RCSID(0, "$NetBSD: vsxxx.c,v 1.11 2009/03/14 21:04:19 dsl Exp $");
#include <dev/dec/vsxxxvar.h>
#include "ioconf.h"
/*
* XXX XXX XXX
*
@ -73,8 +75,6 @@ __KERNEL_RCSID(0, "$NetBSD: vsxxx.c,v 1.11 2009/03/14 21:04:19 dsl Exp $");
#define VS_MOUSE 0x2
#define VS_TABLET 0x4
extern struct cfdriver vsms_cd;
static int vsxxx_enable(void *);
static int vsxxx_ioctl(void *, u_long, void *, int, struct proc *);
static void vsxxx_disable(void *);

View File

@ -1,4 +1,4 @@
/* $NetBSD: device-mapper.c,v 1.38 2016/07/11 11:31:50 msaitoh Exp $ */
/* $NetBSD: device-mapper.c,v 1.39 2017/10/28 04:53:55 riastradh Exp $ */
/*
* Copyright (c) 2010 The NetBSD Foundation, Inc.
@ -111,8 +111,6 @@ CFATTACH_DECL3_NEW(dm, 0,
dm_match, dm_attach, dm_detach, NULL, NULL, NULL,
DVF_DETACH_SHUTDOWN);
extern struct cfdriver dm_cd;
extern uint32_t dm_dev_counter;
/*

View File

@ -1,4 +1,4 @@
/* $NetBSD: dtv_device.c,v 1.11 2014/08/09 13:34:10 jmcneill Exp $ */
/* $NetBSD: dtv_device.c,v 1.12 2017/10/28 04:53:55 riastradh Exp $ */
/*-
* Copyright (c) 2011 Jared D. McNeill <jmcneill@invisible.ca>
@ -33,7 +33,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: dtv_device.c,v 1.11 2014/08/09 13:34:10 jmcneill Exp $");
__KERNEL_RCSID(0, "$NetBSD: dtv_device.c,v 1.12 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/types.h>
#include <sys/conf.h>
@ -45,6 +45,8 @@ __KERNEL_RCSID(0, "$NetBSD: dtv_device.c,v 1.11 2014/08/09 13:34:10 jmcneill Exp
#include <dev/dtv/dtvvar.h>
#include "ioconf.h"
MODULE(MODULE_CLASS_DRIVER, dtv, NULL);
static dev_type_open(dtvopen);
@ -80,8 +82,6 @@ CFATTACH_DECL_NEW(dtv,
NULL
);
extern struct cfdriver dtv_cd;
static int
dtv_match(device_t parent, cfdata_t cfdata, void *aa)
{

View File

@ -1,4 +1,4 @@
/* $NetBSD: flash.c,v 1.12 2014/07/25 08:10:36 dholland Exp $ */
/* $NetBSD: flash.c,v 1.13 2017/10/28 04:53:55 riastradh Exp $ */
/*-
* Copyright (c) 2011 Department of Software Engineering,
@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: flash.c,v 1.12 2014/07/25 08:10:36 dholland Exp $");
__KERNEL_RCSID(0, "$NetBSD: flash.c,v 1.13 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/types.h>
@ -58,6 +58,8 @@ __KERNEL_RCSID(0, "$NetBSD: flash.c,v 1.12 2014/07/25 08:10:36 dholland Exp $");
#include <sys/malloc.h>
#include <sys/reboot.h>
#include "ioconf.h"
#include <sys/flashio.h>
#include "flash.h"
@ -65,8 +67,6 @@ __KERNEL_RCSID(0, "$NetBSD: flash.c,v 1.12 2014/07/25 08:10:36 dholland Exp $");
int flashdebug = FLASH_DEBUG;
#endif
extern struct cfdriver flash_cd;
dev_type_open(flashopen);
dev_type_close(flashclose);
dev_type_read(flashread);

View File

@ -1,4 +1,4 @@
/* $NetBSD: ct.c,v 1.28 2016/07/11 11:31:50 msaitoh Exp $ */
/* $NetBSD: ct.c,v 1.29 2017/10/28 04:53:56 riastradh Exp $ */
/*-
* Copyright (c) 1996-2003 The NetBSD Foundation, Inc.
@ -82,7 +82,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: ct.c,v 1.28 2016/07/11 11:31:50 msaitoh Exp $");
__KERNEL_RCSID(0, "$NetBSD: ct.c,v 1.29 2017/10/28 04:53:56 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -100,6 +100,8 @@ __KERNEL_RCSID(0, "$NetBSD: ct.c,v 1.28 2016/07/11 11:31:50 msaitoh Exp $");
#include <dev/gpib/gpibvar.h>
#include <dev/gpib/cs80busvar.h>
#include "ioconf.h"
/* number of eof marks to remember */
#define EOFS 128
@ -206,8 +208,6 @@ const struct cdevsw ct_cdevsw = {
.d_flag = D_TAPE
};
extern struct cfdriver ct_cd;
struct ctinfo {
short hwid;
short punit;

View File

@ -1,4 +1,4 @@
/* $NetBSD: mt.c,v 1.30 2016/07/14 04:00:45 msaitoh Exp $ */
/* $NetBSD: mt.c,v 1.31 2017/10/28 04:53:56 riastradh Exp $ */
/*-
* Copyright (c) 1996-2003 The NetBSD Foundation, Inc.
@ -75,7 +75,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: mt.c,v 1.30 2016/07/14 04:00:45 msaitoh Exp $");
__KERNEL_RCSID(0, "$NetBSD: mt.c,v 1.31 2017/10/28 04:53:56 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -97,6 +97,8 @@ __KERNEL_RCSID(0, "$NetBSD: mt.c,v 1.30 2016/07/14 04:00:45 msaitoh Exp $");
#include <dev/gpib/mtreg.h>
#include "ioconf.h"
#ifdef DEBUG
int mtdebug = 0;
#define MDB_ANY 0xff
@ -187,8 +189,6 @@ const struct cdevsw mt_cdevsw = {
};
extern struct cfdriver mt_cd;
struct mtinfo {
u_short hwid;
const char *desc;

View File

@ -1,4 +1,4 @@
/* $NetBSD: ppi.c,v 1.22 2014/07/25 08:10:36 dholland Exp $ */
/* $NetBSD: ppi.c,v 1.23 2017/10/28 04:53:56 riastradh Exp $ */
/*-
* Copyright (c) 1996-2003 The NetBSD Foundation, Inc.
@ -65,7 +65,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: ppi.c,v 1.22 2014/07/25 08:10:36 dholland Exp $");
__KERNEL_RCSID(0, "$NetBSD: ppi.c,v 1.23 2017/10/28 04:53:56 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -80,6 +80,8 @@ __KERNEL_RCSID(0, "$NetBSD: ppi.c,v 1.22 2014/07/25 08:10:36 dholland Exp $");
#include <dev/gpib/ppiio.h>
#include "ioconf.h"
struct ppi_softc {
device_t sc_dev;
gpib_chipset_tag_t sc_ic;
@ -109,8 +111,6 @@ void ppiattach(device_t, device_t, void *);
CFATTACH_DECL_NEW(ppi, sizeof(struct ppi_softc),
ppimatch, ppiattach, NULL, NULL);
extern struct cfdriver ppi_cd;
void ppicallback(void *, int);
void ppistart(void *);

View File

@ -1,4 +1,4 @@
/* $NetBSD: rd.c,v 1.41 2016/07/11 11:31:50 msaitoh Exp $ */
/* $NetBSD: rd.c,v 1.42 2017/10/28 04:53:56 riastradh Exp $ */
/*-
* Copyright (c) 1996-2003 The NetBSD Foundation, Inc.
@ -72,7 +72,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: rd.c,v 1.41 2016/07/11 11:31:50 msaitoh Exp $");
__KERNEL_RCSID(0, "$NetBSD: rd.c,v 1.42 2017/10/28 04:53:56 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -96,6 +96,8 @@ __KERNEL_RCSID(0, "$NetBSD: rd.c,v 1.41 2016/07/11 11:31:50 msaitoh Exp $");
#include <dev/gpib/rdreg.h>
#include "ioconf.h"
#ifdef DEBUG
int rddebug = 0xff;
#define RDB_FOLLOW 0x01
@ -280,8 +282,6 @@ const struct cdevsw rd_cdevsw = {
.d_flag = D_DISK
};
extern struct cfdriver rd_cd;
int
rdlookup(int id, int slave, int punit)
{

View File

@ -1,4 +1,4 @@
/* $NetBSD: gpio.c,v 1.59 2017/07/06 10:43:06 jmcneill Exp $ */
/* $NetBSD: gpio.c,v 1.60 2017/10/28 04:53:56 riastradh Exp $ */
/* $OpenBSD: gpio.c,v 1.6 2006/01/14 12:33:49 grange Exp $ */
/*
@ -19,7 +19,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: gpio.c,v 1.59 2017/07/06 10:43:06 jmcneill Exp $");
__KERNEL_RCSID(0, "$NetBSD: gpio.c,v 1.60 2017/10/28 04:53:56 riastradh Exp $");
/*
* General Purpose Input/Output framework.
@ -43,6 +43,7 @@ __KERNEL_RCSID(0, "$NetBSD: gpio.c,v 1.59 2017/07/06 10:43:06 jmcneill Exp $");
#include <sys/module.h>
#include <dev/gpio/gpiovar.h>
#include "ioconf.h"
#include "locators.h"
#ifdef GPIO_DEBUG
@ -114,8 +115,6 @@ const struct cdevsw gpio_cdevsw = {
.d_flag = D_OTHER | D_MPSAFE
};
extern struct cfdriver gpio_cd;
static int
gpio_match(device_t parent, cfdata_t cf, void *aux)
{

View File

@ -1,4 +1,4 @@
/* $NetBSD: gpioiic.c,v 1.7 2015/09/01 19:25:32 phx Exp $ */
/* $NetBSD: gpioiic.c,v 1.8 2017/10/28 04:53:56 riastradh Exp $ */
/* $OpenBSD: gpioiic.c,v 1.8 2008/11/24 12:12:12 mbalmer Exp $ */
/*
@ -18,7 +18,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: gpioiic.c,v 1.7 2015/09/01 19:25:32 phx Exp $");
__KERNEL_RCSID(0, "$NetBSD: gpioiic.c,v 1.8 2017/10/28 04:53:56 riastradh Exp $");
/*
* I2C bus bit-banging through GPIO pins.
@ -36,6 +36,8 @@ __KERNEL_RCSID(0, "$NetBSD: gpioiic.c,v 1.7 2015/09/01 19:25:32 phx Exp $");
#include <dev/i2c/i2cvar.h>
#include <dev/i2c/i2c_bitbang.h>
#include "ioconf.h"
#define GPIOIIC_PIN_SDA 0
#define GPIOIIC_PIN_SCL 1
#define GPIOIIC_NPINS 2
@ -80,8 +82,6 @@ uint32_t gpioiic_bb_read_bits(void *);
CFATTACH_DECL_NEW(gpioiic, sizeof(struct gpioiic_softc),
gpioiic_match, gpioiic_attach, gpioiic_detach, NULL);
extern struct cfdriver gpioiic_cd;
static const struct i2c_bitbang_ops gpioiic_bbops = {
gpioiic_bb_set_bits,
gpioiic_bb_set_dir,

View File

@ -1,4 +1,4 @@
/* $NetBSD: gpiolock.c,v 1.4 2017/01/20 12:25:07 maya Exp $ */
/* $NetBSD: gpiolock.c,v 1.5 2017/10/28 04:53:56 riastradh Exp $ */
/*
* Copyright (c) 2009 Marc Balmer <marc@msys.ch>
@ -38,6 +38,8 @@
#include <dev/gpio/gpiovar.h>
#include <dev/keylock.h>
#include "ioconf.h"
#define GPIOLOCK_MAXPINS 4
#define GPIOLOCK_MINPINS 2
@ -60,8 +62,6 @@ int gpiolock_position(void *);
CFATTACH_DECL_NEW(gpiolock, sizeof(struct gpiolock_softc),
gpiolock_match, gpiolock_attach, gpiolock_detach, gpiolock_activate);
extern struct cfdriver gpiolock_cd;
int
gpiolock_match(device_t parent, cfdata_t cf,
void *aux)

View File

@ -1,4 +1,4 @@
/* $NetBSD: gpioow.c,v 1.14 2011/09/07 07:43:05 mbalmer Exp $ */
/* $NetBSD: gpioow.c,v 1.15 2017/10/28 04:53:56 riastradh Exp $ */
/* $OpenBSD: gpioow.c,v 1.1 2006/03/04 16:27:03 grange Exp $ */
/*
@ -18,7 +18,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: gpioow.c,v 1.14 2011/09/07 07:43:05 mbalmer Exp $");
__KERNEL_RCSID(0, "$NetBSD: gpioow.c,v 1.15 2017/10/28 04:53:56 riastradh Exp $");
/*
* 1-Wire bus bit-banging through GPIO pin.
@ -34,6 +34,8 @@ __KERNEL_RCSID(0, "$NetBSD: gpioow.c,v 1.14 2011/09/07 07:43:05 mbalmer Exp $");
#include <dev/onewire/onewirevar.h>
#include "ioconf.h"
#define GPIOOW_NPINS 1
#define GPIOOW_PIN_DATA 0
@ -65,8 +67,6 @@ void gpioow_bb_set(void *, int);
CFATTACH_DECL_NEW(gpioow, sizeof(struct gpioow_softc),
gpioow_match, gpioow_attach, gpioow_detach, gpioow_activate);
extern struct cfdriver gpioow_cd;
static const struct onewire_bbops gpioow_bbops = {
gpioow_bb_rx,
gpioow_bb_tx,

View File

@ -1,4 +1,4 @@
/* $NetBSD: gpiopwm.c,v 1.6 2017/01/20 12:25:07 maya Exp $ */
/* $NetBSD: gpiopwm.c,v 1.7 2017/10/28 04:53:56 riastradh Exp $ */
/*
* Copyright (c) 2011 Marc Balmer <marc@msys.ch>
@ -36,6 +36,8 @@
#include <dev/gpio/gpiovar.h>
#include "ioconf.h"
#define GPIOPWM_NPINS 1
struct gpiopwm_softc {
@ -63,8 +65,6 @@ static void gpiopwm_pulse(void *);
CFATTACH_DECL_NEW(gpiopwm, sizeof(struct gpiopwm_softc),
gpiopwm_match, gpiopwm_attach, gpiopwm_detach, gpiopwm_activate);
extern struct cfdriver gpiopwm_cd;
int
gpiopwm_match(device_t parent, cfdata_t cf,
void *aux)

View File

@ -1,4 +1,4 @@
/* $NetBSD: gpiosim.c,v 1.20 2017/01/20 12:25:07 maya Exp $ */
/* $NetBSD: gpiosim.c,v 1.21 2017/10/28 04:53:56 riastradh Exp $ */
/* $OpenBSD: gpiosim.c,v 1.1 2008/11/23 18:46:49 mbalmer Exp $ */
/*
@ -57,8 +57,6 @@ static void gpiosim_pin_ctl(void *, int, int);
CFATTACH_DECL_NEW(gpiosim, sizeof(struct gpiosim_softc), gpiosim_match,
gpiosim_attach, gpiosim_detach, NULL);
extern struct cfdriver gpiosim_cd;
static int
gpiosim_match(device_t parent, cfdata_t match, void *aux)
{

View File

@ -1,4 +1,4 @@
/* $NetBSD: hdmicec.c,v 1.1 2015/08/01 21:19:24 jmcneill Exp $ */
/* $NetBSD: hdmicec.c,v 1.2 2017/10/28 04:53:56 riastradh Exp $ */
/*-
* Copyright (c) 2015 Jared D. McNeill <jmcneill@invisible.ca>
@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: hdmicec.c,v 1.1 2015/08/01 21:19:24 jmcneill Exp $");
__KERNEL_RCSID(0, "$NetBSD: hdmicec.c,v 1.2 2017/10/28 04:53:56 riastradh Exp $");
#include <sys/param.h>
#include <sys/types.h>
@ -40,6 +40,8 @@ __KERNEL_RCSID(0, "$NetBSD: hdmicec.c,v 1.1 2015/08/01 21:19:24 jmcneill Exp $")
#include <dev/hdmicec/hdmicec_if.h>
#include <dev/hdmicec/hdmicecio.h>
#include "ioconf.h"
#define CEC_MAX_FRAMESIZE 16
struct hdmicec_softc {
@ -75,8 +77,6 @@ const struct cdevsw hdmicec_cdevsw = {
.d_flag = D_MPSAFE
};
extern struct cfdriver hdmicec_cd;
CFATTACH_DECL_NEW(hdmicec, sizeof(struct hdmicec_softc), hdmicec_match,
hdmicec_attach, NULL, NULL);

View File

@ -1,4 +1,4 @@
/* $NetBSD: hpcapm.c,v 1.21 2017/06/25 12:21:00 maxv Exp $ */
/* $NetBSD: hpcapm.c,v 1.22 2017/10/28 04:53:56 riastradh Exp $ */
/*
* Copyright (c) 2000 Takemura Shin
@ -29,7 +29,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: hpcapm.c,v 1.21 2017/06/25 12:21:00 maxv Exp $");
__KERNEL_RCSID(0, "$NetBSD: hpcapm.c,v 1.22 2017/10/28 04:53:56 riastradh Exp $");
#ifdef _KERNEL_OPT
#include "opt_hpcapm.h"
@ -48,6 +48,8 @@ __KERNEL_RCSID(0, "$NetBSD: hpcapm.c,v 1.21 2017/06/25 12:21:00 maxv Exp $");
#include <machine/platid.h>
#include <machine/platid_mask.h>
#include "ioconf.h"
#ifdef HPCAPMDEBUG
#ifndef HPCAPMDEBUG_CONF
#define HPCAPMDEBUG_CONF 1
@ -102,8 +104,6 @@ struct apm_accessops hpcapm_accessops = {
hpcapm_get_capabilities,
};
extern struct cfdriver hpcapm_cd;
static int
hpcapm_match(device_t parent, cfdata_t cf, void *aux)
{

View File

@ -1,4 +1,4 @@
/* $NetBSD: hpf1275a_tty.c,v 1.28 2017/08/02 00:58:18 uwe Exp $ */
/* $NetBSD: hpf1275a_tty.c,v 1.29 2017/10/28 04:53:56 riastradh Exp $ */
/*
* Copyright (c) 2004 Valeriy E. Ushakov
@ -28,7 +28,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: hpf1275a_tty.c,v 1.28 2017/08/02 00:58:18 uwe Exp $");
__KERNEL_RCSID(0, "$NetBSD: hpf1275a_tty.c,v 1.29 2017/10/28 04:53:56 riastradh Exp $");
#include "opt_wsdisplay_compat.h"
@ -52,8 +52,7 @@ __KERNEL_RCSID(0, "$NetBSD: hpf1275a_tty.c,v 1.28 2017/08/02 00:58:18 uwe Exp $"
#include <dev/hpc/pckbd_encode.h>
#endif
extern struct cfdriver hpf1275a_cd;
#include "ioconf.h"
struct hpf1275a_softc {
device_t sc_dev;

View File

@ -1,4 +1,4 @@
/* $NetBSD: at24cxx.c,v 1.24 2017/10/21 03:17:09 jmcneill Exp $ */
/* $NetBSD: at24cxx.c,v 1.25 2017/10/28 04:53:55 riastradh Exp $ */
/*
* Copyright (c) 2003 Wasabi Systems, Inc.
@ -36,7 +36,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: at24cxx.c,v 1.24 2017/10/21 03:17:09 jmcneill Exp $");
__KERNEL_RCSID(0, "$NetBSD: at24cxx.c,v 1.25 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -53,6 +53,8 @@ __KERNEL_RCSID(0, "$NetBSD: at24cxx.c,v 1.24 2017/10/21 03:17:09 jmcneill Exp $"
#include <dev/i2c/i2cvar.h>
#include <dev/i2c/at24cxxvar.h>
#include "ioconf.h"
/*
* AT24Cxx EEPROM I2C address:
* 101 0xxx
@ -86,7 +88,6 @@ static void seeprom_attach(device_t, device_t, void *);
CFATTACH_DECL_NEW(seeprom, sizeof(struct seeprom_softc),
seeprom_match, seeprom_attach, NULL, NULL);
extern struct cfdriver seeprom_cd;
dev_type_open(seeprom_open);
dev_type_close(seeprom_close);

View File

@ -1,4 +1,4 @@
/* $NetBSD: ds1307.c,v 1.24 2016/10/18 18:54:54 aymeric Exp $ */
/* $NetBSD: ds1307.c,v 1.25 2017/10/28 04:53:55 riastradh Exp $ */
/*
* Copyright (c) 2003 Wasabi Systems, Inc.
@ -36,7 +36,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: ds1307.c,v 1.24 2016/10/18 18:54:54 aymeric Exp $");
__KERNEL_RCSID(0, "$NetBSD: ds1307.c,v 1.25 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -53,6 +53,8 @@ __KERNEL_RCSID(0, "$NetBSD: ds1307.c,v 1.24 2016/10/18 18:54:54 aymeric Exp $");
#include <dev/i2c/ds1307reg.h>
#include <dev/sysmon/sysmonvar.h>
#include "ioconf.h"
struct dsrtc_model {
uint16_t dm_model;
uint8_t dm_ch_reg;
@ -150,7 +152,6 @@ static int dsrtc_match(device_t, cfdata_t, void *);
CFATTACH_DECL_NEW(dsrtc, sizeof(struct dsrtc_softc),
dsrtc_match, dsrtc_attach, NULL, NULL);
extern struct cfdriver dsrtc_cd;
dev_type_open(dsrtc_open);
dev_type_close(dsrtc_close);

View File

@ -1,4 +1,4 @@
/* $NetBSD: i2c.c,v 1.55 2017/06/01 02:45:10 chs Exp $ */
/* $NetBSD: i2c.c,v 1.56 2017/10/28 04:53:55 riastradh Exp $ */
/*
* Copyright (c) 2003 Wasabi Systems, Inc.
@ -40,7 +40,7 @@
#endif
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: i2c.c,v 1.55 2017/06/01 02:45:10 chs Exp $");
__KERNEL_RCSID(0, "$NetBSD: i2c.c,v 1.56 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -59,6 +59,7 @@ __KERNEL_RCSID(0, "$NetBSD: i2c.c,v 1.55 2017/06/01 02:45:10 chs Exp $");
#include <dev/i2c/i2cvar.h>
#include "ioconf.h"
#include "locators.h"
#ifndef I2C_MAX_ADDR
@ -97,8 +98,6 @@ const struct cdevsw iic_cdevsw = {
.d_flag = D_OTHER
};
extern struct cfdriver iic_cd;
static void iic_smbus_intr_thread(void *);
static void iic_fill_compat(struct i2c_attach_args*, const char*,
size_t, char **);

View File

@ -1,4 +1,4 @@
/* $NetBSD: m41st84.c,v 1.22 2014/11/20 16:34:26 christos Exp $ */
/* $NetBSD: m41st84.c,v 1.23 2017/10/28 04:53:55 riastradh Exp $ */
/*
* Copyright (c) 2003 Wasabi Systems, Inc.
@ -36,7 +36,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: m41st84.c,v 1.22 2014/11/20 16:34:26 christos Exp $");
__KERNEL_RCSID(0, "$NetBSD: m41st84.c,v 1.23 2017/10/28 04:53:55 riastradh Exp $");
#include "opt_strtc.h"
@ -55,6 +55,8 @@ __KERNEL_RCSID(0, "$NetBSD: m41st84.c,v 1.22 2014/11/20 16:34:26 christos Exp $"
#include <dev/i2c/m41st84reg.h>
#include <dev/i2c/m41st84var.h>
#include "ioconf.h"
struct strtc_softc {
device_t sc_dev;
i2c_tag_t sc_tag;
@ -70,8 +72,6 @@ CFATTACH_DECL_NEW(strtc, sizeof(struct strtc_softc),
strtc_match, strtc_attach, NULL, NULL);
#ifndef STRTC_NO_USERRAM
extern struct cfdriver strtc_cd;
dev_type_open(strtc_open);
dev_type_close(strtc_close);
dev_type_read(strtc_read);

View File

@ -1,4 +1,4 @@
/* $NetBSD: m41t00.c,v 1.19 2014/11/20 16:34:26 christos Exp $ */
/* $NetBSD: m41t00.c,v 1.20 2017/10/28 04:53:55 riastradh Exp $ */
/*
* Copyright (c) 2003 Wasabi Systems, Inc.
@ -36,7 +36,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: m41t00.c,v 1.19 2014/11/20 16:34:26 christos Exp $");
__KERNEL_RCSID(0, "$NetBSD: m41t00.c,v 1.20 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -55,6 +55,8 @@ __KERNEL_RCSID(0, "$NetBSD: m41t00.c,v 1.19 2014/11/20 16:34:26 christos Exp $")
#include <dev/i2c/i2cvar.h>
#include <dev/i2c/m41t00reg.h>
#include "ioconf.h"
struct m41t00_softc {
device_t sc_dev;
i2c_tag_t sc_tag;
@ -68,7 +70,6 @@ static void m41t00_attach(device_t, device_t, void *);
CFATTACH_DECL_NEW(m41trtc, sizeof(struct m41t00_softc),
m41t00_match, m41t00_attach, NULL, NULL);
extern struct cfdriver m41trtc_cd;
dev_type_open(m41t00_open);
dev_type_close(m41t00_close);

View File

@ -1,4 +1,4 @@
/* $NetBSD: pcf8583.c,v 1.16 2014/11/20 16:34:26 christos Exp $ */
/* $NetBSD: pcf8583.c,v 1.17 2017/10/28 04:53:55 riastradh Exp $ */
/*
* Copyright (c) 2003 Wasabi Systems, Inc.
@ -43,7 +43,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: pcf8583.c,v 1.16 2014/11/20 16:34:26 christos Exp $");
__KERNEL_RCSID(0, "$NetBSD: pcf8583.c,v 1.17 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -60,6 +60,8 @@ __KERNEL_RCSID(0, "$NetBSD: pcf8583.c,v 1.16 2014/11/20 16:34:26 christos Exp $"
#include <dev/i2c/pcf8583reg.h>
#include <dev/i2c/pcf8583var.h>
#include "ioconf.h"
struct pcfrtc_softc {
device_t sc_dev;
i2c_tag_t sc_tag;
@ -73,7 +75,6 @@ static void pcfrtc_attach(device_t, device_t, void *);
CFATTACH_DECL_NEW(pcfrtc, sizeof(struct pcfrtc_softc),
pcfrtc_match, pcfrtc_attach, NULL, NULL);
extern struct cfdriver pcfrtc_cd;
dev_type_open(pcfrtc_open);
dev_type_close(pcfrtc_close);

View File

@ -1,4 +1,4 @@
/* $NetBSD: x1226.c,v 1.19 2014/11/20 16:34:26 christos Exp $ */
/* $NetBSD: x1226.c,v 1.20 2017/10/28 04:53:55 riastradh Exp $ */
/*
* Copyright (c) 2003 Shigeyuki Fukushima.
@ -36,7 +36,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: x1226.c,v 1.19 2014/11/20 16:34:26 christos Exp $");
__KERNEL_RCSID(0, "$NetBSD: x1226.c,v 1.20 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -52,6 +52,8 @@ __KERNEL_RCSID(0, "$NetBSD: x1226.c,v 1.19 2014/11/20 16:34:26 christos Exp $");
#include <dev/i2c/i2cvar.h>
#include <dev/i2c/x1226reg.h>
#include "ioconf.h"
struct xrtc_softc {
device_t sc_dev;
i2c_tag_t sc_tag;
@ -65,7 +67,6 @@ static int xrtc_match(device_t, cfdata_t, void *);
CFATTACH_DECL_NEW(xrtc, sizeof(struct xrtc_softc),
xrtc_match, xrtc_attach, NULL, NULL);
extern struct cfdriver xrtc_cd;
dev_type_open(xrtc_open);
dev_type_close(xrtc_close);

View File

@ -1,4 +1,4 @@
/* $NetBSD: dpti.c,v 1.48 2014/07/25 08:10:37 dholland Exp $ */
/* $NetBSD: dpti.c,v 1.49 2017/10/28 04:53:55 riastradh Exp $ */
/*-
* Copyright (c) 2001, 2007 The NetBSD Foundation, Inc.
@ -57,7 +57,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: dpti.c,v 1.48 2014/07/25 08:10:37 dholland Exp $");
__KERNEL_RCSID(0, "$NetBSD: dpti.c,v 1.49 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -83,6 +83,8 @@ __KERNEL_RCSID(0, "$NetBSD: dpti.c,v 1.48 2014/07/25 08:10:37 dholland Exp $");
#include <dev/i2o/iopvar.h>
#include <dev/i2o/dptivar.h>
#include "ioconf.h"
#ifdef I2ODEBUG
#define DPRINTF(x) printf x
#else
@ -151,8 +153,6 @@ const struct cdevsw dpti_cdevsw = {
.d_flag = D_OTHER,
};
extern struct cfdriver dpti_cd;
CFATTACH_DECL_NEW(dpti, sizeof(struct dpti_softc),
dpti_match, dpti_attach, NULL, NULL);

View File

@ -1,4 +1,4 @@
/* $NetBSD: iop.c,v 1.87 2015/08/16 19:21:33 msaitoh Exp $ */
/* $NetBSD: iop.c,v 1.88 2017/10/28 04:53:55 riastradh Exp $ */
/*-
* Copyright (c) 2000, 2001, 2002, 2007 The NetBSD Foundation, Inc.
@ -34,7 +34,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: iop.c,v 1.87 2015/08/16 19:21:33 msaitoh Exp $");
__KERNEL_RCSID(0, "$NetBSD: iop.c,v 1.88 2017/10/28 04:53:55 riastradh Exp $");
#include "iop.h"
@ -57,6 +57,7 @@ __KERNEL_RCSID(0, "$NetBSD: iop.c,v 1.87 2015/08/16 19:21:33 msaitoh Exp $");
#include <dev/i2o/iopreg.h>
#include <dev/i2o/iopvar.h>
#include "ioconf.h"
#include "locators.h"
#define POLL(ms, cond) \
@ -89,8 +90,6 @@ static void *iop_sdh;
static struct i2o_systab *iop_systab;
static int iop_systab_size;
extern struct cfdriver iop_cd;
dev_type_open(iopopen);
dev_type_close(iopclose);
dev_type_ioctl(iopioctl);

View File

@ -1,4 +1,4 @@
/* $NetBSD: aac.c,v 1.45 2016/09/27 03:33:32 pgoyette Exp $ */
/* $NetBSD: aac.c,v 1.46 2017/10/28 04:53:55 riastradh Exp $ */
/*-
* Copyright (c) 2002, 2007 The NetBSD Foundation, Inc.
@ -70,7 +70,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: aac.c,v 1.45 2016/09/27 03:33:32 pgoyette Exp $");
__KERNEL_RCSID(0, "$NetBSD: aac.c,v 1.46 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -145,8 +145,6 @@ MALLOC_DEFINE(M_AACBUF, "aacbuf", "Buffers for aac(4)");
static void *aac_sdh;
extern struct cfdriver aac_cd;
int
aac_attach(struct aac_softc *sc)
{

View File

@ -1,4 +1,4 @@
/* $NetBSD: aic6360.c,v 1.100 2017/01/11 07:16:48 skrll Exp $ */
/* $NetBSD: aic6360.c,v 1.101 2017/10/28 04:53:55 riastradh Exp $ */
/*
* Copyright (c) 1994, 1995, 1996 Charles M. Hannum. All rights reserved.
@ -58,7 +58,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: aic6360.c,v 1.100 2017/01/11 07:16:48 skrll Exp $");
__KERNEL_RCSID(0, "$NetBSD: aic6360.c,v 1.101 2017/10/28 04:53:55 riastradh Exp $");
#include "opt_ddb.h"
@ -141,6 +141,8 @@ __KERNEL_RCSID(0, "$NetBSD: aic6360.c,v 1.100 2017/01/11 07:16:48 skrll Exp $");
#include <dev/ic/aic6360reg.h>
#include <dev/ic/aic6360var.h>
#include "ioconf.h"
#ifndef DDB
#define Debugger() panic("should call debugger here (aic6360.c)")
#endif /* ! DDB */
@ -2149,7 +2151,6 @@ aic_print_acb(struct aic_acb *acb)
void
aic_print_active_acb(void)
{
extern struct cfdriver aic_cd;
struct aic_acb *acb;
struct aic_softc *sc = device_lookup_private(&aic_cd, 0);

View File

@ -1,4 +1,4 @@
/* $NetBSD: attimer.c,v 1.11 2011/11/23 23:07:32 jmcneill Exp $ */
/* $NetBSD: attimer.c,v 1.12 2017/10/28 04:53:55 riastradh Exp $ */
/*
* Copyright (c) 2005 The NetBSD Foundation.
@ -33,7 +33,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: attimer.c,v 1.11 2011/11/23 23:07:32 jmcneill Exp $");
__KERNEL_RCSID(0, "$NetBSD: attimer.c,v 1.12 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -47,7 +47,7 @@ __KERNEL_RCSID(0, "$NetBSD: attimer.c,v 1.11 2011/11/23 23:07:32 jmcneill Exp $"
#include <dev/ic/attimervar.h>
#include <dev/ic/i8253reg.h>
extern struct cfdriver attimer_cd;
#include "ioconf.h"
void
attimer_attach(struct attimer_softc *sc)

View File

@ -1,4 +1,4 @@
/* $NetBSD: cac.c,v 1.57 2016/09/27 03:33:32 pgoyette Exp $ */
/* $NetBSD: cac.c,v 1.58 2017/10/28 04:53:55 riastradh Exp $ */
/*-
* Copyright (c) 2000, 2006, 2007 The NetBSD Foundation, Inc.
@ -34,7 +34,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: cac.c,v 1.57 2016/09/27 03:33:32 pgoyette Exp $");
__KERNEL_RCSID(0, "$NetBSD: cac.c,v 1.58 2017/10/28 04:53:55 riastradh Exp $");
#if defined(_KERNEL_OPT)
#include "bio.h"
@ -61,6 +61,7 @@ __KERNEL_RCSID(0, "$NetBSD: cac.c,v 1.57 2016/09/27 03:33:32 pgoyette Exp $");
#include <dev/biovar.h>
#endif /* NBIO > 0 */
#include "ioconf.h"
#include "locators.h"
static struct cac_ccb *cac_ccb_alloc(struct cac_softc *, int);
@ -244,7 +245,6 @@ cac_rescan(device_t self, const char *attr, const int *flags)
static void
cac_shutdown(void *cookie)
{
extern struct cfdriver cac_cd;
struct cac_softc *sc;
u_int8_t tbuf[512];
int i;

View File

@ -1,4 +1,4 @@
/* $NetBSD: clmpcc.c,v 1.51 2014/11/15 19:18:18 christos Exp $ */
/* $NetBSD: clmpcc.c,v 1.52 2017/10/28 04:53:55 riastradh Exp $ */
/*-
* Copyright (c) 1999 The NetBSD Foundation, Inc.
@ -34,7 +34,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: clmpcc.c,v 1.51 2014/11/15 19:18:18 christos Exp $");
__KERNEL_RCSID(0, "$NetBSD: clmpcc.c,v 1.52 2017/10/28 04:53:55 riastradh Exp $");
#include "opt_ddb.h"
@ -61,6 +61,7 @@ __KERNEL_RCSID(0, "$NetBSD: clmpcc.c,v 1.51 2014/11/15 19:18:18 christos Exp $")
#include <dev/ic/clmpccvar.h>
#include <dev/cons.h>
#include "ioconf.h"
#if defined(CLMPCC_ONLY_BYTESWAP_LOW) && defined(CLMPCC_ONLY_BYTESWAP_HIGH)
#error "CLMPCC_ONLY_BYTESWAP_LOW and CLMPCC_ONLY_BYTESWAP_HIGH are mutually exclusive."
@ -84,8 +85,6 @@ static int clmpcc_modem_control(struct clmpcc_chan *, int, int);
*/
#define ISCLR(v, f) (((v) & (f)) == 0)
extern struct cfdriver clmpcc_cd;
dev_type_open(clmpccopen);
dev_type_close(clmpccclose);
dev_type_read(clmpccread);

View File

@ -1,4 +1,4 @@
/* $NetBSD: com.c,v 1.342 2017/08/10 13:25:49 nat Exp $ */
/* $NetBSD: com.c,v 1.343 2017/10/28 04:53:55 riastradh Exp $ */
/*-
* Copyright (c) 1998, 1999, 2004, 2008 The NetBSD Foundation, Inc.
@ -66,7 +66,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: com.c,v 1.342 2017/08/10 13:25:49 nat Exp $");
__KERNEL_RCSID(0, "$NetBSD: com.c,v 1.343 2017/10/28 04:53:55 riastradh Exp $");
#include "opt_com.h"
#include "opt_ddb.h"
@ -128,6 +128,8 @@ __KERNEL_RCSID(0, "$NetBSD: com.c,v 1.342 2017/08/10 13:25:49 nat Exp $");
#define com_lcr com_cfcr
#include <dev/cons.h>
#include "ioconf.h"
#ifdef COM_REGMAP
#define CSR_WRITE_1(r, o, v) \
bus_space_write_1((r)->cr_iot, (r)->cr_ioh, (r)->cr_map[o], v)
@ -190,8 +192,6 @@ integrate void com_stsoft(struct com_softc *, struct tty *);
integrate void com_schedrx(struct com_softc *);
void comdiag(void *);
extern struct cfdriver com_cd;
dev_type_open(comopen);
dev_type_close(comclose);
dev_type_read(comread);

View File

@ -1,4 +1,4 @@
/* $NetBSD: cy.c,v 1.60 2014/11/15 19:18:18 christos Exp $ */
/* $NetBSD: cy.c,v 1.61 2017/10/28 04:53:55 riastradh Exp $ */
/*
* cy.c
@ -16,7 +16,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: cy.c,v 1.60 2014/11/15 19:18:18 christos Exp $");
__KERNEL_RCSID(0, "$NetBSD: cy.c,v 1.61 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/ioctl.h>
@ -38,6 +38,8 @@ __KERNEL_RCSID(0, "$NetBSD: cy.c,v 1.60 2014/11/15 19:18:18 christos Exp $");
#include <dev/ic/cyreg.h>
#include <dev/ic/cyvar.h>
#include "ioconf.h"
static int cyparam(struct tty *, struct termios *);
static void cystart(struct tty *);
static void cy_poll(void *);
@ -46,8 +48,6 @@ static void cy_enable_transmitter(struct cy_softc *, struct cy_port *);
static void cd1400_channel_cmd(struct cy_softc *, struct cy_port *, int);
static int cy_speed(speed_t, int *, int *, int);
extern struct cfdriver cy_cd;
static dev_type_open(cyopen);
static dev_type_close(cyclose);
static dev_type_read(cyread);

View File

@ -1,4 +1,4 @@
/* $NetBSD: dpt.c,v 1.73 2016/07/07 06:55:41 msaitoh Exp $ */
/* $NetBSD: dpt.c,v 1.74 2017/10/28 04:53:55 riastradh Exp $ */
/*-
* Copyright (c) 1997, 1998, 1999, 2000, 2001 The NetBSD Foundation, Inc.
@ -71,7 +71,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: dpt.c,v 1.73 2016/07/07 06:55:41 msaitoh Exp $");
__KERNEL_RCSID(0, "$NetBSD: dpt.c,v 1.74 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -99,6 +99,8 @@ __KERNEL_RCSID(0, "$NetBSD: dpt.c,v 1.73 2016/07/07 06:55:41 msaitoh Exp $");
#include <dev/i2o/dptivar.h>
#include "ioconf.h"
#ifdef DEBUG
#define DPRINTF(x) printf x
#else
@ -151,8 +153,6 @@ const struct cdevsw dpt_cdevsw = {
.d_flag = D_OTHER,
};
extern struct cfdriver dpt_cd;
static struct dpt_sig dpt_sig = {
{ 'd', 'P', 't', 'S', 'i', 'G'},
SIG_VERSION,

View File

@ -1,4 +1,4 @@
/* $NetBSD: icp_ioctl.c,v 1.21 2014/07/25 08:10:37 dholland Exp $ */
/* $NetBSD: icp_ioctl.c,v 1.22 2017/10/28 04:53:55 riastradh Exp $ */
/*-
* Copyright (c) 2003 The NetBSD Foundation, Inc.
@ -69,7 +69,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: icp_ioctl.c,v 1.21 2014/07/25 08:10:37 dholland Exp $");
__KERNEL_RCSID(0, "$NetBSD: icp_ioctl.c,v 1.22 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -85,6 +85,8 @@ __KERNEL_RCSID(0, "$NetBSD: icp_ioctl.c,v 1.21 2014/07/25 08:10:37 dholland Exp
#include <dev/ic/icpreg.h>
#include <dev/ic/icpvar.h>
#include "ioconf.h"
/* These are simply the same as ICP's "iir" driver for FreeBSD. */
#define ICP_DRIVER_VERSION 1
#define ICP_DRIVER_SUBVERSION 3
@ -107,8 +109,6 @@ const struct cdevsw icp_cdevsw = {
.d_flag = D_OTHER
};
extern struct cfdriver icp_cd;
kmutex_t icp_ioctl_mutex;
static int

View File

@ -1,4 +1,4 @@
/* $NetBSD: joy.c,v 1.20 2014/07/25 08:10:37 dholland Exp $ */
/* $NetBSD: joy.c,v 1.21 2017/10/28 04:53:55 riastradh Exp $ */
/*-
* Copyright (c) 2008 The NetBSD Foundation, Inc.
@ -61,7 +61,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: joy.c,v 1.20 2014/07/25 08:10:37 dholland Exp $");
__KERNEL_RCSID(0, "$NetBSD: joy.c,v 1.21 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -76,6 +76,8 @@ __KERNEL_RCSID(0, "$NetBSD: joy.c,v 1.20 2014/07/25 08:10:37 dholland Exp $");
#include <dev/ic/joyvar.h>
#include "ioconf.h"
/*
* The game port can manage 4 buttons and 4 variable resistors (usually 2
* joysticks, each with 2 buttons and 2 pots.) via the port at address 0x201.
@ -94,8 +96,6 @@ __KERNEL_RCSID(0, "$NetBSD: joy.c,v 1.20 2014/07/25 08:10:37 dholland Exp $");
#define JOY_TIMEOUT 2000 /* 2 milliseconds */
#endif
extern struct cfdriver joy_cd;
static dev_type_open(joyopen);
static dev_type_close(joyclose);
static dev_type_read(joyread);

View File

@ -1,4 +1,4 @@
/* $NetBSD: lpt.c,v 1.80 2014/07/25 08:10:37 dholland Exp $ */
/* $NetBSD: lpt.c,v 1.81 2017/10/28 04:53:55 riastradh Exp $ */
/*
* Copyright (c) 1993, 1994 Charles M. Hannum.
@ -54,7 +54,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: lpt.c,v 1.80 2014/07/25 08:10:37 dholland Exp $");
__KERNEL_RCSID(0, "$NetBSD: lpt.c,v 1.81 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -73,6 +73,8 @@ __KERNEL_RCSID(0, "$NetBSD: lpt.c,v 1.80 2014/07/25 08:10:37 dholland Exp $");
#include <dev/ic/lptreg.h>
#include <dev/ic/lptvar.h>
#include "ioconf.h"
#define TIMEOUT hz*16 /* wait up to 16 seconds for a ready */
#define STEP hz/4
@ -88,8 +90,6 @@ __KERNEL_RCSID(0, "$NetBSD: lpt.c,v 1.80 2014/07/25 08:10:37 dholland Exp $");
int lptdebug = 0;
#endif
extern struct cfdriver lpt_cd;
dev_type_open(lptopen);
dev_type_close(lptclose);
dev_type_write(lptwrite);

View File

@ -1,4 +1,4 @@
/* $NetBSD: mb89352.c,v 1.55 2017/01/11 07:16:48 skrll Exp $ */
/* $NetBSD: mb89352.c,v 1.56 2017/10/28 04:53:55 riastradh Exp $ */
/* NecBSD: mb89352.c,v 1.4 1998/03/14 07:31:20 kmatsuda Exp */
/*-
@ -77,7 +77,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: mb89352.c,v 1.55 2017/01/11 07:16:48 skrll Exp $");
__KERNEL_RCSID(0, "$NetBSD: mb89352.c,v 1.56 2017/10/28 04:53:55 riastradh Exp $");
#ifdef DDB
#define integrate
@ -164,6 +164,8 @@ __KERNEL_RCSID(0, "$NetBSD: mb89352.c,v 1.55 2017/01/11 07:16:48 skrll Exp $");
#include <dev/ic/mb89352reg.h>
#include <dev/ic/mb89352var.h>
#include "ioconf.h"
#ifndef DDB
#define Debugger() panic("should call debugger here (mb89352.c)")
#endif /* ! DDB */
@ -199,8 +201,6 @@ void spc_show_scsi_cmd(struct spc_acb *);
void spc_print_active_acb(void);
#endif
extern struct cfdriver spc_cd;
/*
* INITIALIZATION ROUTINES (probe, attach ++)
*/

View File

@ -1,4 +1,4 @@
/* $NetBSD: mfi.c,v 1.57 2015/04/04 15:10:47 christos Exp $ */
/* $NetBSD: mfi.c,v 1.58 2017/10/28 04:53:55 riastradh Exp $ */
/* $OpenBSD: mfi.c,v 1.66 2006/11/28 23:59:45 dlg Exp $ */
/*
@ -73,7 +73,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: mfi.c,v 1.57 2015/04/04 15:10:47 christos Exp $");
__KERNEL_RCSID(0, "$NetBSD: mfi.c,v 1.58 2017/10/28 04:53:55 riastradh Exp $");
#include "bio.h"
@ -108,6 +108,8 @@ __KERNEL_RCSID(0, "$NetBSD: mfi.c,v 1.57 2015/04/04 15:10:47 christos Exp $");
#include <dev/biovar.h>
#endif /* NBIO > 0 */
#include "ioconf.h"
#ifdef MFI_DEBUG
uint32_t mfi_debug = 0
/* | MFI_D_CMD */
@ -198,8 +200,6 @@ const struct cdevsw mfi_cdevsw = {
.d_flag = D_OTHER
};
extern struct cfdriver mfi_cd;
static uint32_t mfi_xscale_fw_state(struct mfi_softc *sc);
static void mfi_xscale_intr_ena(struct mfi_softc *sc);
static void mfi_xscale_intr_dis(struct mfi_softc *sc);

View File

@ -1,4 +1,4 @@
/* $NetBSD: midway.c,v 1.100 2017/03/31 08:38:13 msaitoh Exp $ */
/* $NetBSD: midway.c,v 1.101 2017/10/28 04:53:55 riastradh Exp $ */
/* (sync'd to midway.c 1.68) */
/*
@ -61,7 +61,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: midway.c,v 1.100 2017/03/31 08:38:13 msaitoh Exp $");
__KERNEL_RCSID(0, "$NetBSD: midway.c,v 1.101 2017/10/28 04:53:55 riastradh Exp $");
#include "opt_natm.h"
@ -187,6 +187,7 @@ __KERNEL_RCSID(0, "$NetBSD: midway.c,v 1.100 2017/03/31 08:38:13 msaitoh Exp $")
#if defined(__NetBSD__) || defined(__OpenBSD__)
#include <dev/ic/midwayreg.h>
#include <dev/ic/midwayvar.h>
#include "ioconf.h"
#if defined(__alpha__)
/* XXX XXX NEED REAL DMA MAPPING SUPPORT XXX XXX */
#undef vtophys
@ -247,12 +248,6 @@ __KERNEL_RCSID(0, "$NetBSD: midway.c,v 1.100 2017/03/31 08:38:13 msaitoh Exp $")
int en_dma = EN_DMA; /* use DMA (switch off for dbg) */
/*
* autoconfig attachments
*/
extern struct cfdriver en_cd;
/*
* local structures
*/

View File

@ -1,4 +1,4 @@
/* $NetBSD: mlx.c,v 1.65 2016/09/27 03:33:32 pgoyette Exp $ */
/* $NetBSD: mlx.c,v 1.66 2017/10/28 04:53:55 riastradh Exp $ */
/*-
* Copyright (c) 2001 The NetBSD Foundation, Inc.
@ -67,7 +67,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: mlx.c,v 1.65 2016/09/27 03:33:32 pgoyette Exp $");
__KERNEL_RCSID(0, "$NetBSD: mlx.c,v 1.66 2017/10/28 04:53:55 riastradh Exp $");
#if defined(_KERNEL_OPT)
#include "ld.h"
@ -97,6 +97,7 @@ __KERNEL_RCSID(0, "$NetBSD: mlx.c,v 1.65 2016/09/27 03:33:32 pgoyette Exp $");
#include <dev/ic/mlxio.h>
#include <dev/ic/mlxvar.h>
#include "ioconf.h"
#include "locators.h"
#define MLX_TIMEOUT 60
@ -146,7 +147,6 @@ const struct cdevsw mlx_cdevsw = {
.d_flag = D_OTHER
};
extern struct cfdriver mlx_cd;
static struct lwp *mlx_periodic_lwp;
static void *mlx_sdh;
@ -680,7 +680,6 @@ static void
mlx_adjqparam(struct mlx_softc *mlx, int mpu, int slop)
{
#if NLD > 0
extern struct cfdriver ld_cd;
struct ld_softc *ld;
int i;

View File

@ -1,4 +1,4 @@
/* $NetBSD: nvme.c,v 1.30 2017/06/01 02:45:10 chs Exp $ */
/* $NetBSD: nvme.c,v 1.31 2017/10/28 04:53:55 riastradh Exp $ */
/* $OpenBSD: nvme.c,v 1.49 2016/04/18 05:59:50 dlg Exp $ */
/*
@ -18,7 +18,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: nvme.c,v 1.30 2017/06/01 02:45:10 chs Exp $");
__KERNEL_RCSID(0, "$NetBSD: nvme.c,v 1.31 2017/10/28 04:53:55 riastradh Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@ -40,6 +40,8 @@ __KERNEL_RCSID(0, "$NetBSD: nvme.c,v 1.30 2017/06/01 02:45:10 chs Exp $");
#include <dev/ic/nvmevar.h>
#include <dev/ic/nvmeio.h>
#include "ioconf.h"
int nvme_adminq_size = 32;
int nvme_ioq_size = 1024;
@ -1662,8 +1664,6 @@ const struct cdevsw nvme_cdevsw = {
.d_flag = D_OTHER,
};
extern struct cfdriver nvme_cd;
/*
* Accept an open operation on the control device.
*/

View File

@ -1,4 +1,4 @@
/* $NetBSD: rrunner.c,v 1.84 2017/08/20 11:00:30 maxv Exp $ */
/* $NetBSD: rrunner.c,v 1.85 2017/10/28 04:53:55 riastradh Exp $ */
/*
* Copyright (c) 1997, 1998 The NetBSD Foundation, Inc.
@ -35,7 +35,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: rrunner.c,v 1.84 2017/08/20 11:00:30 maxv Exp $");
__KERNEL_RCSID(0, "$NetBSD: rrunner.c,v 1.85 2017/10/28 04:53:55 riastradh Exp $");
#include "opt_inet.h"
@ -85,13 +85,12 @@ __KERNEL_RCSID(0, "$NetBSD: rrunner.c,v 1.84 2017/08/20 11:00:30 maxv Exp $");
#include <dev/ic/rrunnerreg.h>
#include <dev/ic/rrunnervar.h>
#include "ioconf.h"
/*
#define ESH_PRINTF
*/
/* Autoconfig definition of driver back-end */
extern struct cfdriver esh_cd;
struct esh_softc *esh_softc_debug[22]; /* for gdb */
#ifdef DIAGNOSTIC

View File

@ -1,4 +1,4 @@
/* $NetBSD: tpm.c,v 1.11 2014/07/25 08:10:37 dholland Exp $ */
/* $NetBSD: tpm.c,v 1.12 2017/10/28 04:53:55 riastradh Exp $ */
/*
* Copyright (c) 2008, 2009 Michael Shalayeff
* Copyright (c) 2009, 2010 Hans-Jörg Höxer
@ -18,7 +18,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: tpm.c,v 1.11 2014/07/25 08:10:37 dholland Exp $");
__KERNEL_RCSID(0, "$NetBSD: tpm.c,v 1.12 2017/10/28 04:53:55 riastradh Exp $");
#if 0
#define TPM_DEBUG
@ -38,6 +38,8 @@ __KERNEL_RCSID(0, "$NetBSD: tpm.c,v 1.11 2014/07/25 08:10:37 dholland Exp $");
#include <dev/ic/tpmreg.h>
#include <dev/ic/tpmvar.h>
#include "ioconf.h"
/* Set when enabling legacy interface in host bridge. */
int tpm_enabled;
@ -74,7 +76,6 @@ static dev_type_read(tpmread);
static dev_type_read(tpmwrite);
static dev_type_ioctl(tpmioctl);
extern struct cfdriver tpm_cd;
#define TPMUNIT(a) minor(a)
const struct cdevsw tpm_cdevsw = {