summaryrefslogtreecommitdiff
path: root/sys/dev
diff options
context:
space:
mode:
authorpk <pk@NetBSD.org>2000-01-11 12:59:43 +0000
committerpk <pk@NetBSD.org>2000-01-11 12:59:43 +0000
commitc6b6f3883a0ebb98144f71ea756fea4e1f4de973 (patch)
treee6ce7bb261629d5f6daf11ae7266ba8388e3ad5a /sys/dev
parent9658271f9d772006fcfe7995c24ca9b07be03412 (diff)
Remove old-style boot device recognition.
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/sbus/dma_sbus.c18
-rw-r--r--sys/dev/sbus/esp_sbus.c22
-rw-r--r--sys/dev/sbus/if_le.c10
-rw-r--r--sys/dev/sbus/if_le_lebuffer.c10
-rw-r--r--sys/dev/sbus/if_le_ledma.c9
-rw-r--r--sys/dev/sbus/lebuffer.c11
-rw-r--r--sys/dev/sbus/qec.c11
-rw-r--r--sys/dev/sbus/sbusvar.h7
-rw-r--r--sys/dev/sbus/xbox.c10
-rw-r--r--sys/dev/sbus/xboxvar.h3
10 files changed, 14 insertions, 97 deletions
diff --git a/sys/dev/sbus/dma_sbus.c b/sys/dev/sbus/dma_sbus.c
index 36f1bd308c1..58f1648823c 100644
--- a/sys/dev/sbus/dma_sbus.c
+++ b/sys/dev/sbus/dma_sbus.c
@@ -1,4 +1,4 @@
-/* $NetBSD: dma_sbus.c,v 1.3 1998/09/05 17:28:57 pk Exp $ */
+/* $NetBSD: dma_sbus.c,v 1.4 2000/01/11 12:59:43 pk Exp $ */
/*-
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -152,7 +152,6 @@ dmaattach_sbus(parent, self, aux)
struct dma_softc *dsc = (void *)self;
struct lsi64854_softc *sc = &dsc->sc_lsi64854;
bus_space_handle_t bh;
-/*XXX*/ struct bootpath *bp;
bus_space_tag_t sbt;
int sbusburst, burst;
int node;
@@ -222,19 +221,6 @@ dmaattach_sbus(parent, self, aux)
sc->sc_channel = L64854_CHANNEL_SCSI;
}
-
- /* Propagate bootpath */
- bp = NULL;
- if (sa->sa_bp != NULL) {
- char *bpname = sa->sa_bp->name;
- if (strcmp(bpname, "espdma") == 0)
- /* We call everything "dma" */
- bpname = "dma";
-
- if (strcmp(bpname, self->dv_cfdata->cf_driver->cd_name) == 0)
- bp = sa->sa_bp + 1;
- }
-
sbus_establish(&dsc->sc_sd, &sc->sc_dev);
sbt = dma_alloc_bustag(dsc);
lsi64854_attach(sc);
@@ -243,7 +229,7 @@ dmaattach_sbus(parent, self, aux)
for (node = firstchild(sa->sa_node); node; node = nextsibling(node)) {
struct sbus_attach_args sa;
sbus_setup_attach_args((struct sbus_softc *)parent,
- sbt, sc->sc_dmatag, node, bp, &sa);
+ sbt, sc->sc_dmatag, node, &sa);
(void) config_found(&sc->sc_dev, (void *)&sa, dmaprint_sbus);
sbus_destroy_attach_args(&sa);
}
diff --git a/sys/dev/sbus/esp_sbus.c b/sys/dev/sbus/esp_sbus.c
index 863a58c0167..896d89942aa 100644
--- a/sys/dev/sbus/esp_sbus.c
+++ b/sys/dev/sbus/esp_sbus.c
@@ -1,4 +1,4 @@
-/* $NetBSD: esp_sbus.c,v 1.7 1999/11/21 15:01:51 pk Exp $ */
+/* $NetBSD: esp_sbus.c,v 1.8 2000/01/11 12:59:43 pk Exp $ */
/*-
* Copyright (c) 1997, 1998 The NetBSD Foundation, Inc.
@@ -75,16 +75,6 @@ struct esp_softc {
int sc_pri; /* SBUS priority */
};
-/*
- * Is this esp on the bootpath?
- * We may get two forms of the bootpath:
- * (1) ../sbus@.../esp@<offset>,<slot>/sd@.. (PROM v3 style)
- * (2) /sbus0/esp0/sd@.. (PROM v2 style)
- */
-#define SAME_ESP(sc, bp, sa) \
- ((bp->val[0] == sa->sa_slot && bp->val[1] == sa->sa_offset) || \
- (bp->val[0] == -1 && bp->val[1] == sc->sc_dev.dv_unit))
-
void espattach_sbus __P((struct device *, struct device *, void *));
void espattach_dma __P((struct device *, struct device *, void *));
int espmatch_sbus __P((struct device *, struct cfdata *, void *));
@@ -236,10 +226,6 @@ espattach_sbus(parent, self, aux)
esc->sc_sd.sd_reset = (void *) ncr53c9x_reset;
sbus_establish(&esc->sc_sd, &sc->sc_dev);
- if (sa->sa_bp != NULL && strcmp("esp", sa->sa_bp->name) == 0 &&
- SAME_ESP(sc, sa->sa_bp, sa))
- bootpath_store(1, sa->sa_bp + 1);
-
if (strcmp("ptscII", sa->sa_name) == 0) {
espattach(esc, &esp_sbus_glue1);
} else {
@@ -303,10 +289,6 @@ espattach_dma(parent, self, aux)
esc->sc_sd.sd_reset = (void *) ncr53c9x_reset;
sbus_establish(&esc->sc_sd, parent);
- if (sa->sa_bp != NULL && strcmp("esp", sa->sa_bp->name) == 0 &&
- SAME_ESP(sc, sa->sa_bp, sa))
- bootpath_store(1, sa->sa_bp + 1);
-
espattach(esc, &esp_sbus_glue);
}
@@ -423,8 +405,6 @@ espattach(esc, gluep)
/* Turn on target selection using the `dma' method */
ncr53c9x_dmaselect = 1;
-
- bootpath_store(1, NULL);
}
/*
diff --git a/sys/dev/sbus/if_le.c b/sys/dev/sbus/if_le.c
index 6be7afbb1f1..70bd27e2633 100644
--- a/sys/dev/sbus/if_le.c
+++ b/sys/dev/sbus/if_le.c
@@ -1,4 +1,4 @@
-/* $NetBSD: if_le.c,v 1.9 1999/11/21 15:01:51 pk Exp $ */
+/* $NetBSD: if_le.c,v 1.10 2000/01/11 12:59:43 pk Exp $ */
/*-
* Copyright (c) 1997, 1998 The NetBSD Foundation, Inc.
@@ -158,10 +158,6 @@ lematch_sbus(parent, cf, aux)
return (strcmp(cf->cf_driver->cd_name, sa->sa_name) == 0);
}
-#define SAME_LANCE(bp, sa) \
- ((bp->val[0] == sa->sa_slot && bp->val[1] == sa->sa_offset) || \
- (bp->val[0] == -1 && bp->val[1] == sc->sc_dev.dv_unit))
-
void
leattach_sbus(parent, self, aux)
struct device *parent, *self;
@@ -220,10 +216,6 @@ leattach_sbus(parent, self, aux)
lesc->sc_sd.sd_reset = (void *)lance_reset;
sbus_establish(&lesc->sc_sd, &sc->sc_dev);
- if (sa->sa_bp != NULL && strcmp(sa->sa_bp->name, le_cd.cd_name) == 0 &&
- SAME_LANCE(sa->sa_bp, sa))
- sa->sa_bp->dev = &sc->sc_dev;
-
if (sc->sc_mem == 0) {
bus_dma_segment_t seg;
int rseg, error;
diff --git a/sys/dev/sbus/if_le_lebuffer.c b/sys/dev/sbus/if_le_lebuffer.c
index 9157e8a23b1..4b8a51fae1b 100644
--- a/sys/dev/sbus/if_le_lebuffer.c
+++ b/sys/dev/sbus/if_le_lebuffer.c
@@ -1,4 +1,4 @@
-/* $NetBSD: if_le_lebuffer.c,v 1.4 1999/11/21 15:01:51 pk Exp $ */
+/* $NetBSD: if_le_lebuffer.c,v 1.5 2000/01/11 12:59:43 pk Exp $ */
/*-
* Copyright (c) 1997, 1998 The NetBSD Foundation, Inc.
@@ -163,10 +163,6 @@ lematch_lebuffer(parent, cf, aux)
}
-#define SAME_LANCE(bp, sa) \
- (bp->val[0] == sa->sa_slot && bp->val[1] == sa->sa_offset)
-
-
void
leattach_lebuffer(parent, self, aux)
struct device *parent, *self;
@@ -205,10 +201,6 @@ leattach_lebuffer(parent, self, aux)
lesc->sc_sd.sd_reset = (void *)lance_reset;
sbus_establish(&lesc->sc_sd, parent);
- if (sa->sa_bp != NULL && strcmp(sa->sa_bp->name, le_cd.cd_name) == 0 &&
- SAME_LANCE(sa->sa_bp, sa))
- sa->sa_bp->dev = &sc->sc_dev;
-
sc->sc_supmedia = lemedia;
sc->sc_nsupmedia = NLEMEDIA;
sc->sc_defaultmedia = lemedia[0];
diff --git a/sys/dev/sbus/if_le_ledma.c b/sys/dev/sbus/if_le_ledma.c
index 59bd497637f..090a2a23d96 100644
--- a/sys/dev/sbus/if_le_ledma.c
+++ b/sys/dev/sbus/if_le_ledma.c
@@ -1,4 +1,4 @@
-/* $NetBSD: if_le_ledma.c,v 1.6 1999/11/21 15:01:51 pk Exp $ */
+/* $NetBSD: if_le_ledma.c,v 1.7 2000/01/11 12:59:44 pk Exp $ */
/*-
* Copyright (c) 1997, 1998 The NetBSD Foundation, Inc.
@@ -338,9 +338,6 @@ lematch_ledma(parent, cf, aux)
}
-#define SAME_LANCE(bp, sa) \
- (bp->val[0] == sa->sa_slot && bp->val[1] == sa->sa_offset)
-
void
leattach_ledma(parent, self, aux)
struct device *parent, *self;
@@ -400,10 +397,6 @@ leattach_ledma(parent, self, aux)
lesc->sc_sd.sd_reset = (void *)lance_reset;
sbus_establish(&lesc->sc_sd, parent);
- if (sa->sa_bp != NULL && strcmp(sa->sa_bp->name, le_cd.cd_name) == 0 &&
- SAME_LANCE(sa->sa_bp, sa))
- sa->sa_bp->dev = &sc->sc_dev;
-
sc->sc_mediachange = lemediachange;
sc->sc_mediastatus = lemediastatus;
sc->sc_supmedia = lemedia;
diff --git a/sys/dev/sbus/lebuffer.c b/sys/dev/sbus/lebuffer.c
index be5e84af2f6..b4590fc9d70 100644
--- a/sys/dev/sbus/lebuffer.c
+++ b/sys/dev/sbus/lebuffer.c
@@ -1,4 +1,4 @@
-/* $NetBSD: lebuffer.c,v 1.5 1998/08/29 20:38:38 pk Exp $ */
+/* $NetBSD: lebuffer.c,v 1.6 2000/01/11 12:59:44 pk Exp $ */
/*-
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -99,7 +99,6 @@ lebufattach(parent, self, aux)
int sbusburst;
bus_space_tag_t sbt;
bus_space_handle_t bh;
- struct bootpath *bp;
sc->sc_bustag = sa->sa_bustag;
sc->sc_dmatag = sa->sa_dmatag;
@@ -139,12 +138,6 @@ lebufattach(parent, self, aux)
sbus_establish(&sc->sc_sd, &sc->sc_dev);
- /* Propagate bootpath */
- if (sa->sa_bp != NULL)
- bp = sa->sa_bp + 1;
- else
- bp = NULL;
-
/* Allocate a bus tag */
sbt = (bus_space_tag_t)
malloc(sizeof(struct sparc_bus_space_tag), M_DEVBUF, M_NOWAIT);
@@ -163,7 +156,7 @@ lebufattach(parent, self, aux)
for (node = firstchild(node); node; node = nextsibling(node)) {
struct sbus_attach_args sa;
sbus_setup_attach_args((struct sbus_softc *)parent,
- sbt, sc->sc_dmatag, node, bp, &sa);
+ sbt, sc->sc_dmatag, node, &sa);
(void)config_found(&sc->sc_dev, (void *)&sa, lebufprint);
sbus_destroy_attach_args(&sa);
}
diff --git a/sys/dev/sbus/qec.c b/sys/dev/sbus/qec.c
index 5da41109269..d508efa51a4 100644
--- a/sys/dev/sbus/qec.c
+++ b/sys/dev/sbus/qec.c
@@ -1,4 +1,4 @@
-/* $NetBSD: qec.c,v 1.9 1999/06/24 19:56:51 pk Exp $ */
+/* $NetBSD: qec.c,v 1.10 2000/01/11 12:59:44 pk Exp $ */
/*-
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -115,7 +115,6 @@ qecattach(parent, self, aux)
int sbusburst;
bus_space_tag_t sbt;
bus_space_handle_t bh;
- struct bootpath *bp;
int error;
sc->sc_bustag = sa->sa_bustag;
@@ -190,12 +189,6 @@ qecattach(parent, self, aux)
panic("%s: error getting ranges property", self->dv_xname);
}
- /* Propagate bootpath */
- if (sa->sa_bp != NULL)
- bp = sa->sa_bp + 1;
- else
- bp = NULL;
-
/* Allocate a bus tag */
sbt = (bus_space_tag_t)
malloc(sizeof(struct sparc_bus_space_tag), M_DEVBUF, M_NOWAIT);
@@ -229,7 +222,7 @@ qecattach(parent, self, aux)
for (node = firstchild(node); node; node = nextsibling(node)) {
struct sbus_attach_args sa;
sbus_setup_attach_args((struct sbus_softc *)parent,
- sbt, sc->sc_dmatag, node, bp, &sa);
+ sbt, sc->sc_dmatag, node, &sa);
(void)config_found(&sc->sc_dev, (void *)&sa, qecprint);
sbus_destroy_attach_args(&sa);
}
diff --git a/sys/dev/sbus/sbusvar.h b/sys/dev/sbus/sbusvar.h
index 943d7f50126..5fe950813fd 100644
--- a/sys/dev/sbus/sbusvar.h
+++ b/sys/dev/sbus/sbusvar.h
@@ -1,4 +1,4 @@
-/* $NetBSD: sbusvar.h,v 1.9 1998/09/06 21:23:58 eeh Exp $ */
+/* $NetBSD: sbusvar.h,v 1.10 2000/01/11 12:59:44 pk Exp $ */
/*-
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -95,13 +95,11 @@ struct sbus_attach_args {
u_int32_t *sa_promvaddrs;/* PROM-supplied virtual addresses -- 32-bit */
int sa_npromvaddrs; /* Number of PROM VAs */
#define sa_promvaddr sa_promvaddrs[0]
-
- struct bootpath *sa_bp; /* used for locating boot device */
};
/* sbus_attach_internal() is also used from obio.c */
void sbus_attach_common __P((struct sbus_softc *, char *, int,
- struct bootpath *, const char * const *));
+ const char * const *));
int sbus_print __P((void *, const char *));
void sbus_establish __P((struct sbusdev *, struct device *));
@@ -111,7 +109,6 @@ int sbus_setup_attach_args __P((
bus_space_tag_t,
bus_dma_tag_t,
int, /*node*/
- struct bootpath *,
struct sbus_attach_args *));
void sbus_destroy_attach_args __P((struct sbus_attach_args *));
diff --git a/sys/dev/sbus/xbox.c b/sys/dev/sbus/xbox.c
index e0690be0ed3..1672d06790c 100644
--- a/sys/dev/sbus/xbox.c
+++ b/sys/dev/sbus/xbox.c
@@ -1,4 +1,4 @@
-/* $NetBSD: xbox.c,v 1.2 1998/07/27 19:13:06 pk Exp $ */
+/* $NetBSD: xbox.c,v 1.3 2000/01/11 12:59:44 pk Exp $ */
/*-
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -138,7 +138,6 @@ xbox_attach(parent, self, aux)
{
struct xbox_softc *sc = (struct xbox_softc *)self;
struct sbus_attach_args *sa = aux;
- struct bootpath *bp = sa->sa_bp;
int node = sa->sa_node;
struct xbox_attach_args xa;
char *cp;
@@ -156,12 +155,6 @@ xbox_attach(parent, self, aux)
printf("\n");
- /* Propagate bootpath */
- if (bp != NULL && strcmp(bp->name, "xbox") == 0)
- bp++;
- else
- bp = NULL;
-
/*
* Now pretend to be another Sbus.
*/
@@ -170,7 +163,6 @@ xbox_attach(parent, self, aux)
xa.xa_node = node;
xa.xa_bustag = sa->sa_bustag;
xa.xa_dmatag = sa->sa_dmatag;
- xa.xa_bp = bp;
(void) config_found(&sc->sc_dev, (void *)&xa, xbox_print);
}
diff --git a/sys/dev/sbus/xboxvar.h b/sys/dev/sbus/xboxvar.h
index e44a5b61a3c..a8f60faeceb 100644
--- a/sys/dev/sbus/xboxvar.h
+++ b/sys/dev/sbus/xboxvar.h
@@ -1,4 +1,4 @@
-/* $NetBSD: xboxvar.h,v 1.1 1998/04/18 19:00:18 pk Exp $ */
+/* $NetBSD: xboxvar.h,v 1.2 2000/01/11 12:59:44 pk Exp $ */
/*-
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -47,6 +47,5 @@ struct xbox_attach_args {
bus_dma_tag_t xa_dmatag;
char *xa_name; /* PROM node name */
int xa_node; /* PROM handle */
- struct bootpath *xa_bp; /* used for locating boot device */
};
#endif /* _XBOX_VAR_H */