[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen staging] x86/ACPI: restore VESA mode upon resume from S3



commit d1235883bf4e61be0b38e6393d445374b6e52492
Author:     Jan Beulich <jbeulich@xxxxxxxx>
AuthorDate: Mon Sep 2 14:41:19 2019 +0200
Commit:     Jan Beulich <jbeulich@xxxxxxxx>
CommitDate: Mon Sep 2 14:41:19 2019 +0200

    x86/ACPI: restore VESA mode upon resume from S3
    
    In order for "acpi_sleep=s3_mode" to have any effect, we should record
    the video mode we switched to during boot. Since right now there's mode
    setting code for VESA modes only in the resume case, record the mode
    just in that one case.
    
    Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>
    Acked-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
---
 xen/arch/x86/boot/video.S | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/xen/arch/x86/boot/video.S b/xen/arch/x86/boot/video.S
index 335a51c9b5..20097aa643 100644
--- a/xen/arch/x86/boot/video.S
+++ b/xen/arch/x86/boot/video.S
@@ -455,14 +455,17 @@ check_vesa:
         cmpb    $0x99, %al
         jnz     _setbad                 # Doh! No linear frame buffer.
 
+        pushw   %bx
         subb    $VIDEO_FIRST_VESA>>8, %bh
         orw     $0x4000, %bx            # Use linear frame buffer
         movw    $0x4f02, %ax            # VESA BIOS mode set call
         int     $0x10
+        popw    %bx
         cmpw    $0x004f, %ax            # AL=4f if implemented
         jnz     _setbad                 # AH=0 if OK
 
         movb    $1, bootsym(graphic_mode)  # flag graphic mode
+        movw    %bx, bootsym(video_mode)
         stc
         ret
 
--
generated by git-patchbot for /home/xen/git/xen.git#staging

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/xen-changelog

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.