Garbage-collect the old confargs stuff that was used in the Early Days.
It isn't really appropriate anymore. Replace it with a real mainbus attach args structure.
This commit is contained in:
parent
6a49b0a33e
commit
d19fbe1196
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: cpu.c,v 1.23 1998/01/12 10:21:02 thorpej Exp $ */
|
||||
/* $NetBSD: cpu.c,v 1.24 1998/05/14 00:01:30 thorpej Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1994, 1995, 1996 Carnegie-Mellon University.
|
||||
|
@ -29,7 +29,7 @@
|
|||
|
||||
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
|
||||
|
||||
__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.23 1998/01/12 10:21:02 thorpej Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: cpu.c,v 1.24 1998/05/14 00:01:30 thorpej Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
|
@ -54,10 +54,10 @@ cpumatch(parent, cfdata, aux)
|
|||
struct cfdata *cfdata;
|
||||
void *aux;
|
||||
{
|
||||
struct confargs *ca = aux;
|
||||
struct mainbus_attach_args *ma = aux;
|
||||
|
||||
/* make sure that we're looking for a CPU. */
|
||||
if (strcmp(ca->ca_name, cpu_cd.cd_name) != 0)
|
||||
if (strcmp(ma->ma_name, cpu_cd.cd_name) != 0)
|
||||
return (0);
|
||||
|
||||
/* XXX CHECK SLOT? */
|
||||
|
@ -72,7 +72,7 @@ cpuattach(parent, dev, aux)
|
|||
struct device *dev;
|
||||
void *aux;
|
||||
{
|
||||
struct confargs *ca = aux;
|
||||
struct mainbus_attach_args *ma = aux;
|
||||
struct pcs *p;
|
||||
#ifdef DEBUG
|
||||
int needcomma;
|
||||
|
@ -80,12 +80,12 @@ cpuattach(parent, dev, aux)
|
|||
u_int32_t major, minor;
|
||||
|
||||
p = (struct pcs *)((char *)hwrpb + hwrpb->rpb_pcs_off +
|
||||
(ca->ca_slot * hwrpb->rpb_pcs_size));
|
||||
(ma->ma_slot * hwrpb->rpb_pcs_size));
|
||||
major = (p->pcs_proc_type & PCS_PROC_MAJOR) >> PCS_PROC_MAJORSHIFT;
|
||||
minor = (p->pcs_proc_type & PCS_PROC_MINOR) >> PCS_PROC_MINORSHIFT;
|
||||
|
||||
printf(": ID %d%s, ", ca->ca_slot,
|
||||
ca->ca_slot == hwrpb->rpb_primary_cpu_id ? " (primary)" : "");
|
||||
printf(": ID %d%s, ", ma->ma_slot,
|
||||
ma->ma_slot == hwrpb->rpb_primary_cpu_id ? " (primary)" : "");
|
||||
|
||||
switch (major) {
|
||||
case PCS_PROC_EV3:
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: mainbus.c,v 1.25 1998/05/13 23:38:26 thorpej Exp $ */
|
||||
/* $NetBSD: mainbus.c,v 1.26 1998/05/14 00:01:30 thorpej Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1994, 1995, 1996 Carnegie-Mellon University.
|
||||
|
@ -29,7 +29,7 @@
|
|||
|
||||
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
|
||||
|
||||
__KERNEL_RCSID(0, "$NetBSD: mainbus.c,v 1.25 1998/05/13 23:38:26 thorpej Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: mainbus.c,v 1.26 1998/05/14 00:01:30 thorpej Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
|
@ -71,7 +71,7 @@ mbattach(parent, self, aux)
|
|||
struct device *self;
|
||||
void *aux;
|
||||
{
|
||||
struct confargs nca;
|
||||
struct mainbus_attach_args ma;
|
||||
struct pcs *pcsp;
|
||||
int i, cpuattachcnt;
|
||||
extern int ncpus;
|
||||
|
@ -91,10 +91,9 @@ mbattach(parent, self, aux)
|
|||
if ((pcsp->pcs_flags & PCS_PP) == 0)
|
||||
continue;
|
||||
|
||||
nca.ca_name = "cpu";
|
||||
nca.ca_slot = i;
|
||||
nca.ca_offset = 0;
|
||||
if (config_found(self, &nca, mbprint) != NULL)
|
||||
ma.ma_name = "cpu";
|
||||
ma.ma_slot = i;
|
||||
if (config_found(self, &ma, mbprint) != NULL)
|
||||
cpuattachcnt++;
|
||||
}
|
||||
if (ncpus != cpuattachcnt)
|
||||
|
@ -102,10 +101,9 @@ mbattach(parent, self, aux)
|
|||
ncpus, cpuattachcnt);
|
||||
|
||||
if (platform.iobus != NULL) {
|
||||
nca.ca_name = (char *) platform.iobus;
|
||||
nca.ca_slot = 0;
|
||||
nca.ca_offset = 0;
|
||||
config_found(self, &nca, mbprint);
|
||||
ma.ma_name = platform.iobus;
|
||||
ma.ma_slot = 0; /* meaningless */
|
||||
config_found(self, &ma, mbprint);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -114,10 +112,10 @@ mbprint(aux, pnp)
|
|||
void *aux;
|
||||
const char *pnp;
|
||||
{
|
||||
struct confargs *ca = aux;
|
||||
struct mainbus_attach_args *ma = aux;
|
||||
|
||||
if (pnp)
|
||||
printf("%s at %s", ca->ca_name, pnp);
|
||||
printf("%s at %s", ma->ma_name, pnp);
|
||||
|
||||
return (UNCONF);
|
||||
}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: autoconf.h,v 1.15 1998/05/13 23:38:27 thorpej Exp $ */
|
||||
/* $NetBSD: autoconf.h,v 1.16 1998/05/14 00:01:30 thorpej Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1994, 1995, 1996 Carnegie-Mellon University.
|
||||
|
@ -31,14 +31,10 @@
|
|||
* Machine-dependent structures of autoconfiguration
|
||||
*/
|
||||
|
||||
struct confargs;
|
||||
|
||||
typedef int (*intr_handler_t) __P((void *));
|
||||
|
||||
struct confargs {
|
||||
char *ca_name; /* Device name. */
|
||||
int ca_slot; /* Device slot. */
|
||||
int ca_offset; /* Offset into slot. */
|
||||
struct mainbus_attach_args {
|
||||
const char *ma_name; /* device name */
|
||||
int ma_slot; /* CPU "slot" number; only meaningful
|
||||
when attaching CPUs */
|
||||
};
|
||||
|
||||
struct bootdev_data {
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: mcbus.c,v 1.2 1998/04/15 20:37:39 mjacob Exp $ */
|
||||
/* $NetBSD: mcbus.c,v 1.3 1998/05/14 00:01:31 thorpej Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1998 by Matthew Jacob
|
||||
|
@ -37,7 +37,7 @@
|
|||
|
||||
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
|
||||
|
||||
__KERNEL_RCSID(0, "$NetBSD: mcbus.c,v 1.2 1998/04/15 20:37:39 mjacob Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: mcbus.c,v 1.3 1998/05/14 00:01:31 thorpej Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
|
@ -109,10 +109,10 @@ mcbusmatch(parent, cf, aux)
|
|||
struct cfdata *cf;
|
||||
void *aux;
|
||||
{
|
||||
struct confargs *ca = aux;
|
||||
struct mainbus_attach_args *ma = aux;
|
||||
|
||||
/* Make sure we're looking for a MCBUS. */
|
||||
if (strcmp(ca->ca_name, mcbus_cd.cd_name) != 0)
|
||||
if (strcmp(ma->ma_name, mcbus_cd.cd_name) != 0)
|
||||
return (0);
|
||||
|
||||
/*
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: a12c.c,v 1.3 1998/03/02 06:59:38 ross Exp $ */
|
||||
/* $NetBSD: a12c.c,v 1.4 1998/05/14 00:01:31 thorpej Exp $ */
|
||||
|
||||
/* [Notice revision 2.2]
|
||||
* Copyright (c) 1997, 1998 Avalon Computer Systems, Inc.
|
||||
|
@ -38,7 +38,7 @@
|
|||
#include "opt_avalon_a12.h" /* Config options headers */
|
||||
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
|
||||
|
||||
__KERNEL_RCSID(0, "$NetBSD: a12c.c,v 1.3 1998/03/02 06:59:38 ross Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: a12c.c,v 1.4 1998/05/14 00:01:31 thorpej Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
|
@ -95,10 +95,10 @@ a12cmatch(parent, match, aux)
|
|||
struct cfdata *match;
|
||||
void *aux;
|
||||
{
|
||||
struct confargs *ca = aux;
|
||||
struct mainbus_attach_args *ma = aux;
|
||||
|
||||
return cputype == ST_AVALON_A12
|
||||
&& strcmp(ca->ca_name, a12c_cd.cd_name) == 0
|
||||
&& strcmp(ma->ma_name, a12c_cd.cd_name) == 0
|
||||
&& !a12cfound;
|
||||
}
|
||||
|
||||
|
@ -144,7 +144,7 @@ a12cattach(parent, self, aux)
|
|||
a12c_init(ccp, 1);
|
||||
|
||||
/* XXX print chipset information */
|
||||
printf(": driver %s over logic %x\n", "$Revision: 1.3 $",
|
||||
printf(": driver %s over logic %x\n", "$Revision: 1.4 $",
|
||||
A12_ALL_EXTRACT(REGVAL(A12_VERS)));
|
||||
|
||||
pci_a12_pickintr(ccp);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: apecs.c,v 1.30 1998/04/29 00:24:59 thorpej Exp $ */
|
||||
/* $NetBSD: apecs.c,v 1.31 1998/05/14 00:01:31 thorpej Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1995, 1996 Carnegie-Mellon University.
|
||||
|
@ -32,7 +32,7 @@
|
|||
|
||||
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
|
||||
|
||||
__KERNEL_RCSID(0, "$NetBSD: apecs.c,v 1.30 1998/04/29 00:24:59 thorpej Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: apecs.c,v 1.31 1998/05/14 00:01:31 thorpej Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
|
@ -79,10 +79,10 @@ apecsmatch(parent, match, aux)
|
|||
struct cfdata *match;
|
||||
void *aux;
|
||||
{
|
||||
struct confargs *ca = aux;
|
||||
struct mainbus_attach_args *ma = aux;
|
||||
|
||||
/* Make sure that we're looking for an APECS. */
|
||||
if (strcmp(ca->ca_name, apecs_cd.cd_name) != 0)
|
||||
if (strcmp(ma->ma_name, apecs_cd.cd_name) != 0)
|
||||
return (0);
|
||||
|
||||
if (apecsfound)
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: cia.c,v 1.34 1998/05/12 19:07:21 thorpej Exp $ */
|
||||
/* $NetBSD: cia.c,v 1.35 1998/05/14 00:01:31 thorpej Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1995, 1996 Carnegie-Mellon University.
|
||||
|
@ -32,7 +32,7 @@
|
|||
|
||||
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
|
||||
|
||||
__KERNEL_RCSID(0, "$NetBSD: cia.c,v 1.34 1998/05/12 19:07:21 thorpej Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: cia.c,v 1.35 1998/05/14 00:01:31 thorpej Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
|
@ -79,10 +79,10 @@ ciamatch(parent, match, aux)
|
|||
struct cfdata *match;
|
||||
void *aux;
|
||||
{
|
||||
struct confargs *ca = aux;
|
||||
struct mainbus_attach_args *ma = aux;
|
||||
|
||||
/* Make sure that we're looking for a CIA. */
|
||||
if (strcmp(ca->ca_name, cia_cd.cd_name) != 0)
|
||||
if (strcmp(ma->ma_name, cia_cd.cd_name) != 0)
|
||||
return (0);
|
||||
|
||||
if (ciafound)
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: lca.c,v 1.27 1998/01/17 03:39:52 thorpej Exp $ */
|
||||
/* $NetBSD: lca.c,v 1.28 1998/05/14 00:01:31 thorpej Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1995, 1996 Carnegie-Mellon University.
|
||||
|
@ -31,7 +31,7 @@
|
|||
|
||||
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
|
||||
|
||||
__KERNEL_RCSID(0, "$NetBSD: lca.c,v 1.27 1998/01/17 03:39:52 thorpej Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: lca.c,v 1.28 1998/05/14 00:01:31 thorpej Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
|
@ -75,10 +75,10 @@ lcamatch(parent, match, aux)
|
|||
struct cfdata *match;
|
||||
void *aux;
|
||||
{
|
||||
struct confargs *ca = aux;
|
||||
struct mainbus_attach_args *ma = aux;
|
||||
|
||||
/* Make sure that we're looking for a LCA. */
|
||||
if (strcmp(ca->ca_name, lca_cd.cd_name) != 0)
|
||||
if (strcmp(ma->ma_name, lca_cd.cd_name) != 0)
|
||||
return (0);
|
||||
|
||||
if (lcafound)
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: mcpcia.c,v 1.1 1998/04/15 00:50:14 mjacob Exp $ */
|
||||
/* $NetBSD: mcpcia.c,v 1.2 1998/05/14 00:01:31 thorpej Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1998 by Matthew Jacob
|
||||
|
@ -37,7 +37,7 @@
|
|||
|
||||
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
|
||||
|
||||
__KERNEL_RCSID(0, "$NetBSD: mcpcia.c,v 1.1 1998/04/15 00:50:14 mjacob Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: mcpcia.c,v 1.2 1998/05/14 00:01:31 thorpej Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
|
@ -70,10 +70,6 @@ struct cfattach mcpcia_ca = {
|
|||
};
|
||||
|
||||
static int mcpciaprint __P((void *, const char *));
|
||||
void mcpcia_intr_establish __P((struct confargs *, int (*)(void *), void *));
|
||||
void mcpcia_intr_disestablish __P((struct confargs *));
|
||||
caddr_t mcpcia_cvtaddr __P((struct confargs *));
|
||||
int mcpcia_matchname __P((struct confargs *, char *));
|
||||
|
||||
static int
|
||||
mcpciaprint(aux, pnp)
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: tcasic.c,v 1.22 1998/01/19 02:54:24 thorpej Exp $ */
|
||||
/* $NetBSD: tcasic.c,v 1.23 1998/05/14 00:01:31 thorpej Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1994, 1995, 1996 Carnegie-Mellon University.
|
||||
|
@ -32,7 +32,7 @@
|
|||
|
||||
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
|
||||
|
||||
__KERNEL_RCSID(0, "$NetBSD: tcasic.c,v 1.22 1998/01/19 02:54:24 thorpej Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: tcasic.c,v 1.23 1998/05/14 00:01:31 thorpej Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
|
@ -67,10 +67,10 @@ tcasicmatch(parent, cfdata, aux)
|
|||
struct cfdata *cfdata;
|
||||
void *aux;
|
||||
{
|
||||
struct confargs *ca = aux;
|
||||
struct mainbus_attach_args *ma = aux;
|
||||
|
||||
/* Make sure that we're looking for a TurboChannel ASIC. */
|
||||
if (strcmp(ca->ca_name, tcasic_cd.cd_name))
|
||||
if (strcmp(ma->ma_name, tcasic_cd.cd_name))
|
||||
return (0);
|
||||
|
||||
/* Make sure that the system supports a TurboChannel ASIC. */
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: kftxx.c,v 1.8 1998/05/13 23:22:08 thorpej Exp $ */
|
||||
/* $NetBSD: kftxx.c,v 1.9 1998/05/14 00:01:32 thorpej Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1997 by Matthew Jacob
|
||||
|
@ -39,7 +39,7 @@
|
|||
|
||||
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
|
||||
|
||||
__KERNEL_RCSID(0, "$NetBSD: kftxx.c,v 1.8 1998/05/13 23:22:08 thorpej Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: kftxx.c,v 1.9 1998/05/14 00:01:32 thorpej Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
|
@ -71,10 +71,6 @@ struct cfattach kft_ca = {
|
|||
};
|
||||
|
||||
static int kftprint __P((void *, const char *));
|
||||
void kft_intr_establish __P((struct confargs *, int (*)(void *), void *));
|
||||
void kft_intr_disestablish __P((struct confargs *));
|
||||
caddr_t kft_cvtaddr __P((struct confargs *));
|
||||
int kft_matchname __P((struct confargs *, char *));
|
||||
|
||||
static int
|
||||
kftprint(aux, pnp)
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: tlsb.c,v 1.9 1998/05/13 23:23:23 thorpej Exp $ */
|
||||
/* $NetBSD: tlsb.c,v 1.10 1998/05/14 00:01:32 thorpej Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1997 by Matthew Jacob
|
||||
|
@ -40,7 +40,7 @@
|
|||
|
||||
#include <sys/cdefs.h> /* RCS ID & Copyright macro defns */
|
||||
|
||||
__KERNEL_RCSID(0, "$NetBSD: tlsb.c,v 1.9 1998/05/13 23:23:23 thorpej Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: tlsb.c,v 1.10 1998/05/14 00:01:32 thorpej Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
|
@ -114,10 +114,10 @@ tlsbmatch(parent, cf, aux)
|
|||
struct cfdata *cf;
|
||||
void *aux;
|
||||
{
|
||||
struct confargs *ca = aux;
|
||||
struct mainbus_attach_args *ma = aux;
|
||||
|
||||
/* Make sure we're looking for a TurboLaser. */
|
||||
if (strcmp(ca->ca_name, tlsb_cd.cd_name) != 0)
|
||||
if (strcmp(ma->ma_name, tlsb_cd.cd_name) != 0)
|
||||
return (0);
|
||||
|
||||
/*
|
||||
|
|
Loading…
Reference in New Issue