From: deraadt Date: Thu, 14 Dec 1995 06:04:25 +0000 (+0000) Subject: from netbsd; Make sure vt_coldinit() is called before vt_coldmalloc() X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=a1a9cd8973d2794e8cd76bc1c27bef6a2140a56d;p=openbsd from netbsd; Make sure vt_coldinit() is called before vt_coldmalloc() --- diff --git a/sys/arch/i386/isa/pcvt/pcvt_drv.c b/sys/arch/i386/isa/pcvt/pcvt_drv.c index fe7af81895c..d6aa3e27d81 100644 --- a/sys/arch/i386/isa/pcvt/pcvt_drv.c +++ b/sys/arch/i386/isa/pcvt/pcvt_drv.c @@ -159,6 +159,9 @@ pcattach(struct isa_device *dev) int i; + if(do_initialization) + vt_coldinit(); + vt_coldmalloc(); /* allocate memory for screens */ #if PCVT_NETBSD || PCVT_FREEBSD diff --git a/sys/arch/i386/isa/pcvt/pcvt_hdr.h b/sys/arch/i386/isa/pcvt/pcvt_hdr.h index 6286e439132..615e19abeb3 100644 --- a/sys/arch/i386/isa/pcvt/pcvt_hdr.h +++ b/sys/arch/i386/isa/pcvt/pcvt_hdr.h @@ -1367,6 +1367,7 @@ void vt_clreol ( struct video_state *svsp ); void vt_clreos ( struct video_state *svsp ); void vt_clrtab ( struct video_state *svsp ); int vt_col ( struct video_state *svsp, int cols ); +void vt_coldinit ( void ); void vt_coldmalloc ( void ); void vt_cub ( struct video_state *svsp ); void vt_cud ( struct video_state *svsp ); diff --git a/sys/arch/i386/isa/pcvt/pcvt_out.c b/sys/arch/i386/isa/pcvt/pcvt_out.c index 9a463527a72..167dd8f0c80 100644 --- a/sys/arch/i386/isa/pcvt/pcvt_out.c +++ b/sys/arch/i386/isa/pcvt/pcvt_out.c @@ -74,7 +74,6 @@ static void check_scroll ( struct video_state *svsp ); static void hp_entry ( U_char ch, struct video_state *svsp ); -static void vt_coldinit ( void ); static void wrfkl ( int num, u_char *string, struct video_state *svsp ); static void writefkl ( int num, u_char *string, struct video_state *svsp ); @@ -976,7 +975,7 @@ sput (u_char *s, U_char kernel, int len, int page) /*---------------------------------------------------------------------------* * this is the absolute cold initialization of the emulator *---------------------------------------------------------------------------*/ -static void +void vt_coldinit(void) { extern u_short csd_ascii[]; /* pcvt_tbl.h */