From c36ab687e95f9d95ed80e4ef8945b4157ad4bbca Mon Sep 17 00:00:00 2001 From: skrll Date: Sat, 29 Mar 2008 15:59:25 +0000 Subject: [PATCH] Tidyup the attachment of various devices in the same way as OpenBSD and use the same name. Must have been funny to someone. --- sys/arch/hp700/conf/files.hp700 | 36 +++++++++++++++---------------- sys/arch/hp700/dev/lasi.c | 9 +++----- sys/arch/hp700/dev/phantomas.c | 4 ++-- sys/arch/hp700/dev/sti_sgc.c | 10 +++------ sys/arch/hp700/dev/wax.c | 9 +++----- sys/arch/hp700/hp700/mainbus.c | 8 +++---- sys/arch/hp700/include/autoconf.h | 4 ++-- sys/conf/files | 4 ++-- 8 files changed, 36 insertions(+), 48 deletions(-) diff --git a/sys/arch/hp700/conf/files.hp700 b/sys/arch/hp700/conf/files.hp700 index 4e9b914b58dd..880de7b25978 100644 --- a/sys/arch/hp700/conf/files.hp700 +++ b/sys/arch/hp700/conf/files.hp700 @@ -1,4 +1,4 @@ -# $NetBSD: files.hp700,v 1.18 2008/02/20 21:43:34 drochner Exp $ +# $NetBSD: files.hp700,v 1.19 2008/03/29 15:59:25 skrll Exp $ # # $OpenBSD: files.hp700,v 1.31 2001/06/26 02:41:25 mickey Exp $ # @@ -65,65 +65,63 @@ define gscbus { } # Mainbus # -device mainbus {[irq = -1]}: sysmon_power, sysmon_taskq +define gedoens {[irq = -1]}: sysmon_power, sysmon_taskq +device mainbus: gedoens attach mainbus at root file arch/hp700/hp700/mainbus.c mainbus device pdc -attach pdc at mainbus +attach pdc at gedoens file arch/hp700/dev/pdc.c pdc device mem -attach mem at mainbus +attach mem at gedoens file arch/hp700/dev/mem.c mem device cpu -attach cpu at mainbus +attach cpu at gedoens file arch/hp700/dev/cpu.c cpu device fpu -attach fpu at mainbus +attach fpu at gedoens file arch/hp700/dev/fpu.c fpu # Phantom PseudoBC GSC+ Port -device phantomas {} -attach phantomas at mainbus +device phantomas: gedoens +attach phantomas at gedoens file arch/hp700/dev/phantomas.c phantomas # 1FT1-0002, 1FU2-0002 # as goes w/ 7100LC, 7300LC, 7200, 8000, 8200, 8500 device lasi: gscbus -attach lasi at mainbus with lasi_mainbus -attach lasi at phantomas with lasi_phantomas +attach lasi at gedoens file arch/hp700/dev/lasi.c lasi # all the older systems device asp: gscbus -attach asp at mainbus +attach asp at gedoens file arch/hp700/dev/asp.c asp # 1FT4-0001, ASIC used on gecko cards device wax: gscbus -attach wax at mainbus with wax_mainbus -attach wax at phantomas with wax_phantomas +attach wax at gedoens file arch/hp700/dev/wax.c wax device mongoose: isabus, eisabus -attach mongoose at mainbus +attach mongoose at gedoens file arch/hp700/dev/mongoose.c mongoose -# Dino, GSC to PCI bridge. Includes ps/2, serial, and flying toaster interfaces +# Dino, GSC-PCI bridge. Includes ps/2, serial, and flying toaster interfaces # Cujo is a 64-bit data path Dino device dino { }: pcibus -attach dino at phantomas +attach dino at gedoens file arch/hp700/dev/dino.c dino attach com at dino with com_dino file arch/hp700/dev/com_dino.c com_dino -attach sti at mainbus with sti_sgc -attach sti at phantomas with sti_phantomas -file arch/hp700/dev/sti_sgc.c sti_sgc | sti_phantomas +attach sti at gedoens with sti_gedoens +file arch/hp700/dev/sti_sgc.c sti_gedoens ### diff --git a/sys/arch/hp700/dev/lasi.c b/sys/arch/hp700/dev/lasi.c index d1108eb81418..4d04ad633ff8 100644 --- a/sys/arch/hp700/dev/lasi.c +++ b/sys/arch/hp700/dev/lasi.c @@ -1,4 +1,4 @@ -/* $NetBSD: lasi.c,v 1.10 2005/12/11 12:17:24 christos Exp $ */ +/* $NetBSD: lasi.c,v 1.11 2008/03/29 15:59:26 skrll Exp $ */ /* $OpenBSD: lasi.c,v 1.4 2001/06/09 03:57:19 mickey Exp $ */ @@ -33,7 +33,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: lasi.c,v 1.10 2005/12/11 12:17:24 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: lasi.c,v 1.11 2008/03/29 15:59:26 skrll Exp $"); #undef LASIDEBUG @@ -85,10 +85,7 @@ struct lasi_softc { int lasimatch(struct device *, struct cfdata *, void *); void lasiattach(struct device *, struct device *, void *); -CFATTACH_DECL(lasi_mainbus, sizeof(struct lasi_softc), - lasimatch, lasiattach, NULL, NULL); - -CFATTACH_DECL(lasi_phantomas, sizeof(struct lasi_softc), +CFATTACH_DECL(lasi, sizeof(struct lasi_softc), lasimatch, lasiattach, NULL, NULL); /* diff --git a/sys/arch/hp700/dev/phantomas.c b/sys/arch/hp700/dev/phantomas.c index 3df157065dfc..305427ab92d1 100644 --- a/sys/arch/hp700/dev/phantomas.c +++ b/sys/arch/hp700/dev/phantomas.c @@ -1,4 +1,4 @@ -/* $NetBSD: phantomas.c,v 1.3 2005/12/11 12:17:24 christos Exp $ */ +/* $NetBSD: phantomas.c,v 1.4 2008/03/29 15:59:26 skrll Exp $ */ /* $OpenBSD: phantomas.c,v 1.1 2002/12/18 23:52:45 mickey Exp $ */ /* @@ -76,5 +76,5 @@ static void phantomas_callback(struct device *self, struct confargs *ca) { - config_found_sm_loc(self, "phantomas", NULL, ca, mbprint, mbsubmatch); + config_found_sm_loc(self, "gedoens", NULL, ca, mbprint, mbsubmatch); } diff --git a/sys/arch/hp700/dev/sti_sgc.c b/sys/arch/hp700/dev/sti_sgc.c index c3b54587a737..2bfad0981863 100644 --- a/sys/arch/hp700/dev/sti_sgc.c +++ b/sys/arch/hp700/dev/sti_sgc.c @@ -1,4 +1,4 @@ -/* $NetBSD: sti_sgc.c,v 1.12 2005/12/11 12:17:24 christos Exp $ */ +/* $NetBSD: sti_sgc.c,v 1.13 2008/03/29 15:59:26 skrll Exp $ */ /* $OpenBSD: sti_sgc.c,v 1.21 2003/12/22 23:39:06 mickey Exp $ */ @@ -39,7 +39,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: sti_sgc.c,v 1.12 2005/12/11 12:17:24 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: sti_sgc.c,v 1.13 2008/03/29 15:59:26 skrll Exp $"); #include #include @@ -80,13 +80,9 @@ __KERNEL_RCSID(0, "$NetBSD: sti_sgc.c,v 1.12 2005/12/11 12:17:24 christos Exp $" int sti_sgc_probe(struct device *, struct cfdata *, void *); void sti_sgc_attach(struct device *, struct device *, void *); -CFATTACH_DECL(sti_sgc, sizeof(struct sti_softc), sti_sgc_probe, sti_sgc_attach, +CFATTACH_DECL(sti_gedoens, sizeof(struct sti_softc), sti_sgc_probe, sti_sgc_attach, NULL, NULL); -CFATTACH_DECL(sti_phantomas, sizeof(struct sti_softc), sti_sgc_probe, - sti_sgc_attach, NULL, NULL); - - paddr_t sti_sgc_getrom(struct confargs *); /* diff --git a/sys/arch/hp700/dev/wax.c b/sys/arch/hp700/dev/wax.c index dc8164a6ea38..17d2aebe4a27 100644 --- a/sys/arch/hp700/dev/wax.c +++ b/sys/arch/hp700/dev/wax.c @@ -1,4 +1,4 @@ -/* $NetBSD: wax.c,v 1.8 2005/12/11 12:17:24 christos Exp $ */ +/* $NetBSD: wax.c,v 1.9 2008/03/29 15:59:26 skrll Exp $ */ /* $OpenBSD: wax.c,v 1.1 1998/11/23 03:04:10 mickey Exp $ */ @@ -33,7 +33,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: wax.c,v 1.8 2005/12/11 12:17:24 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: wax.c,v 1.9 2008/03/29 15:59:26 skrll Exp $"); #include #include @@ -68,10 +68,7 @@ int waxmatch(struct device *, struct cfdata *, void *); void waxattach(struct device *, struct device *, void *); -CFATTACH_DECL(wax_mainbus, sizeof(struct wax_softc), - waxmatch, waxattach, NULL, NULL); - -CFATTACH_DECL(wax_phantomas, sizeof(struct wax_softc), +CFATTACH_DECL(wax, sizeof(struct wax_softc), waxmatch, waxattach, NULL, NULL); static int wax_attached; diff --git a/sys/arch/hp700/hp700/mainbus.c b/sys/arch/hp700/hp700/mainbus.c index c15f855a4f97..2bbb3e84f9a8 100644 --- a/sys/arch/hp700/hp700/mainbus.c +++ b/sys/arch/hp700/hp700/mainbus.c @@ -1,4 +1,4 @@ -/* $NetBSD: mainbus.c,v 1.41 2008/03/24 08:34:06 skrll Exp $ */ +/* $NetBSD: mainbus.c,v 1.42 2008/03/29 15:59:26 skrll Exp $ */ /*- * Copyright (c) 2001, 2002 The NetBSD Foundation, Inc. @@ -70,7 +70,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: mainbus.c,v 1.41 2008/03/24 08:34:06 skrll Exp $"); +__KERNEL_RCSID(0, "$NetBSD: mainbus.c,v 1.42 2008/03/29 15:59:26 skrll Exp $"); #include "locators.h" #include "opt_power_switch.h" @@ -1491,7 +1491,7 @@ mb_module_callback(struct device *self, struct confargs *ca) if (ca->ca_type.iodc_type == HPPA_TYPE_NPROC || ca->ca_type.iodc_type == HPPA_TYPE_MEMORY) return; - config_found_sm_loc(self, "mainbus", NULL, ca, mbprint, mbsubmatch); + config_found_sm_loc(self, "gedoens", NULL, ca, mbprint, mbsubmatch); } static void @@ -1500,7 +1500,7 @@ mb_cpu_mem_callback(struct device *self, struct confargs *ca) if ((ca->ca_type.iodc_type == HPPA_TYPE_NPROC || ca->ca_type.iodc_type == HPPA_TYPE_MEMORY) && ca->ca_hpa != pdc_hpa.hpa) - config_found_sm_loc(self, "mainbus", NULL, ca, mbprint, + config_found_sm_loc(self, "gedoens", NULL, ca, mbprint, mbsubmatch); } diff --git a/sys/arch/hp700/include/autoconf.h b/sys/arch/hp700/include/autoconf.h index ada499e76ebf..c76f5ec94c1a 100644 --- a/sys/arch/hp700/include/autoconf.h +++ b/sys/arch/hp700/include/autoconf.h @@ -1,4 +1,4 @@ -/* $NetBSD: autoconf.h,v 1.7 2005/12/11 12:17:24 christos Exp $ */ +/* $NetBSD: autoconf.h,v 1.8 2008/03/29 15:59:26 skrll Exp $ */ /* $OpenBSD: autoconf.h,v 1.10 2001/05/05 22:33:42 art Exp $ */ @@ -56,7 +56,7 @@ struct confargs { }; #define HP700CF_IRQ_UNDEF (-1) -#define hp700cf_irq cf_loc[MAINBUSCF_IRQ] +#define hp700cf_irq cf_loc[GEDOENSCF_IRQ] /* this is used for hppa_knownmodules table * describing known to this port modules, diff --git a/sys/conf/files b/sys/conf/files index cc49542906d9..cbb31ff1ee3e 100644 --- a/sys/conf/files +++ b/sys/conf/files @@ -1,4 +1,4 @@ -# $NetBSD: files,v 1.896 2008/03/23 14:02:49 ad Exp $ +# $NetBSD: files,v 1.897 2008/03/29 15:59:26 skrll Exp $ # @(#)files.newconf 7.5 (Berkeley) 5/10/93 @@ -1045,7 +1045,7 @@ file dev/ic/igsfb_subr.c igsfb # STI (hp graphics) device sti: wsemuldisplaydev -file dev/ic/sti.c sti & (sti_pci | sti_sgc | sti_phantom) +file dev/ic/sti.c sti & (sti_pci | sti_gedoens) include "dev/wscons/files.wscons" include "dev/rasops/files.rasops"