All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: [Qemu-devel] [PULL 0/7] Vga 20180927 patches
       [not found] <20180927071247.25725-1-kraxel@redhat.com>
@ 2018-10-01 11:33 ` Peter Maydell
       [not found] ` <20180927071247.25725-7-kraxel@redhat.com>
  1 sibling, 0 replies; 2+ messages in thread
From: Peter Maydell @ 2018-10-01 11:33 UTC (permalink / raw)
  To: Gerd Hoffmann; +Cc: QEMU Developers, Michael S. Tsirkin

On 27 September 2018 at 08:12, Gerd Hoffmann <kraxel@redhat.com> wrote:
> The following changes since commit c5e4e49258e9b89cb34c085a419dd9f862935c48:
>
>   Merge remote-tracking branch 'remotes/xanclic/tags/pull-block-2018-09-25' into staging (2018-09-25 16:47:35 +0100)
>
> are available in the git repository at:
>
>   git://git.kraxel.org/qemu tags/vga-20180927-pull-request
>
> for you to fetch changes up to 36ffc122dcd69ab66db4afab3a13cfca46bfc323:
>
>   qxl: support mono cursors with inverted colors (2018-09-27 08:10:07 +0200)
>
> ----------------------------------------------------------------
> vga: add edid support, qxl bugfixes.
>
> ----------------------------------------------------------------

Applied, thanks.

-- PMM

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [Qemu-devel] [PULL 6/7] qxl: use guest_monitor_config for local renderer.
       [not found] ` <20180927071247.25725-7-kraxel@redhat.com>
@ 2018-10-05 12:51   ` Peter Maydell
  0 siblings, 0 replies; 2+ messages in thread
From: Peter Maydell @ 2018-10-05 12:51 UTC (permalink / raw)
  To: Gerd Hoffmann; +Cc: QEMU Developers, Michael S. Tsirkin

On 27 September 2018 at 08:12, Gerd Hoffmann <kraxel@redhat.com> wrote:
> When processing monitor config from guest store head0 width and height
> for single-head configurations.  Use these when creating the
> DisplaySurface in the local renderer.
>
> This fixes a rendering issue with wayland.  Wayland rounds up the
> framebuffer width and height to a multiple of 64, so with odd
> resolutions (800x600 for example) the framebuffer is larger than the
> actual screen.  The monitor config has the actual screen size though.
>
> This fixes guest display for anything using the local renderer
> (non-spice UI, screendump monitor command).
>
> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
> Message-id: 20180919103057.9666-1-kraxel@redhat.com

> diff --git a/hw/display/qxl.c b/hw/display/qxl.c
> index 8e9135d9c6..747986478f 100644
> --- a/hw/display/qxl.c
> +++ b/hw/display/qxl.c
> @@ -259,6 +259,8 @@ static void qxl_spice_destroy_surfaces(PCIQXLDevice *qxl, qxl_async_io async)
>
>  static void qxl_spice_monitors_config_async(PCIQXLDevice *qxl, int replay)
>  {
> +    QXLMonitorsConfig *cfg;
> +
>      trace_qxl_spice_monitors_config(qxl->id);
>      if (replay) {
>          /*
> @@ -286,6 +288,16 @@ static void qxl_spice_monitors_config_async(PCIQXLDevice *qxl, int replay)
>                  (uintptr_t)qxl_cookie_new(QXL_COOKIE_TYPE_IO,
>                                            QXL_IO_MONITORS_CONFIG_ASYNC));
>      }
> +
> +    cfg = qxl_phys2virt(qxl, qxl->guest_monitors_config, MEMSLOT_GROUP_GUEST);
> +    if (cfg->count == 1) {
> +        qxl->guest_primary.resized = 1;
> +        qxl->guest_head0_width  = cfg->heads[0].width;
> +        qxl->guest_head0_height = cfg->heads[0].height;
> +    } else {
> +        qxl->guest_head0_width  = 0;
> +        qxl->guest_head0_height = 0;
> +    }

Hi. Coverity points out (CID 1395986) that we fail to check
the return value from qxl_phys2virt() here. It can return NULL,
in which case we'll segfault trying to dereference it.

thanks
-- PMM

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-10-05 12:51 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <20180927071247.25725-1-kraxel@redhat.com>
2018-10-01 11:33 ` [Qemu-devel] [PULL 0/7] Vga 20180927 patches Peter Maydell
     [not found] ` <20180927071247.25725-7-kraxel@redhat.com>
2018-10-05 12:51   ` [Qemu-devel] [PULL 6/7] qxl: use guest_monitor_config for local renderer Peter Maydell

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.