[PATCH v6 4/6] libweston: fbdev: set fb device info upon the first run.

Pekka Paalanen ppaalanen at gmail.com
Tue Jun 12 12:34:32 UTC 2018


On Tue, 23 Jan 2018 22:15:46 -0500
nerdopolis <bluescreen_avenger at verizon.net> wrote:

> This attempts to wake up secondary framebuffer devices
> (/dev/fb1 and up) as usually these devices start powered off, and
> the FBIOPUT_VSCREENINFO ioctl turns it on. This was tested on a
> qemu system with the options:
> 
> -vga none -device VGA,id=video0 -device secondary-vga,id=video1 \
> -device secondary-vga,id=video2
> ---
>  libweston/compositor-fbdev.c | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/libweston/compositor-fbdev.c b/libweston/compositor-fbdev.c
> index ef571339..39668aa8 100644
> --- a/libweston/compositor-fbdev.c
> +++ b/libweston/compositor-fbdev.c
> @@ -361,6 +361,13 @@ fbdev_frame_buffer_open(const char *fb_dev,
>  		return -1;
>  	}
>  
> +	/* Attempt to correct the framebuffer settings */

This comment should say the same as the commit message: attempt to turn
on the fb device, needed for secondary devices.

> +	if (fbdev_set_screen_info(fd, screen_info) < 0) {
> +		weston_log("Failed to set mode settings. "
> +		           "Attempting to open output anyway.\n");
> +	}
> +
> +

Loigcally this is not the right place to call fbdev_set_screen_info(),
but then again there is so much wrong in the fbdev-backend logic
already and I cannot care about fbdev.

It doesn't regress on my desktop, so:
Reviewed-by: Pekka Paalanen <pekka.paalanen at collabora.co.uk>

>  	return fd;
>  }
>  

Thanks,
pq
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <https://lists.freedesktop.org/archives/wayland-devel/attachments/20180612/01d32dab/attachment.sig>


More information about the wayland-devel mailing list