summaryrefslogtreecommitdiffstats
path: root/sys/dev/syscons/scvidctl.c
diff options
context:
space:
mode:
authoryokota <yokota@FreeBSD.org>1998-10-01 11:39:18 +0000
committeryokota <yokota@FreeBSD.org>1998-10-01 11:39:18 +0000
commit3d34bf047babbcd0a199d4a7bc2464a62066bc78 (patch)
treef7fcb33db5f1af78f7a852d912e39a8b0ff77fd5 /sys/dev/syscons/scvidctl.c
parent5b11e527361dc6279982c78cd72f2438aad9696e (diff)
downloadFreeBSD-src-3d34bf047babbcd0a199d4a7bc2464a62066bc78.zip
FreeBSD-src-3d34bf047babbcd0a199d4a7bc2464a62066bc78.tar.gz
Yet another round of fixes for the VESA support code.
- Express various sizes in bytes, rather than Kbytes, in the video mode and adapter information structures. - Fill 0 in the linear buffer size field if the linear frame buffer is not available. - Remove SW_VESA_USER ioctl. It is still experimetal and was not meant to be released. - Fix missing cast operator. - Correctly handle pointers returned by the VESA BIOS. The pointers may point to the area either in the BIOS ROM or in the buffer supplied by the caller. - Set the destructive cursor at the right moment.
Diffstat (limited to 'sys/dev/syscons/scvidctl.c')
-rw-r--r--sys/dev/syscons/scvidctl.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/sys/dev/syscons/scvidctl.c b/sys/dev/syscons/scvidctl.c
index e29c209..065dee2 100644
--- a/sys/dev/syscons/scvidctl.c
+++ b/sys/dev/syscons/scvidctl.c
@@ -23,7 +23,7 @@
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
- * $Id: scvidctl.c,v 1.3 1998/09/25 11:55:46 yokota Exp $
+ * $Id: scvidctl.c,v 1.4 1998/09/29 02:00:56 ache Exp $
*/
#include "sc.h"
@@ -49,7 +49,6 @@ extern scr_stat *cur_console;
extern int fonts_loaded;
extern int sc_history_size;
extern u_char palette[];
-extern int sc_flags;
int
sc_set_text_mode(scr_stat *scp, struct tty *tp, int mode, int xsize, int ysize,
@@ -122,8 +121,6 @@ sc_set_text_mode(scr_stat *scp, struct tty *tp, int mode, int xsize, int ysize,
if (scp == cur_console)
set_mode(scp);
scp->status &= ~UNKNOWN_MODE;
- if (ISTEXTSC(scp) && (sc_flags & CHAR_CURSOR))
- set_destructive_cursor(scp);
if (tp == NULL)
return 0;
@@ -251,7 +248,7 @@ sc_set_pixel_mode(scr_stat *scp, struct tty *tp, int xsize, int ysize,
* memory size is larger than 64K. Because such modes require
* bank switching to access the entire screen. XXX
*/
- if (info.vi_width*info.vi_height/8 > info.vi_window_size*1024)
+ if (info.vi_width*info.vi_height/8 > info.vi_window_size)
return ENODEV;
/* stop screen saver, etc */
@@ -383,7 +380,7 @@ sc_vid_ioctl(struct tty *tp, u_long cmd, caddr_t data, int flag, struct proc *p)
return sc_set_graphics_mode(scp, tp, cmd & 0xff);
case KDSETMODE: /* set current mode of this (virtual) console */
- switch (*data) {
+ switch (*(int *)data) {
case KD_TEXT: /* switch to TEXT (known) mode */
/*
* If scp->mode is of graphics modes, we don't know which
OpenPOWER on IntegriCloud