Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 5 Sep 2014 18:11:39 +0000 (UTC)
From:      Jean-Sebastien Pedron <dumbbell@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r271180 - head/sys/dev/vt/hw/vga
Message-ID:  <201409051811.s85IBdoH050811@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: dumbbell
Date: Fri Sep  5 18:11:39 2014
New Revision: 271180
URL: http://svnweb.freebsd.org/changeset/base/271180

Log:
  vt_vga: vd_setpixel_t and vd_drawrect_t are noop in text mode
  
  MFC after:	3 days

Modified:
  head/sys/dev/vt/hw/vga/vt_vga.c

Modified: head/sys/dev/vt/hw/vga/vt_vga.c
==============================================================================
--- head/sys/dev/vt/hw/vga/vt_vga.c	Fri Sep  5 18:11:36 2014	(r271179)
+++ head/sys/dev/vt/hw/vga/vt_vga.c	Fri Sep  5 18:11:39 2014	(r271180)
@@ -352,6 +352,9 @@ static void
 vga_setpixel(struct vt_device *vd, int x, int y, term_color_t color)
 {
 
+	if (vd->vd_flags & VDF_TEXTMODE)
+		return;
+
 	vga_bitblt_put(vd, (y * VT_VGA_WIDTH / 8) + (x / 8), color,
 	    0x80 >> (x % 8));
 }
@@ -362,6 +365,9 @@ vga_drawrect(struct vt_device *vd, int x
 {
 	int x, y;
 
+	if (vd->vd_flags & VDF_TEXTMODE)
+		return;
+
 	for (y = y1; y <= y2; y++) {
 		if (fill || (y == y1) || (y == y2)) {
 			for (x = x1; x <= x2; x++)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201409051811.s85IBdoH050811>