Wed Dec 14 13:19:05 2022 UTC ()
if we have the ROM font, make it available to wsdisplay
needs testing on non-macppc


(macallan)
diff -r1.24 -r1.25 src/sys/arch/powerpc/oea/ofw_autoconf.c

cvs diff -r1.24 -r1.25 src/sys/arch/powerpc/oea/ofw_autoconf.c (expand / switch to unified diff)

--- src/sys/arch/powerpc/oea/ofw_autoconf.c 2019/11/27 21:07:32 1.24
+++ src/sys/arch/powerpc/oea/ofw_autoconf.c 2022/12/14 13:19:04 1.25
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1/* $NetBSD: ofw_autoconf.c,v 1.24 2019/11/27 21:07:32 joerg Exp $ */ 1/* $NetBSD: ofw_autoconf.c,v 1.25 2022/12/14 13:19:04 macallan Exp $ */
2/* 2/*
3 * Copyright (C) 1995, 1996 Wolfgang Solfrank. 3 * Copyright (C) 1995, 1996 Wolfgang Solfrank.
4 * Copyright (C) 1995, 1996 TooLs GmbH. 4 * Copyright (C) 1995, 1996 TooLs GmbH.
5 * All rights reserved. 5 * All rights reserved.
6 * 6 *
7 * Redistribution and use in source and binary forms, with or without 7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions 8 * modification, are permitted provided that the following conditions
9 * are met: 9 * are met:
10 * 1. Redistributions of source code must retain the above copyright 10 * 1. Redistributions of source code must retain the above copyright
11 * notice, this list of conditions and the following disclaimer. 11 * notice, this list of conditions and the following disclaimer.
12 * 2. Redistributions in binary form must reproduce the above copyright 12 * 2. Redistributions in binary form must reproduce the above copyright
13 * notice, this list of conditions and the following disclaimer in the 13 * notice, this list of conditions and the following disclaimer in the
14 * documentation and/or other materials provided with the distribution. 14 * documentation and/or other materials provided with the distribution.
@@ -21,27 +21,27 @@ @@ -21,27 +21,27 @@
21 * THIS SOFTWARE IS PROVIDED BY TOOLS GMBH ``AS IS'' AND ANY EXPRESS OR 21 * THIS SOFTWARE IS PROVIDED BY TOOLS GMBH ``AS IS'' AND ANY EXPRESS OR
22 * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 22 * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
23 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 23 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
24 * IN NO EVENT SHALL TOOLS GMBH BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 24 * IN NO EVENT SHALL TOOLS GMBH BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
25 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, 25 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
26 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; 26 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
27 * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 27 * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
28 * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR 28 * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
29 * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 29 * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
30 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31 */ 31 */
32 32
33#include <sys/cdefs.h> 33#include <sys/cdefs.h>
34__KERNEL_RCSID(0, "$NetBSD: ofw_autoconf.c,v 1.24 2019/11/27 21:07:32 joerg Exp $"); 34__KERNEL_RCSID(0, "$NetBSD: ofw_autoconf.c,v 1.25 2022/12/14 13:19:04 macallan Exp $");
35 35
36#ifdef ofppc 36#ifdef ofppc
37#include "gtpci.h" 37#include "gtpci.h"
38#endif 38#endif
39 39
40#include <sys/param.h> 40#include <sys/param.h>
41#include <sys/conf.h> 41#include <sys/conf.h>
42#include <sys/device.h> 42#include <sys/device.h>
43#include <sys/reboot.h> 43#include <sys/reboot.h>
44#include <sys/systm.h> 44#include <sys/systm.h>
45 45
46#include <uvm/uvm_extern.h> 46#include <uvm/uvm_extern.h>
47 47
@@ -51,42 +51,48 @@ __KERNEL_RCSID(0, "$NetBSD: ofw_autoconf @@ -51,42 +51,48 @@ __KERNEL_RCSID(0, "$NetBSD: ofw_autoconf
51#include <dev/ofw/openfirm.h> 51#include <dev/ofw/openfirm.h>
52#include <dev/marvell/marvellvar.h> 52#include <dev/marvell/marvellvar.h>
53#include <dev/pci/pcireg.h> 53#include <dev/pci/pcireg.h>
54#include <dev/pci/pcivar.h> 54#include <dev/pci/pcivar.h>
55#if NGTPCI > 0 55#if NGTPCI > 0
56#include <dev/marvell/gtpcivar.h> 56#include <dev/marvell/gtpcivar.h>
57#endif 57#endif
58#include <dev/scsipi/scsi_all.h> 58#include <dev/scsipi/scsi_all.h>
59#include <dev/scsipi/scsipi_all.h> 59#include <dev/scsipi/scsipi_all.h>
60#include <dev/scsipi/scsiconf.h> 60#include <dev/scsipi/scsiconf.h>
61#include <dev/ata/atavar.h> 61#include <dev/ata/atavar.h>
62#include <dev/ic/wdcvar.h> 62#include <dev/ic/wdcvar.h>
63 63
 64#include <dev/wscons/wsconsio.h>
 65#include <dev/wscons/wsdisplayvar.h>
 66#include <dev/rasops/rasops.h>
 67#include <powerpc/oea/ofw_rasconsvar.h>
 68
64#include <machine/pci_machdep.h> 69#include <machine/pci_machdep.h>
65 70
66#include <prop/proplib.h> 71#include <prop/proplib.h>
67 72
68extern char bootpath[256]; 73extern char bootpath[256];
69char cbootpath[256]; 74char cbootpath[256];
70static int boot_node = 0; /* points at boot device if we netboot */ 75static int boot_node = 0; /* points at boot device if we netboot */
71 76
72static void canonicalize_bootpath(void); 77static void canonicalize_bootpath(void);
73 78
74/* 79/*
75 * Determine device configuration for a machine. 80 * Determine device configuration for a machine.
76 */ 81 */
77void 82void
78cpu_configure(void) 83cpu_configure(void)
79{ 84{
 85 rascons_add_rom_font();
80 init_interrupt(); 86 init_interrupt();
81 canonicalize_bootpath(); 87 canonicalize_bootpath();
82 88
83 if (config_rootfound("mainbus", NULL) == NULL) 89 if (config_rootfound("mainbus", NULL) == NULL)
84 panic("configure: mainbus not configured"); 90 panic("configure: mainbus not configured");
85 91
86 genppc_cpu_configure(); 92 genppc_cpu_configure();
87} 93}
88 94
89static void 95static void
90canonicalize_bootpath(void) 96canonicalize_bootpath(void)
91{ 97{
92 int node, len; 98 int node, len;