Page MenuHomeFreeBSD

D5739.id14598.diff
No OneTemporary

D5739.id14598.diff

Index: sys/dev/vt/hw/vga/vt_vga.c
===================================================================
--- sys/dev/vt/hw/vga/vt_vga.c
+++ sys/dev/vt/hw/vga/vt_vga.c
@@ -1229,7 +1229,16 @@
bus_space_map(sc->vga_reg_tag, VGA_REG_BASE, VGA_REG_SIZE, 0,
&sc->vga_reg_handle);
- TUNABLE_INT_FETCH("hw.vga.textmode", &textmode);
+ /*
+ * If "hw.vga.textmode" is not set and we're running on hypervisor,
+ * we use text mode by default, this is because when we're on
+ * hypervisor, vt(4) is usually much slower in graphics mode than
+ * in text mode, especially when we're on Hyper-V.
+ */
+ if (!TUNABLE_INT_FETCH("hw.vga.textmode", &textmode) &&
+ vm_guest != VM_GUEST_NO)
+ textmode = 1;
+
if (textmode) {
vd->vd_flags |= VDF_TEXTMODE;
vd->vd_width = 80;

File Metadata

Mime Type
text/plain
Expires
Fri, Feb 14, 8:28 AM (19 h, 40 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
16640006
Default Alt Text
D5739.id14598.diff (779 B)

Event Timeline