x86/boot: don't blindly mark VGA in graphics mode on MB2 path
PATCH 1/1 x86/boot: don't blindly mark VGA in graphics mode on MB2 path
Setting ->orig_video_isVGA to the specific marker should be done only when the VBE tag is present and the FRAMEBUFFER is either absent or indicates RGB type. Since the "video" variable now starts out non-NULL, this property was broken when in particular neither of the tags are present. To move back to at least close to original behavior, add a 2nd check to said conditional.
xen/arch/x86/boot/reloc.c +1 -1
@@ -339,7 +339,7 @@ static multiboot_info_t *mbi2_reloc(uint end:#ifdef CONFIG_VIDEO -if ( video ) +if ( video && video->lfb_size ) video->orig_video_isVGA =0x23 ;#endif
Quoted 11 lines · Jan Beulich
Setting ->orig_video_isVGA to the specific marker should be done only when the VBE tag is present and the FRAMEBUFFER is either absent or indicates RGB type. Since the "video" variable now starts out non-NULL, this property was broken when in particular neither of the tags are present. To move back to at least close to original behavior, add a 2nd check to said conditional.
Fixes d5a73cdc6b90 ("x86/boot: Use boot_vid_info variable directly from C code")Reported-by Marek Marczykowski-Górecki <[email protected]>Signed-off-by Jan Beulich <[email protected]>
Quoted 11 lines · Jan Beulich
Setting ->orig_video_isVGA to the specific marker should be done only when the VBE tag is present and the FRAMEBUFFER is either absent or indicates RGB type. Since the "video" variable now starts out non-NULL, this property was broken when in particular neither of the tags are present. To move back to at least close to original behavior, add a 2nd check to said conditional.
Fixes d5a73cdc6b90 ("x86/boot: Use boot_vid_info variable directly from C code")Reported-by Marek Marczykowski-Górecki <[email protected]>Signed-off-by Jan Beulich <[email protected]>
~ Oleksii
Le 24/06/2026 à 12:24, Jan Beulich a écrit :
Quoted 15 lines
Setting ->orig_video_isVGA to the specific marker should be done only when the VBE tag is present and the FRAMEBUFFER is either absent or indicates RGB type. Since the "video" variable now starts out non-NULL, this property was broken when in particular neither of the tags are present. To move back to at least close to original behavior, add a 2nd check to said conditional.
Fixes d5a73cdc6b90 ("x86/boot: Use boot_vid_info variable directly from C code")Reported-by Marek Marczykowski-Górecki <[email protected]>Signed-off-by Jan Beulich <[email protected]>
xen/arch/x86/boot/reloc.c static multiboot_info_t *mbi2_reloc(uint · line 345
Quoted 8 lines
xen/arch/x86/boot/reloc.c +1
-1@@ -339,7 +339,7 @@ static multiboot_info_t *mbi2_reloc(uint end:#ifdef CONFIG_VIDEO -if ( video ) +if ( video && video->lfb_size ) video->orig_video_isVGA =0x23 ;#endif
Teddy