Skip to content

Commit

Permalink
fbdev/hyperv_fb: Do not clear global screen_info
Browse files Browse the repository at this point in the history
Do not clear the global instance of screen_info. If necessary, clearing
fields in screen_info should be done by architecture or firmware code
that maintains the firmware framebuffer.

Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: Javier Martinez Canillas <javierm@redhat.com>
Signed-off-by: Helge Deller <deller@gmx.de>
  • Loading branch information
Thomas Zimmermann authored and Helge Deller committed Jan 12, 2024
1 parent df67699 commit c25a19a
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions drivers/video/fbdev/hyperv_fb.c
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@
#include <linux/aperture.h>
#include <linux/module.h>
#include <linux/kernel.h>
#include <linux/screen_info.h>
#include <linux/vmalloc.h>
#include <linux/init.h>
#include <linux/completion.h>
Expand Down Expand Up @@ -1059,14 +1058,8 @@ static int hvfb_getmem(struct hv_device *hdev, struct fb_info *info)
else
aperture_remove_all_conflicting_devices(KBUILD_MODNAME);

if (!gen2vm) {
if (!gen2vm)
pci_dev_put(pdev);
} else if (IS_ENABLED(CONFIG_SYSFB)) {
/* framebuffer is reallocated, clear screen_info to avoid misuse from kexec */
screen_info.lfb_size = 0;
screen_info.lfb_base = 0;
screen_info.orig_video_isVGA = 0;
}

return 0;

Expand Down

0 comments on commit c25a19a

Please sign in to comment.