summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authornyan <nyan@FreeBSD.org>2000-03-29 12:26:41 +0000
committernyan <nyan@FreeBSD.org>2000-03-29 12:26:41 +0000
commited031b005eaa9ea1bc4a341fcae0790ea6050813 (patch)
treebe478d8aad3bbcf6eae6833a4349d25a50350eea
parent409bbf806052ec3deb6fa3c7f799afeb0559dfb7 (diff)
downloadFreeBSD-src-ed031b005eaa9ea1bc4a341fcae0790ea6050813.zip
FreeBSD-src-ed031b005eaa9ea1bc4a341fcae0790ea6050813.tar.gz
Merge from the following changes.
File Revision sys/conf/files.i386 1.303 and 1.304 sys/dev/kbd/atkbd.c 1.23 sys/dev/syscons/scterm-sc.c 1.2 sys/dev/syscons/scvgarndr.c 1.5 sys/dev/syscons/scvtb.c 1.5 sys/dev/syscons/syscons.c 1.335 sys/isa/syscons_isa.c 1.11 sys/isa/vga_isa.c 1.17
-rw-r--r--sys/conf/files.pc988
-rw-r--r--sys/pc98/cbus/gdc.c5
-rw-r--r--sys/pc98/cbus/pckbd.c4
-rw-r--r--sys/pc98/cbus/scgdcrndr.c6
-rw-r--r--sys/pc98/cbus/scterm-sck.c5
-rw-r--r--sys/pc98/cbus/scvtb.c5
-rw-r--r--sys/pc98/cbus/syscons_cbus.c9
-rw-r--r--sys/pc98/pc98/pc98gdc.c5
-rw-r--r--sys/pc98/pc98/pc98kbd.c4
-rw-r--r--sys/pc98/pc98/scgdcrndr.c6
-rw-r--r--sys/pc98/pc98/scterm-sck.c5
-rw-r--r--sys/pc98/pc98/scvtbpc98.c5
-rw-r--r--sys/pc98/pc98/syscons.c4
-rw-r--r--sys/pc98/pc98/syscons_pc98.c9
14 files changed, 10 insertions, 70 deletions
diff --git a/sys/conf/files.pc98 b/sys/conf/files.pc98
index 5b4d9df..10334760 100644
--- a/sys/conf/files.pc98
+++ b/sys/conf/files.pc98
@@ -305,7 +305,7 @@ pc98/pc98/syscons.c optional sc
pc98/pc98/syscons_pc98.c optional sc
dev/syscons/schistory.c optional sc
dev/syscons/scmouse.c optional sc
-pc98/pc98/scgdcrndr.c optional sc
+pc98/pc98/scgdcrndr.c optional sc gdc
dev/syscons/scterm.c optional sc
dev/syscons/scterm-dumb.c optional sc
pc98/pc98/scterm-sck.c optional sc
@@ -315,9 +315,9 @@ dev/syscons/sysmouse.c optional sc
i386/isa/tw.c optional tw
pc98/pc98/wd.c optional wdc
pc98/pc98/wd.c optional wd
-pc98/pc98/wd_cd.c optional wcd
-pc98/pc98/wfd.c optional wfd
-pc98/pc98/wst.c optional wst
+pc98/pc98/wd_cd.c optional wcd wdc
+pc98/pc98/wfd.c optional wfd wdc
+pc98/pc98/wst.c optional wst wdc
i386/isa/wt.c optional wt
i386/linux/imgact_linux.c optional compat_linux
i386/linux/linux_dummy.c optional compat_linux
diff --git a/sys/pc98/cbus/gdc.c b/sys/pc98/cbus/gdc.c
index d3f6d92..26dcb43 100644
--- a/sys/pc98/cbus/gdc.c
+++ b/sys/pc98/cbus/gdc.c
@@ -28,13 +28,10 @@
* $FreeBSD$
*/
-#include "gdc.h"
#include "opt_gdc.h"
#include "opt_fb.h"
#include "opt_syscons.h"
-#if NGDC > 0
-
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/kernel.h>
@@ -1077,5 +1074,3 @@ gdc_diag(video_adapter_t *adp, int level)
return 0;
}
-
-#endif /* NGDC > 0 */
diff --git a/sys/pc98/cbus/pckbd.c b/sys/pc98/cbus/pckbd.c
index b4eb148..d46edbf 100644
--- a/sys/pc98/cbus/pckbd.c
+++ b/sys/pc98/cbus/pckbd.c
@@ -31,8 +31,6 @@
#include "pckbd.h"
#include "opt_kbd.h"
-#if NPCKBD > 0
-
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/kernel.h>
@@ -927,5 +925,3 @@ read_kbd_data_no_wait(KBDC p)
}
return -1; /* no data */
}
-
-#endif /* NPCKBD > 0 */
diff --git a/sys/pc98/cbus/scgdcrndr.c b/sys/pc98/cbus/scgdcrndr.c
index 22a6d5d..33f2ea1 100644
--- a/sys/pc98/cbus/scgdcrndr.c
+++ b/sys/pc98/cbus/scgdcrndr.c
@@ -26,13 +26,9 @@
* $FreeBSD$
*/
-#include "sc.h"
-#include "gdc.h"
#include "opt_syscons.h"
#include "opt_gdc.h"
-#if NSC > 0 && NGDC > 0
-
#include <sys/param.h>
#include <sys/kernel.h>
@@ -199,5 +195,3 @@ gdc_grborder(scr_stat *scp, int color)
}
#endif /* SC_NO_MODE_CHANGE */
-
-#endif /* NSC > 0 && NGDC > 0 */
diff --git a/sys/pc98/cbus/scterm-sck.c b/sys/pc98/cbus/scterm-sck.c
index ec09274..bc69200 100644
--- a/sys/pc98/cbus/scterm-sck.c
+++ b/sys/pc98/cbus/scterm-sck.c
@@ -26,11 +26,8 @@
* $FreeBSD$
*/
-#include "sc.h"
#include "opt_syscons.h"
-#if NSC > 0
-
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/kernel.h>
@@ -1106,5 +1103,3 @@ kanji_convert(u_char mode, u_char h, u_char l)
#endif /* KANJI */
#endif /* SC_DUMB_TERMINAL */
-
-#endif /* NSC > 0 */
diff --git a/sys/pc98/cbus/scvtb.c b/sys/pc98/cbus/scvtb.c
index 1c0be2c..7677442 100644
--- a/sys/pc98/cbus/scvtb.c
+++ b/sys/pc98/cbus/scvtb.c
@@ -26,11 +26,8 @@
* $FreeBSD$
*/
-#include "sc.h"
#include "opt_syscons.h"
-#if NSC > 0
-
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/malloc.h>
@@ -405,5 +402,3 @@ sc_vtb_ins(sc_vtb_t *vtb, int at, int count, int c, int attr)
(void *)sc_vtb_attr_pointer(vtb, at), count);
}
}
-
-#endif /* NSC */
diff --git a/sys/pc98/cbus/syscons_cbus.c b/sys/pc98/cbus/syscons_cbus.c
index d4f5bd1..7a8b584 100644
--- a/sys/pc98/cbus/syscons_cbus.c
+++ b/sys/pc98/cbus/syscons_cbus.c
@@ -26,11 +26,8 @@
* $FreeBSD$
*/
-#include "sc.h"
#include "opt_syscons.h"
-#if NSC > 0
-
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/kernel.h>
@@ -105,13 +102,15 @@ sc_softc_t
{
sc_softc_t *sc;
- if ((unit < 0) || (unit >= NSC))
+ if (unit < 0)
return NULL;
if (flags & SC_KERNEL_CONSOLE) {
/* FIXME: clear if it is wired to another unit! */
sc = &main_softc;
} else {
sc = (sc_softc_t *)device_get_softc(devclass_get_device(sc_devclass, unit));
+ if (sc == NULL)
+ return NULL;
}
sc->unit = unit;
if (!(sc->flags & SC_INIT_DONE)) {
@@ -213,5 +212,3 @@ sc_tone(int herz)
}
DRIVER_MODULE(sc, isa, sc_driver, sc_devclass, 0, 0);
-
-#endif /* NSC > 0 */
diff --git a/sys/pc98/pc98/pc98gdc.c b/sys/pc98/pc98/pc98gdc.c
index d3f6d92..26dcb43 100644
--- a/sys/pc98/pc98/pc98gdc.c
+++ b/sys/pc98/pc98/pc98gdc.c
@@ -28,13 +28,10 @@
* $FreeBSD$
*/
-#include "gdc.h"
#include "opt_gdc.h"
#include "opt_fb.h"
#include "opt_syscons.h"
-#if NGDC > 0
-
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/kernel.h>
@@ -1077,5 +1074,3 @@ gdc_diag(video_adapter_t *adp, int level)
return 0;
}
-
-#endif /* NGDC > 0 */
diff --git a/sys/pc98/pc98/pc98kbd.c b/sys/pc98/pc98/pc98kbd.c
index b4eb148..d46edbf 100644
--- a/sys/pc98/pc98/pc98kbd.c
+++ b/sys/pc98/pc98/pc98kbd.c
@@ -31,8 +31,6 @@
#include "pckbd.h"
#include "opt_kbd.h"
-#if NPCKBD > 0
-
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/kernel.h>
@@ -927,5 +925,3 @@ read_kbd_data_no_wait(KBDC p)
}
return -1; /* no data */
}
-
-#endif /* NPCKBD > 0 */
diff --git a/sys/pc98/pc98/scgdcrndr.c b/sys/pc98/pc98/scgdcrndr.c
index 22a6d5d..33f2ea1 100644
--- a/sys/pc98/pc98/scgdcrndr.c
+++ b/sys/pc98/pc98/scgdcrndr.c
@@ -26,13 +26,9 @@
* $FreeBSD$
*/
-#include "sc.h"
-#include "gdc.h"
#include "opt_syscons.h"
#include "opt_gdc.h"
-#if NSC > 0 && NGDC > 0
-
#include <sys/param.h>
#include <sys/kernel.h>
@@ -199,5 +195,3 @@ gdc_grborder(scr_stat *scp, int color)
}
#endif /* SC_NO_MODE_CHANGE */
-
-#endif /* NSC > 0 && NGDC > 0 */
diff --git a/sys/pc98/pc98/scterm-sck.c b/sys/pc98/pc98/scterm-sck.c
index ec09274..bc69200 100644
--- a/sys/pc98/pc98/scterm-sck.c
+++ b/sys/pc98/pc98/scterm-sck.c
@@ -26,11 +26,8 @@
* $FreeBSD$
*/
-#include "sc.h"
#include "opt_syscons.h"
-#if NSC > 0
-
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/kernel.h>
@@ -1106,5 +1103,3 @@ kanji_convert(u_char mode, u_char h, u_char l)
#endif /* KANJI */
#endif /* SC_DUMB_TERMINAL */
-
-#endif /* NSC > 0 */
diff --git a/sys/pc98/pc98/scvtbpc98.c b/sys/pc98/pc98/scvtbpc98.c
index 1c0be2c..7677442 100644
--- a/sys/pc98/pc98/scvtbpc98.c
+++ b/sys/pc98/pc98/scvtbpc98.c
@@ -26,11 +26,8 @@
* $FreeBSD$
*/
-#include "sc.h"
#include "opt_syscons.h"
-#if NSC > 0
-
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/malloc.h>
@@ -405,5 +402,3 @@ sc_vtb_ins(sc_vtb_t *vtb, int at, int count, int c, int attr)
(void *)sc_vtb_attr_pointer(vtb, at), count);
}
}
-
-#endif /* NSC */
diff --git a/sys/pc98/pc98/syscons.c b/sys/pc98/pc98/syscons.c
index 7ddbdd2..3d195f3 100644
--- a/sys/pc98/pc98/syscons.c
+++ b/sys/pc98/pc98/syscons.c
@@ -28,7 +28,6 @@
* $FreeBSD$
*/
-#include "sc.h"
#include "splash.h"
#include "opt_syscons.h"
#include "opt_ddb.h"
@@ -36,7 +35,6 @@
#include "apm.h"
#endif
-#if NSC > 0
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/eventhandler.h>
@@ -3428,5 +3426,3 @@ blink_screen(void *arg)
timeout(blink_screen, scp, hz / 10);
}
}
-
-#endif /* NSC */
diff --git a/sys/pc98/pc98/syscons_pc98.c b/sys/pc98/pc98/syscons_pc98.c
index d4f5bd1..7a8b584 100644
--- a/sys/pc98/pc98/syscons_pc98.c
+++ b/sys/pc98/pc98/syscons_pc98.c
@@ -26,11 +26,8 @@
* $FreeBSD$
*/
-#include "sc.h"
#include "opt_syscons.h"
-#if NSC > 0
-
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/kernel.h>
@@ -105,13 +102,15 @@ sc_softc_t
{
sc_softc_t *sc;
- if ((unit < 0) || (unit >= NSC))
+ if (unit < 0)
return NULL;
if (flags & SC_KERNEL_CONSOLE) {
/* FIXME: clear if it is wired to another unit! */
sc = &main_softc;
} else {
sc = (sc_softc_t *)device_get_softc(devclass_get_device(sc_devclass, unit));
+ if (sc == NULL)
+ return NULL;
}
sc->unit = unit;
if (!(sc->flags & SC_INIT_DONE)) {
@@ -213,5 +212,3 @@ sc_tone(int herz)
}
DRIVER_MODULE(sc, isa, sc_driver, sc_devclass, 0, 0);
-
-#endif /* NSC > 0 */
OpenPOWER on IntegriCloud