From: kettenis Date: Mon, 30 Jul 2018 19:40:53 +0000 (+0000) Subject: If we keep the BIOS framebuffer, stick to the desired framebuffer size X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=141e54329c5e5154a90a7a874aee990007e949ae;p=openbsd If we keep the BIOS framebuffer, stick to the desired framebuffer size instead of using the actual framebuffer size. This fixes a problem seen on various Apple machines where the BIOS framebuffer is bigger than the actual display. ok jcs@, mpi@ --- diff --git a/sys/dev/pci/drm/i915/intel_fbdev.c b/sys/dev/pci/drm/i915/intel_fbdev.c index bf221b05b50..a03b13dc0e9 100644 --- a/sys/dev/pci/drm/i915/intel_fbdev.c +++ b/sys/dev/pci/drm/i915/intel_fbdev.c @@ -220,8 +220,10 @@ static int intelfb_create(struct drm_fb_helper *helper, } else { DRM_DEBUG_KMS("re-using BIOS fb\n"); prealloc = true; +#ifdef __linux__ sizes->fb_width = intel_fb->base.width; sizes->fb_height = intel_fb->base.height; +#endif } obj = intel_fb->obj;