Re: [PATCH RFC v1 1/1] ui/sdl2: clipboard sharing implementation for SDL

2025-07-30 Thread Marc-André Lureau
!text) { > - ``` > qemu_log_mask(LOG_GUEST_ERROR, > ``` > - ``` >"SDL clipboard: Failed to get clipboard text: %s\n", > ``` > - ``` >SDL_GetError()); > ``` > - ``` > return; > ``` > - } > - > - if (text[0] == ‘\0’) {

Re: [PATCH RFC v1 1/1] ui/sdl2: clipboard sharing implementation for SDL

2025-07-30 Thread Marc-André Lureau
> +qemu_log_mask(LOG_GUEST_ERROR, > + "SDL clipboard: Failed to get clipboard text: %s\n", > + SDL_GetError()); > +return; > +} > + > +if (text[0] == '\0') { > +return; /* Ignore empty clipbo

Re: [PATCH RFC v1 1/1] ui/sdl2: clipboard sharing implementation for SDL

2025-07-30 Thread Marc-André Lureau
ext[0] == '\0') { > +return; /* Ignore empty clipboard */ > +} > + > +info = qemu_clipboard_info_new(&scon->cbpeer, > QEMU_CLIPBOARD_SELECTION_CLIPBOARD); > +qemu_clipboard_set_data(&scon->cbpeer, info, QEMU_CLIPBOARD_TYPE_TEXT, >

Re: [PATCH RFC v1 1/1] ui/sdl2: clipboard sharing implementation for SDL

2025-07-29 Thread Marc-André Lureau
dInfo) info = > +qemu_clipboard_info_new(&scon->cbpeer, > +QEMU_CLIPBOARD_SELECTION_CLIPBOARD); > + > +if (info) { qemu_clipboard_info_new never returns NULL > +sdl2_clipboard_request(info, QEMU_CLIPBOARD_TYPE_TEXT); > + } > +} > + > +void sdl2_clipboard_init(struct sdl2_console *scon) > +{ > +scon->cbpeer.name = "sdl2"; > +scon->cbpeer.notifier.notify = sdl2_clipboard_notify; > +scon->cbpeer.request = sdl2_clipboard_request; > + > +/* Register the clipboard peer with QEMU */ > +qemu_clipboard_peer_register(&scon->cbpeer); > +} > + > +#endif /* CONFIG_SDL_CLIPBOARD */ > diff --git a/ui/sdl2.c b/ui/sdl2.c > index 1a83c3b1bf..5678930d3c 100644 > --- a/ui/sdl2.c > +++ b/ui/sdl2.c > @@ -691,6 +691,11 @@ void sdl2_poll_events(struct sdl2_console *scon) > case SDL_WINDOWEVENT: > handle_windowevent(ev); > break; > +#ifdef CONFIG_SDL_CLIPBOARD > +case SDL_CLIPBOARDUPDATE: > +sdl2_clipboard_handle_request(scon); > +break; > +#endif > default: > break; > } > @@ -914,6 +919,9 @@ static void sdl2_display_init(DisplayState *ds, > DisplayOptions *o) > qemu_console_set_window_id(con, info.info.x11.window); > #endif > } > +#ifdef CONFIG_SDL_CLIPBOARD > +sdl2_clipboard_init(&sdl2_console[i]); > +#endif > } > > #ifdef CONFIG_SDL_IMAGE > -- Marc-André Lureau

Re: [PATCH v7 23/24] migration: Add error-parameterized function variants in VMSD struct

2025-07-28 Thread Marc-André Lureau
Hi On Fri, Jul 25, 2025 at 4:22 PM Arun Menon wrote: > - We need to have good error reporting in the callbacks in > VMStateDescription struct. Specifically pre_save, post_save, > pre_load and post_load callbacks. > - It is not possible to change these functions everywhere in one > patch, t

Re: [PATCH v7 22/24] migration: Capture error in postcopy_ram_listen_thread()

2025-07-28 Thread Marc-André Lureau
e > coroutine also reports the error in case of failure, with > error_report_err(). Otherwise, the source qemu will not display > any errors before going into the postcopy pause state. > > Signed-off-by: Arun Menon > Reviewed-by: Marc-André Lureau > --- > migra

Re: [PATCH v7 08/24] migration: make loadvm_postcopy_handle_resume() void

2025-07-28 Thread Marc-André Lureau
Hi On Fri, Jul 25, 2025 at 4:20 PM Arun Menon wrote: > This is an incremental step in converting vmstate loading > code to report error via Error objects instead of directly > printing it to console/monitor. > > Reviewed-by: Daniel P. Berrangé > Signed-off-by: Arun Menon > --- > migration/sav

Re: [PATCH v7 02/24] migration: push Error **errp into vmstate_load_state()

2025-07-28 Thread Marc-André Lureau
Hi On Fri, Jul 25, 2025 at 5:48 PM Marc-André Lureau < marcandre.lur...@redhat.com> wrote: > > > On Fri, Jul 25, 2025 at 4:19 PM Arun Menon wrote: > >> This is an incremental step in converting vmstate loading >> code to report error via Error objects instead

Re: [PATCH v7 01/24] migration: push Error **errp into vmstate_subsection_load()

2025-07-28 Thread Marc-André Lureau
Hi On Mon, Jul 28, 2025 at 1:06 PM Daniel P. Berrangé wrote: > > On Mon, Jul 28, 2025 at 12:44:53PM +0400, Marc-André Lureau wrote: > > Hi > > > > On Fri, Jul 25, 2025 at 5:46 PM Marc-André Lureau < > > marcandre.lur...@redhat.com> wrote: > > > &g

Re: [PATCH v7 12/24] migration: push Error **errp into loadvm_postcopy_handle_advise()

2025-07-28 Thread Marc-André Lureau
gt; in errp, in case of failure. > > Reviewed-by: Daniel P. Berrangé > Signed-off-by: Arun Menon > Reviewed-by: Marc-André Lureau > --- > migration/savevm.c | 40 +++- > 1 file changed, 19 insertions(+), 21 deletions(-) > > diff --git

Re: [PATCH v7 11/24] migration: push Error **errp into ram_postcopy_incoming_init()

2025-07-28 Thread Marc-André Lureau
n errp, in case of failure. > > Signed-off-by: Arun Menon > Reviewed-by: Marc-André Lureau > --- > migration/postcopy-ram.c | 9 ++--- > migration/postcopy-ram.h | 2 +- > migration/ram.c | 4 ++-- > migration/ram.h | 2 +- > migration/sa

Re: [PATCH v7 09/24] migration: push Error **errp into loadvm_process_command()

2025-07-28 Thread Marc-André Lureau
HOVER_START: > - return loadvm_postcopy_handle_switchover_start(); > +ret = loadvm_postcopy_handle_switchover_start(); > +if (ret < 0) { > +error_setg(errp, "Failed to load device state command: %d", > ret); > +} > +return ret; > } > > return 0; > @@ -3075,7 +3108,7 @@ retry: > } > break; > case QEMU_VM_COMMAND: > -ret = loadvm_process_command(f); > +ret = loadvm_process_command(f, NULL); > trace_qemu_loadvm_state_section_command(ret); > if ((ret < 0) || (ret == LOADVM_QUIT)) { > goto out; > > -- > 2.50.0 > Reviewed-by: Marc-André Lureau

Re: [PATCH v7 07/24] migration: Update qemu_file_get_return_path() docs and remove dead checks

2025-07-28 Thread Marc-André Lureau
LL. > > As a result, the NULL checks post calling the function become redundant. > This commit updates the documentation for the function and removes all > NULL checks throughout the migration code. > > Reviewed-by: Daniel P. Berrangé > Signed-off-by: Arun Menon

Re: [PATCH v7 01/24] migration: push Error **errp into vmstate_subsection_load()

2025-07-28 Thread Marc-André Lureau
Hi On Fri, Jul 25, 2025 at 5:46 PM Marc-André Lureau < marcandre.lur...@redhat.com> wrote: > > > On Fri, Jul 25, 2025 at 4:19 PM Arun Menon wrote: > >> This is an incremental step in converting vmstate loading >> code to report error via Error objects instead

Re: [PATCH v7 04/24] migration: push Error **errp into vmstate_load()

2025-07-25 Thread Marc-André Lureau
case of failure. > > Signed-off-by: Arun Menon > Reviewed-by: Marc-André Lureau > --- > migration/savevm.c | 16 +++- > 1 file changed, 11 insertions(+), 5 deletions(-) > > diff --git a/migration/savevm.c b/migration/savevm.c > index

Re: [PATCH v7 03/24] migration: push Error **errp into qemu_loadvm_state_header()

2025-07-25 Thread Marc-André Lureau
rrp, in case of failure. > > Signed-off-by: Arun Menon > Reviewed-by: Marc-André Lureau > --- > migration/savevm.c | 27 ++- > 1 file changed, 18 insertions(+), 9 deletions(-) > > diff --git a/migration/savevm.c b/migration/savevm.c > index

Re: [PATCH v7 02/24] migration: push Error **errp into vmstate_load_state()

2025-07-25 Thread Marc-André Lureau
rrp, in case of failure. > > Signed-off-by: Arun Menon > Reviewed-by: Marc-André Lureau > --- > hw/display/virtio-gpu.c | 2 +- > hw/pci/pci.c| 2 +- > hw/s390x/virtio-ccw.c | 2 +- > hw/scsi/spapr_vscsi.c | 2 +- > hw/vfio/pci.c

Re: [PATCH v7 01/24] migration: push Error **errp into vmstate_subsection_load()

2025-07-25 Thread Marc-André Lureau
state_subsection_load(QEMUFile *f, const > VMStateDescription *vmsd, > ret = vmstate_load_state(f, sub_vmsd, opaque, version_id); > if (ret) { > trace_vmstate_subsection_load_bad(vmsd->name, idstr, > "(child)"); > +error_setg(errp, > + "Loading VM subsection '%s' in '%s' failed : %d", > extra space before ":" other than that Reviewed-by: Marc-André Lureau > + idstr, vmsd->name, ret); > return ret; > } > } > > -- > 2.50.0 > >

Re: [PATCH] ui/keymaps: Avoid trace crash and improve error messages

2025-07-23 Thread Marc-André Lureau
se(). > > While there, improve the error messages a bit. > > Fixes: d3b787fa7dde (keymaps: add tracing) > Signed-off-by: Markus Armbruster > Reviewed-by: Marc-André Lureau > --- > ui/keymaps.c | 14 ++ > 1 file changed, 10 insertions(+), 4 deletions(-) &g

Re: [PATCH v6 03/24] migration: push Error **errp into qemu_loadvm_state_header()

2025-07-21 Thread Marc-André Lureau
Hi On Mon, Jul 21, 2025 at 3:30 PM Arun Menon wrote: > This is an incremental step in converting vmstate loading > code to report error via Error objects instead of directly > printing it to console/monitor. > It is ensured that qemu_loadvm_state_header() must report an error > in errp, in case

Re: [PATCH v6 02/24] migration: push Error **errp into vmstate_load_state()

2025-07-21 Thread Marc-André Lureau
Hi On Mon, Jul 21, 2025 at 3:35 PM Arun Menon wrote: > This is an incremental step in converting vmstate loading > code to report error via Error objects instead of directly > printing it to console/monitor. > It is ensured that vmstate_load_state() must report an error > in errp, in case of fai

Re: [PATCH] ui/spice: Destroy the temporary egl fb after the blit is submitted

2025-07-21 Thread Marc-André Lureau
> is empty initialized before it is actually used. > > Fixes: f851cd65 ("ui/spice: Blit the scanout texture if its memory layout is > not linear") > Reported-by: Peter Maydell > Cc: Marc-André Lureau > Signed-off-by: Vivek Kasireddy Reviewed-by: Marc-André

Re: [PULL v2 00/13] Ui patches

2025-07-14 Thread Marc-André Lureau
Hi On Tue, Jul 15, 2025 at 10:36 AM wrote: > > From: Marc-André Lureau > > The following changes since commit 9a4e273ddec3927920c5958d2226c6b38b543336: > > Merge tag 'pull-tcg-20250711' of https://gitlab.com/rth7680/qemu into > staging (2025-07-13 01:46:04 -040

Re: [PATCH] gtk: Skip drawing if console surface is NULL

2025-07-14 Thread Marc-André Lureau
In practice, this case wouldn't happen at all because we always install > a placeholder surface to the console when there is nothing to display. > > Resolves: Coverity CID 1610328 > Signed-off-by: Weifeng Liu Reviewed-by: Marc-André Lureau > --- > ui/gtk-egl.c | 5

Re: [PULL 00/13] Ui patches

2025-07-14 Thread Marc-André Lureau
On Mon, Jul 14, 2025 at 3:45 PM wrote: > > From: Marc-André Lureau > > The following changes since commit 9a4e273ddec3927920c5958d2226c6b38b543336: > > Merge tag 'pull-tcg-20250711' of https://gitlab.com/rth7680/qemu into > staging (2025-07-13 01:46:04 -040

Re: [PULL 14/19] ui/gtk: Update scales in fixed-scale mode when rendering GL area

2025-07-11 Thread Marc-André Lureau
(!vc->gfx.ds) { > return; > } > > Either vc->gfx.ds can be NULL, in which case we need some > kind of guard on these surface_width() and surface_height() > calls; or else it can't, and the NULL check later is dead code. > Which is correct ? Given that it's simply called from a GTK callback, it can be NULL. I think we should simply return in this case, or perhaps use the older code path as a fallback. Weifeng, wdyt? -- Marc-André Lureau

Re: [PATCH v6 1/1] hw/display: Allow injection of virtio-gpu EDID name

2025-07-10 Thread Marc-André Lureau
ot;driver":"virtio-vga", > "max_outputs":2, > "id":"vga", > "outputs":[ > { > "name":"AAA" > }, >

Re: [PATCH v5 1/1] hw/display: Allow injection of virtio-gpu EDID name

2025-07-08 Thread Marc-André Lureau
ot;driver":"virtio-vga", > "max_outputs":2, > "id":"vga", > "outputs":[ > { > "name":"AAA", > }, > { >

Re: [PATCH v4 1/1] hw/display: Allow injection of virtio-gpu EDID name

2025-07-02 Thread Marc-André Lureau
\ > DEFINE_PROP_UINT32("max_outputs", _state, _conf.max_outputs, 1),\ > +DEFINE_PROP_VIRTIO_GPU_OUTPUT_LIST("outputs", _state, _conf.outputs), \ > DEFINE_PROP_BIT("edid", _state, _conf.flags, \ > VIRTIO_GPU_FLAG_EDID_ENABLED, true), \ > DEFINE_PROP_UINT32("xres", _state, _conf.xres, 1280), \ > diff --git a/qapi/virtio.json b/qapi/virtio.json > index 73df718a26..eb6a907c40 100644 > --- a/qapi/virtio.json > +++ b/qapi/virtio.json > @@ -963,17 +963,31 @@ > { 'struct': 'IOThreadVirtQueueMapping', >'data': { 'iothread': 'str', '*vqs': ['uint16'] } } > > +## > +# @VirtIOGPUOutput: > +# > +# Describes configuration of a VirtIO GPU output. > +# > +# @name: the name of the output > +# > +# Since: 9.0 Needs to be 10.1 > +## > + > +{ 'struct': 'VirtIOGPUOutput', > + 'data': { 'name': 'str' } } > + > ## > # @DummyVirtioForceArrays: > # > # Not used by QMP; hack to let us use IOThreadVirtQueueMappingList > -# internally > +# and VirtIOGPUOutputList internally > # > # Since: 9.0 > ## > > { 'struct': 'DummyVirtioForceArrays', > - 'data': { 'unused-iothread-vq-mapping': ['IOThreadVirtQueueMapping'] } } > + 'data': { 'unused-iothread-vq-mapping': ['IOThreadVirtQueueMapping'], > +'unused-virtio-gpu-output': ['VirtIOGPUOutput'] } } > > ## > # @GranuleMode: > -- > 2.50.0.727.gbf7dc18ff4-goog > > -- Marc-André Lureau

Re: [PATCH 3/3] backends/tpm: Propagate vTPM error on migration failure

2025-07-01 Thread Marc-André Lureau
rp); > int (*pre_save)(void *opaque); > int (*post_save)(void *opaque); > bool (*needed)(void *opaque); > diff --git a/migration/vmstate.c b/migration/vmstate.c > index > 3f8c3d3c1dcfe14d70bab1f43b827244eb4bb385..c5dfffd9bad7285e819d4769e055d47157caab34 > 100644 > --- a/migration/vmstate.c > +++ b/migration/vmstate.c > @@ -232,7 +232,9 @@ int vmstate_load_state(QEMUFile *f, const > VMStateDescription *vmsd, > qemu_file_set_error(f, ret); > return ret; > } > -if (vmsd->post_load) { > +if (vmsd->post_load_with_error) { > +ret = vmsd->post_load_with_error(opaque, version_id, errp); > +} else if (vmsd->post_load) { > ret = vmsd->post_load(opaque, version_id); > } > trace_vmstate_load_state_end(vmsd->name, "end", ret); > > -- > 2.49.0 > > -- Marc-André Lureau

Re: [PATCH] ui/vnc: Update display update interval when VM state changes to RUNNING

2025-06-11 Thread Marc-André Lureau
Hi On Wed, Jun 11, 2025 at 4:34 PM Peter Xu wrote: > On Wed, May 21, 2025 at 05:16:13PM +0200, Juraj Marcin wrote: > > From: Juraj Marcin > > > > If a virtual machine is paused for an extended period time, for example, > > due to an incoming migration, there are also no changes on the screen. >

Re: [PATCH 2/3] scripts/qapi: add QAPISchemaIfCond.rsgen()

2025-06-10 Thread Marc-André Lureau
Hi On Thu, Jun 5, 2025 at 2:11 PM Paolo Bonzini wrote: > From: Marc-André Lureau > > Generate Rust #[cfg(...)] guards from QAPI 'if' conditions. > > Signed-off-by: Marc-André Lureau > Link: > https://lore.kernel.org/r/20210907121943.3498701-15-marcandre.lu

Re: [PATCH 1/3] rust: make TryFrom macro more resilient

2025-06-10 Thread Marc-André Lureau
Error do not use the associated type > at all. > > Signed-off-by: Paolo Bonzini > Reviewed-by: Marc-André Lureau > --- > rust/qemu-api-macros/src/lib.rs | 7 --- > 1 file changed, 4 insertions(+), 3 deletions(-) > > diff --git a/rust/qemu-api-macros/src/lib.rs b/rust/qemu-

Re: [PATCH preview 0/3] reviving minimal QAPI generation from 2021

2025-06-10 Thread Marc-André Lureau
ling and unmarshaling code; and whether > to use bindgen or generate C-compatible FFI types---but it made sense, > from the point of view of extracting "some" code from Marc-André's > proof of concept and enticing other people, :) to start from high-level > types. > &g

Re: [PATCH v5 2/7] ui/spice: Add an option for users to provide a preferred codec

2025-06-10 Thread Marc-André Lureau
> > > > > On Wed, May 28, 2025 at 10:11:13PM -0700, Vivek Kasireddy wrote: > > > > Giving users an option to choose a particular codec will enable > > > > them to make an appropriate decision based on their hardware and > > > > use-case. >

Re: [PATCH 0/2] ui: fix VNC endian regression & improve tracing

2025-06-04 Thread Marc-André Lureau
t; ui/vnc.c| 53 + > 2 files changed, 67 insertions(+) > Series: Reviewed-by: Marc-André Lureau > > -- > 2.49.0 > >

Re: [PATCH v3 1/2] ui/vnc: Do not copy z_stream

2025-06-04 Thread Marc-André Lureau
stream > and returns Z_STREAM_ERROR, leaking the allocated memory. > > Avoid copying the zlib state to fix the memory leak. > > Fixes: bd023f953e5e ("vnc: threaded VNC server") > Signed-off-by: Akihiko Odaki lgtm, Reviewed-by: Marc-André Lureau I wonder if VncZlib could

Re: [PATCH v5 0/7] ui/spice: Enable gl=on option for non-local or remote clients

2025-06-04 Thread Marc-André Lureau
the issue with better default for video-codecs is on spice-server side, so for this series: Reviewed-by: Marc-André Lureau > v4 -> v5 (suggestions from Marc-André): > - Fix the errors (mostly 80 chars limit violations) identified by > scripts/checkpatch.pl > - Rename the globa

Re: [PATCH 0/2] ui/gtk: Add keep-aspect-ratio and scale option

2025-06-03 Thread Marc-André Lureau
dded > to the host window to preserve the aspect ratio of guest frame-buffer. > > - scale: allow user to set a preferred scale factor, which would be > helpful for users running on a hi-dpi desktop to achieve pixel to > pixel display. > > Cc: BALATON Zoltan > Cc: Gerd

Re: [PATCH v2 0/2] ui/vnc: Do not copy z_stream

2025-06-01 Thread Marc-André Lureau
Hi Akihiko On Sat, May 31, 2025 at 4:55 PM Akihiko Odaki wrote: > vnc_worker_thread_loop() copies z_stream stored in its local VncState to > the persistent VncState, and the copied one is freed with deflateEnd() > later. However, deflateEnd() refuses to operate with a copied z_stream > and retur

Re: [PATCH] ui/vnc: Update display update interval when VM state changes to RUNNING

2025-05-27 Thread Marc-André Lureau
gt; and changing the update interval when the VM state changes to RUNNING. > The update_displaychangelistener() function updates the internal timer, > and the display is refreshed immediately if the timer is expired. > > Signed-off-by: Juraj Marcin Reviewed-by: Marc-André Lureau

Re: [PULL 8/9] alsaaudio: Set try-poll to false by default

2025-05-26 Thread Marc-André Lureau
tion until the guest can provide enough audio frames. Timer based > > playback doesn't have that problem." > > > > But users cannot easily find this option and having a non-working > > default is really unhelpful so to make life easier just set it to > > false

Re: [PATCH] audio: Reset rate control when adding bytes

2025-05-25 Thread Marc-André Lureau
> not. > > Reset the rate control in audio_rate_add_bytes(), which is called only > when actually adding frames, according to the previous call to > audio_rate_peek_bytes() to avoid frequent rate control resets even when > the guest generates no frame. > > Signed-off-by: Ak

Re: [PATCH 0/4] chardev: Fix issues found by vhost-user-test

2025-05-24 Thread Marc-André Lureau
chardev: Introduce a lock for hup_source Daniel, would you take the first 3 (or all) patches in your next I/O PR ? > > chardev/char-io.c | 5 + > chardev/char-socket.c | 38 -- > chardev/char.c | 2 ++ > include/chardev/char.h | 1 + > 4 files changed, 20 insertions(+), 26 deletions(-) > > -- > 2.35.3 > > -- Marc-André Lureau

Re: [PATCH v4 4/7] ui/spice: Add an option to submit gl_draw requests at fixed rate

2025-05-24 Thread Marc-André Lureau
ue using the GUI refresh timer. Otherwise, the updates > or gl_draw requests would be sent as soon as the Guest submits a new > frame which is not optimal as it would lead to increased network > traffic and wastage of GPU cycles if the frames get dropped. > > Cc: Gerd Hoffmann &g

Re: [PATCH v4 4/7] ui/spice: Add an option to submit gl_draw requests at fixed rate

2025-05-24 Thread Marc-André Lureau
sing the GUI refresh timer. Otherwise, the updates > or gl_draw requests would be sent as soon as the Guest submits a new > frame which is not optimal as it would lead to increased network > traffic and wastage of GPU cycles if the frames get dropped. > > Cc: Gerd Hoffmann > Cc: M

Re: [PATCH v4 3/7] ui/spice: Enable gl=on option for non-local or remote clients

2025-05-24 Thread Marc-André Lureau
would encode and send the data > associated with the fd to a client that could be located on > a different machine. > > Cc: Gerd Hoffmann > Cc: Marc-André Lureau > Cc: Dmitry Osipenko > Cc: Frediano Ziglio > Cc: Dongwon Kim > Signed-off-by: Vivek Kasireddy > ---

Re: [PATCH v4 0/7] ui/spice: Enable gl=on option for non-local or remote clients

2025-05-24 Thread Marc-André Lureau
virtio-vga,max_outputs=1,xres=1920,yres=1080,blob=true > -spice port=3001,gl=on,disable-ticketing=on,video-codecs=gstreamer:h264 > > and remote-viewer --spice-debug spice://x.x.x.x:3001 on the client side. > > Associated Spice server MR (merged): > https://gitlab.freedesktop.org

Re: [PATCH 0/7] audio related fixes for 10.1

2025-05-11 Thread Marc-André Lureau
12 ++-- > audio/mixeng.c | 83 > audio/mixeng.h | 6 +- > hw/audio/asc.c | 9 ++- > tests/functional/test_m68k_q800.py | 3 +- > tests/functional/test_m68k_replay.py | 3 +- > 7 files changed, 10

Re: [PATCH for-10.1 06/10] ui/vdagent: replace Buffer with GByteArray

2025-05-09 Thread Marc-André Lureau
Hi On Fri, May 9, 2025 at 3:31 PM Daniel P. Berrangé wrote: > > On Tue, Mar 11, 2025 at 07:59:28PM +0400, marcandre.lur...@redhat.com wrote: > > From: Marc-André Lureau > > > > Buffer is slightly more advanced than GByteArray, since it has a > > cursor/position. Bu

Re: [PATCH for-10.1 00/10] Support vdagent migration

2025-05-06 Thread Marc-André Lureau
Hi On Tue, Mar 11, 2025 at 8:16 PM Daniel P. Berrangé wrote: > > On Tue, Mar 11, 2025 at 07:59:22PM +0400, marcandre.lur...@redhat.com wrote: > > From: Marc-André Lureau > > > > > > iQJQBAABCAA6FiEEh6m9kz+HxgbSdvYt2u

Re: [PATCH 1/1] util/memfd: allow allocating 0 bytes

2025-05-05 Thread Marc-André Lureau
you are trying to solve. > > On Mon, May 5, 2025, 19:55 Marc-André Lureau > wrote: >> >> Hi >> >> On Wed, Mar 26, 2025 at 8:21 PM donno2048 wrote: >> > >> > This silently fixes issues resulting from trying to allocate 0 bytes. >> >

Re: [PATCH 1/1] util/memfd: allow allocating 0 bytes

2025-05-05 Thread Marc-André Lureau
) { > +ptr = mmap(0, size, PROT_READ | PROT_WRITE, MAP_SHARED, mfd, 0); > +if (ptr == MAP_FAILED) { > +goto err; > +} > +} else { > +ptr = fdopen(mfd, "rw"); I don't understand fdopen() here, it returns a FILE* > } > > *fd = mfd; > -- > 2.30.2 > > -- Marc-André Lureau

Re: [PATCH 6/6] RFC: qom/object: simplify object_property_del_all()

2025-04-29 Thread Marc-André Lureau
Hi On Tue, Apr 29, 2025 at 6:23 PM Paolo Bonzini wrote: > > > > Il mar 29 apr 2025, 16:03 ha scritto: >> >> From: Marc-André Lureau >> >> Since commit 9859fac ("object: release all props"), the code was changed >> to tracks the already relea

Re: [PATCH v3 6/6] ui/spice: support multi plane dmabuf scanout

2025-04-29 Thread Marc-André Lureau
ad of > bump spice version dependency > > Signed-off-by: Qiang Yu Reviewed-by: Marc-André Lureau (for a single-plane case:) Tested-by: Marc-André Lureau Spice didn't release yet with the new API. It should be okay, but I will wait for the Spice release plan before sen

Re: [PATCH v3 0/6] ui/spice: Enable gl=on option for non-local or remote clients

2025-04-29 Thread Marc-André Lureau
parameters: > -device virtio-vga,max_outputs=1,xres=1920,yres=1080,blob=true > -spice port=3001,gl=on,disable-ticketing=on,video-codecs=gstreamer:h264 > > and remote-viewer --spice-debug spice://x.x.x.x:3001 on the client side. > > Associated Spice server MR (merged): > https:/

Re: [PATCH v3 5/6] ui/spice: Create a new texture with linear layout when gl=on is enabled

2025-04-29 Thread Marc-André Lureau
ure that has a linear memory layout. > > Cc: Gerd Hoffmann > Cc: Marc-André Lureau > Cc: Dmitry Osipenko > Cc: Frediano Ziglio > Cc: Dongwon Kim > Signed-off-by: Vivek Kasireddy > --- > ui/spice-display.c | 63 +- > 1

Re: [PATCH v3 4/6] ui/console-gl: Add a helper to create a texture with linear memory layout

2025-04-29 Thread Marc-André Lureau
memory backing the texture has a linear layout is absolutely necessary > in these situations. > > Cc: Gerd Hoffmann > Cc: Marc-André Lureau > Cc: Dmitry Osipenko > Cc: Frediano Ziglio > Cc: Dongwon Kim > Signed-off-by: Vivek Kasireddy > --- > include/ui/c

Re: [PATCH v3 3/6] ui/spice: Submit the gl_draw requests at 60 FPS for remote clients

2025-04-29 Thread Marc-André Lureau
tely, none of the vnc, spice or dbus protocols provide the refresh rate. I wonder if it would make sense to set it on the GPU.. Perhaps a "max-refresh-rate" device property? > > Cc: Gerd Hoffmann > Cc: Marc-André Lureau > Cc: Dmitry Osipenko > Cc: Frediano Ziglio >

Re: [PATCH v4 8/8] h264: stop gstreamer pipeline before destroying, cleanup on exit

2025-04-28 Thread Marc-André Lureau
ndencies: libsystem_ss.dependencies(), > + dependencies: [libsystem_ss.dependencies(), > pixman], > build_by_default: false) better in system/meson.build > libsystem = declare_dependency(objects: > libsystem.extract_all_objects(recursive: false), >

Re: [PATCH v4 8/8] h264: stop gstreamer pipeline before destroying, cleanup on exit

2025-04-28 Thread Marc-André Lureau
return 0; > } > > +void vnc_cleanup(void) > +{ > +VncDisplay *vd; > + VncState *vs; > + > +QTAILQ_FOREACH(vd, &vnc_displays, next) { > +QTAILQ_FOREACH(vs, &vd->clients, next) { > +#ifdef CONFIG_GSTREAMER > +/* correctly close all h264 encoder pipelines */ > +vnc_h264_clear(vs); > +#endif > +} > +} > +} > + > static void vnc_register_config(void) > { > qemu_add_opts(&qemu_vnc_opts); > -- > 2.39.5 > > -- Marc-André Lureau

Re: [PATCH v4 2/8] vnc: initialize gst during argument processing

2025-04-28 Thread Marc-André Lureau
bool userconfig = true; > FILE *vmstate_dump_file = NULL; > > +#ifdef CONFIG_GSTREAMER > +gst_init(&argc, &argv); > +#endif > + > qemu_add_opts(&qemu_drive_opts); > qemu_add_drive_opts(&qemu_legacy_drive_opts); > qemu_add_drive_opts(&qemu_common_drive_opts); > -- > 2.39.5 > > -- Marc-André Lureau

Re: [PATCH v4 1/8] new configure option to enable gstreamer

2025-04-28 Thread Marc-André Lureau
On Mon, Apr 28, 2025 at 12:07 PM Dietmar Maurer wrote: > > GStreamer is required to implement H264 encoding for VNC. Please note > that QEMU already depends on this library when you enable Spice. > > Signed-off-by: Dietmar Maurer Reviewed-by: Marc-André Lureau >

Re: [PATCH] ui/gtk: Properly apply x/y scale when rendering GL area

2025-04-28 Thread Marc-André Lureau
les before rendering the image fixes this issue. > > Cc: hikalium > Cc: Alexander Orzechowski > Cc: Gerd Hoffmann > Signed-off-by: Weifeng Liu Tested-by: Marc-André Lureau (Hopefully someone has enough motivation to actually understand this change better - otherwise I'

Re: [PATCH v3 2/9] add vnc h264 encoder

2025-04-23 Thread Marc-André Lureau
Hi On Wed, Apr 23, 2025 at 3:46 PM Dietmar Maurer wrote: > > > On 19.4.2025 07:24 CEST Marc-André Lureau > > wrote: > > > > > > Hi > > > > On Fri, Apr 18, 2025 at 3:41 PM Dietmar Maurer wrote: > > > > > > This patch implements H2

Re: [PATCH v3 9/9] h264: register shutdown notifiers, stop pipeline in destroy_encoder_context

2025-04-22 Thread Marc-André Lureau
Hi On Tue, Apr 22, 2025 at 11:03 AM Dietmar Maurer wrote: > > > > On 22.4.2025 08:39 CEST Marc-André Lureau > > wrote: > > > > > > Hi > > > > On Tue, Apr 22, 2025 at 10:37 AM Dietmar Maurer wrote: > > > > > >

Re: [PATCH v3 9/9] h264: register shutdown notifiers, stop pipeline in destroy_encoder_context

2025-04-21 Thread Marc-André Lureau
cause the Qemu process to hang (CTRL-C does not stop it, only kill -9) Given that h264 code depends on VNC state, can you make VNC close/clean the connection instead? -- Marc-André Lureau

Re: [PATCH v3 5/9] h264: new vnc option to configure h264 at server side

2025-04-21 Thread Marc-André Lureau
Hi On Fri, Apr 18, 2025 at 3:30 PM Dietmar Maurer wrote: > > Values can be 'on', 'off', or a space sparated list of separated > allowed gstreamer encoders. > > - on: automatically select the encoder 'auto' then (default?) > - off: disbale h264 disable 'auto'/'off' but there should be 'on' t

Re: [PATCH v3 9/9] h264: register shutdown notifiers, stop pipeline in destroy_encoder_context

2025-04-21 Thread Marc-André Lureau
Hi On Fri, Apr 18, 2025 at 3:30 PM Dietmar Maurer wrote: > > Some encoders can hang indefinetly (i.e. nvh264enc) if indefinitely > the pipeline is not stopped before it is destroyed > (Observed on Debian bookworm). but why do you need the extra shutdown notifier? > > Signed-off-by: Dietmar Ma

Re: [PATCH v3 8/9] vnc: initialize gst during argument processing

2025-04-21 Thread Marc-André Lureau
Hi On Fri, Apr 18, 2025 at 3:30 PM Dietmar Maurer wrote: > > So that we can set --gst- options on the qemu command line. > > Signed-off-by: Dietmar Maurer Nice, could you move that up in the patch series? As a second patch after linking gst seems fitting. > --- > system/vl.c | 8 > u

Re: [PATCH v3 3/9] vnc: h264: send additional frames after the display is clean

2025-04-18 Thread Marc-André Lureau
This patch modifies the code to send a few additional frames in such > situations to flush the H264 encoder data. > > Signed-off-by: Dietmar Maurer (from v1) Reviewed-by: Marc-André Lureau > --- > ui/vnc.c | 25 - > ui/vnc.h | 3 +++ > 2 files chang

Re: [PATCH v3 2/9] add vnc h264 encoder

2025-04-18 Thread Marc-André Lureau
; case VNC_ENCODING_DESKTOPRESIZE: > vnc_set_feature(vs, VNC_FEATURE_RESIZE); > break; > @@ -4291,6 +4308,10 @@ int vnc_init_func(void *opaque, QemuOpts *opts, Error > **errp) > Error *local_err = NULL; > char *id = (char *)qemu_opts_id(opts); > > +#ifdef CONFIG_GSTREAMER > +gst_init(NULL, NULL); > +#endif > + > assert(id); > vnc_display_init(id, &local_err); > if (local_err) { > diff --git a/ui/vnc.h b/ui/vnc.h > index acc53a2cc1..a0d336738d 100644 > --- a/ui/vnc.h > +++ b/ui/vnc.h > @@ -46,6 +46,10 @@ > #include "vnc-enc-zrle.h" > #include "ui/kbd-state.h" > > +#ifdef CONFIG_GSTREAMER > +#include > +#endif > + > // #define _VNC_DEBUG 1 > > #ifdef _VNC_DEBUG > @@ -231,6 +235,14 @@ typedef struct VncZywrle { > int buf[VNC_ZRLE_TILE_WIDTH * VNC_ZRLE_TILE_HEIGHT]; > } VncZywrle; > > +#ifdef CONFIG_GSTREAMER > +typedef struct VncH264 { > +GstElement *pipeline, *source, *gst_encoder, *sink, *convert; > +size_t width; > +size_t height; > +} VncH264; > +#endif > + > struct VncRect > { > int x; > @@ -344,6 +356,9 @@ struct VncState > VncHextile hextile; > VncZrle *zrle; > VncZywrle zywrle; > +#ifdef CONFIG_GSTREAMER > +VncH264 *h264; > +#endif > > Notifier mouse_mode_notifier; > > @@ -404,6 +419,7 @@ enum { > #define VNC_ENCODING_TRLE 0x000f > #define VNC_ENCODING_ZRLE 0x0010 > #define VNC_ENCODING_ZYWRLE 0x0011 > +#define VNC_ENCODING_H264 0x0032 /* 50 */ > #define VNC_ENCODING_COMPRESSLEVEL0 0xFF00 /* -256 */ > #define VNC_ENCODING_QUALITYLEVEL00xFFE0 /* -32 */ > #define VNC_ENCODING_XCURSOR 0xFF10 /* -240 */ > @@ -464,6 +480,7 @@ enum VncFeatures { > VNC_FEATURE_XVP, > VNC_FEATURE_CLIPBOARD_EXT, > VNC_FEATURE_AUDIO, > +VNC_FEATURE_H264, > }; > > > @@ -625,6 +642,10 @@ int vnc_zrle_send_framebuffer_update(VncState *vs, int > x, int y, int w, int h); > int vnc_zywrle_send_framebuffer_update(VncState *vs, int x, int y, int w, > int h); > void vnc_zrle_clear(VncState *vs); > > +bool vnc_h264_encoder_init(VncState *vs); > +int vnc_h264_send_framebuffer_update(VncState *vs, int x, int y, int w, int > h); > +void vnc_h264_clear(VncState *vs); > + > /* vnc-clipboard.c */ > void vnc_server_cut_text_caps(VncState *vs); > void vnc_client_cut_text(VncState *vs, size_t len, uint8_t *text); > -- > 2.39.5 > > -- Marc-André Lureau

Re: [PATCH v3 1/9] new configure option to enable gstreamer

2025-04-18 Thread Marc-André Lureau
; @@ -1348,6 +1348,14 @@ if not get_option('zstd').auto() or have_block > required: get_option('zstd'), > method: 'pkg-config') > endif > + > +gstreamer = not_found > +if not get_option('gstreamer').

Re: [PATCH v2 2/6] add vnc h264 encoder

2025-04-15 Thread Marc-André Lureau
Hi On Thu, Apr 10, 2025 at 3:22 PM Dietmar Maurer wrote: > > This patch implements H264 support for VNC. The RFB protocol > extension is defined in: > > https://github.com/rfbproto/rfbproto/blob/master/rfbproto.rst#open-h-264-encoding > > Currently the Gstreamer x264enc plugin (software encoder)

Re: [PATCH v2 1/6] new configure option to enable gstreamer

2025-04-15 Thread Marc-André Lureau
; @@ -1348,6 +1348,14 @@ if not get_option('zstd').auto() or have_block > required: get_option('zstd'), > method: 'pkg-config') > endif > + > +gstreamer = not_found > +if not get_option('gstreamer').

Re: [PATCH 3/3] vnc: h264: send additional frames after the display is clean

2025-04-10 Thread Marc-André Lureau
On Mon, Apr 7, 2025 at 3:06 PM Dietmar Maurer wrote: > > So that encoder can improve the picture quality. > > Signed-off-by: Dietmar Maurer Reviewed-by: Marc-André Lureau > --- > ui/vnc.c | 25 - > ui/vnc.h | 3 +++ > 2 files changed, 27 i

Re: [PATCH 2/3] add vnc h264 encoder

2025-04-08 Thread Marc-André Lureau
; > the encoder is present. > > ok. > > > It would also be useful to have an extra VNC > > option like H264=on/off/auto. > > I thought it would be better to do that at the client? Well, it can be worth it to prevent h264 usage from the server too. Or to ensure the server is h264-capable. (this wasn't seen as much necessary for other codecs that are low-resource and/or patent-free, but may make sense too) -- Marc-André Lureau

Re: [PATCH 2/3] add vnc h264 encoder

2025-04-07 Thread Marc-André Lureau
Hi Please resend the series with a cover letter (https://www.qemu.org/docs/master/devel/submitting-a-patch.html#use-git-format-patch) Some people prefer when the commit message has content too :) At least, it would be useful if you point to a client that supports the codec and allow us to test/u

Re: [PATCH for-10.1 10/10] ui/vdagent: remove migration blocker

2025-04-05 Thread Marc-André Lureau
Well, there isn't much else to say. And there is a Fixes tag. I don't think we have strict rules about commit message, but I am fine adding more context on each commit. Le jeu. 20 mars 2025, 12:39, Prasad Pandit a écrit : > On Tue, 11 Mar 2025 at 21:44, wrote: > > From

Re: [PATCH v2 4/6] ui/egl: support multi-plane dmabuf when egl export/import

2025-03-26 Thread Marc-André Lureau
On Wed, Mar 26, 2025 at 1:34 PM wrote: > > From: Qiang Yu > > v2: > * use new dmabuf API and check length > > Signed-off-by: Qiang Yu Reviewed-by: Marc-André Lureau > --- > include/ui/egl-helpers.h | 5 ++- > ui/dbus-listener.c | 19 + &g

Re: [PATCH v2 5/6] ui/dbus: change dbus ScanoutDMABUF interface

2025-03-26 Thread Marc-André Lureau
> > > + > + > + As it may be used with single plane, it is essentially ScanoutDMABUF2, I think we should use that name rather than MultiPlane. > + > + > + > + > + > + > + > + > + > + > + > + > + > + > + > 2.43.0 > -- Marc-André Lureau

Re: [PATCH v2 1/6] ui/dmabuf: extend QemuDmaBuf to support multi-plane

2025-03-26 Thread Marc-André Lureau
; -assert(dmabuf != NULL); > -dmabuf->fd = fd; > -} > diff --git a/ui/egl-helpers.c b/ui/egl-helpers.c > index d591159480..d194d004b7 100644 > --- a/ui/egl-helpers.c > +++ b/ui/egl-helpers.c > @@ -323,9 +323,9 @@ void egl_dmabuf_import_texture(QemuDmaBuf *dmabuf) > attrs[i++] = qemu_dmabuf_get_fourcc(dmabuf); > > attrs[i++] = EGL_DMA_BUF_PLANE0_FD_EXT; > -attrs[i++] = qemu_dmabuf_get_fd(dmabuf); > +attrs[i++] = qemu_dmabuf_get_fds(dmabuf, NULL)[0]; > attrs[i++] = EGL_DMA_BUF_PLANE0_PITCH_EXT; > -attrs[i++] = qemu_dmabuf_get_stride(dmabuf); > +attrs[i++] = qemu_dmabuf_get_strides(dmabuf, NULL)[0]; > attrs[i++] = EGL_DMA_BUF_PLANE0_OFFSET_EXT; > attrs[i++] = 0; > #ifdef EGL_DMA_BUF_PLANE0_MODIFIER_LO_EXT > diff --git a/ui/spice-display.c b/ui/spice-display.c > index c794ae0649..40547edb5e 100644 > --- a/ui/spice-display.c > +++ b/ui/spice-display.c > @@ -1075,10 +1075,10 @@ static void > qemu_spice_gl_update(DisplayChangeListener *dcl, > stride, fourcc, false); > } > } else { > -stride = qemu_dmabuf_get_stride(dmabuf); > +stride = qemu_dmabuf_get_strides(dmabuf, NULL)[0]; > fourcc = qemu_dmabuf_get_fourcc(dmabuf); > y_0_top = qemu_dmabuf_get_y0_top(dmabuf); > -fd = qemu_dmabuf_dup_fd(dmabuf); > +qemu_dmabuf_dup_fds(dmabuf, &fd, 1); > > trace_qemu_spice_gl_forward_dmabuf(ssd->qxl.id, width, height); > /* note: spice server will close the fd, so hand over a dup */ > -- > 2.43.0 > -- Marc-André Lureau

Re: [PATCH v2 2/6] ui/egl: require EGL_EXT_image_dma_buf_import_modifiers

2025-03-26 Thread Marc-André Lureau
buf_get_strides(dmabuf, NULL)[0]; > attrs[i++] = EGL_DMA_BUF_PLANE0_OFFSET_EXT; > attrs[i++] = 0; > -#ifdef EGL_DMA_BUF_PLANE0_MODIFIER_LO_EXT Maybe we should have in meson.build: if gbm.found() cc.has_header_symbol('epoxy/egl.h', 'EGL_DMA_BUF_PLANE0_MO

Re: [PATCH 6/6] ui/spice: support multi plane dmabuf scanout

2025-03-25 Thread Marc-André Lureau
Hi On Wed, Mar 26, 2025 at 5:46 AM Qiang Yu wrote: > > On Mon, Mar 24, 2025 at 10:02 PM Marc-André Lureau > wrote: > > > > On Mon, Mar 24, 2025 at 5:35 PM Qiang Yu wrote: > > > > > > On Mon, Mar 24, 2025 at 5:30 PM Marc-André Lureau > > > wrote

Re: [PATCH 1/6] ui/dmabuf: extend QemuDmaBuf to support multi-plane

2025-03-25 Thread Marc-André Lureau
Hi On Tue, Mar 25, 2025 at 10:52 AM Qiang Yu wrote: > > On Tue, Mar 25, 2025 at 2:37 PM Marc-André Lureau > wrote: > > > > Hi > > > > On Tue, Mar 25, 2025 at 7:26 AM Qiang Yu wrote: > > > > > > On Mon, Mar 24, 2025 at 10:06 PM

Re: [PATCH 1/6] ui/dmabuf: extend QemuDmaBuf to support multi-plane

2025-03-24 Thread Marc-André Lureau
Hi On Tue, Mar 25, 2025 at 7:26 AM Qiang Yu wrote: > > On Mon, Mar 24, 2025 at 10:06 PM Marc-André Lureau > wrote: > > > > Hi > > > > On Mon, Mar 24, 2025 at 5:20 PM Qiang Yu wrote: > > > > > > On Mon, Mar 24, 2025 at 6:04 PM

Re: [PATCH] meson.build: Put the D-Bus summary into the UI section

2025-03-24 Thread Marc-André Lureau
On Tue, Mar 25, 2025 at 9:51 AM Thomas Huth wrote: > > From: Thomas Huth > > We've got a dedicated section for UI options nowadays, so the > D-Bus display should get reported here, too. > > Signed-off-by: Thomas Huth Reviewed-by: Marc-André Lureau > --- &g

Re: [PATCH 1/6] ui/dmabuf: extend QemuDmaBuf to support multi-plane

2025-03-24 Thread Marc-André Lureau
Hi On Mon, Mar 24, 2025 at 5:20 PM Qiang Yu wrote: > > On Mon, Mar 24, 2025 at 6:04 PM Marc-André Lureau > wrote: > > > > Hi > > > > On Mon, Mar 24, 2025 at 12:19 PM wrote: > > > > > > From: Qiang Yu > > > > > > mesa/ra

Re: [PATCH 6/6] ui/spice: support multi plane dmabuf scanout

2025-03-24 Thread Marc-André Lureau
On Mon, Mar 24, 2025 at 5:35 PM Qiang Yu wrote: > > On Mon, Mar 24, 2025 at 5:30 PM Marc-André Lureau > wrote: > > > > Hi > > > > On Mon, Mar 24, 2025 at 12:20 PM wrote: > > > > > > From: Qiang Yu > > > > > > Signed-off-by:

Re: [PATCH 2/6] ui/egl: require EGL_EXT_image_dma_buf_import_modifiers

2025-03-24 Thread Marc-André Lureau
Hi On Mon, Mar 24, 2025 at 5:27 PM Qiang Yu wrote: > > On Mon, Mar 24, 2025 at 6:09 PM Marc-André Lureau > wrote: > > > > Hi > > > > On Mon, Mar 24, 2025 at 12:19 PM wrote: > > > > > > From: Qiang Yu > > > > > > It's u

Re: [PATCH 3/6] ui/egl: use DRM_FORMAT_MOD_INVALID as default modifier

2025-03-24 Thread Marc-André Lureau
On Mon, Mar 24, 2025 at 12:19 PM wrote: > > From: Qiang Yu > > 0 is used as DRM_FORMAT_MOD_LINEAR already. > > Signed-off-by: Qiang Yu Reviewed-by: Marc-André Lureau > --- > hw/display/vhost-user-gpu.c | 3 ++- > hw/display/virtio-gpu-udmabuf.c |

Re: [PATCH 1/6] ui/dmabuf: extend QemuDmaBuf to support multi-plane

2025-03-24 Thread Marc-André Lureau
Hi On Mon, Mar 24, 2025 at 12:19 PM wrote: > > From: Qiang Yu > > mesa/radeonsi is going to support explicit midifier which > may export a multi-plane texture. For example, texture with > DCC enabled (a compressed format) has two planes, one with > compressed data, the other with meta data for c

Re: [PATCH 2/6] ui/egl: require EGL_EXT_image_dma_buf_import_modifiers

2025-03-24 Thread Marc-André Lureau
Hi On Mon, Mar 24, 2025 at 12:19 PM wrote: > > From: Qiang Yu > > It's used already, just check it explicitly. > > Signed-off-by: Qiang Yu > --- > ui/egl-helpers.c | 10 ++ > 1 file changed, 6 insertions(+), 4 deletions(-) > > diff --git a/ui/egl-helpers.c b/ui/egl-helpers.c > index 72

Re: [PATCH 6/6] ui/spice: support multi plane dmabuf scanout

2025-03-24 Thread Marc-André Lureau
> +int fds[DMABUF_MAX_PLANES]; > + > fourcc = qemu_dmabuf_get_fourcc(dmabuf); > y_0_top = qemu_dmabuf_get_y0_top(dmabuf); > -qemu_dmabuf_dup_fd(dmabuf, &fd); > +qemu_dmabuf_dup_fd(dmabuf, fds); > > trace_qemu_spice_gl_forward_dmabuf(ssd->qxl.id, width, height); > /* note: spice server will close the fd, so hand over a dup */ > -spice_qxl_gl_scanout(&ssd->qxl, fd, width, height, > - stride, fourcc, y_0_top); > +spice_qxl_gl_scanout2(&ssd->qxl, fds, width, height, > + qemu_dmabuf_get_offset(dmabuf), > + qemu_dmabuf_get_stride(dmabuf), > + qemu_dmabuf_get_num_planes(dmabuf), > + fourcc, > + qemu_dmabuf_get_modifier(dmabuf), > + y_0_top); > } > qemu_spice_gl_monitor_config(ssd, 0, 0, width, height); > ssd->guest_dmabuf_refresh = false; > -- > 2.43.0 > > -- Marc-André Lureau

Re: [RFC 0/3] Support live migration for qemu-vdagent chardev

2025-03-20 Thread Marc-André Lureau
Hi On Fri, Mar 21, 2025 at 7:40 AM wrote: > > From: Hyman Huang > > Our goal is to migrate VMs that are configured with qemu-vdagent-typed > chardev while allowing the agent to continue working without having > to restart the service in guest. > I sent a more complete series last week: "[PATCH

Re: [PATCH v2 0/5] ui/console-vc: various fixes and improvements

2025-02-26 Thread Marc-André Lureau
> * The VT spec and ECMA-48 standard are somewhat vague about exactly > what attributes should be set for the ICH (insert character), > but various terminal implementations reset the character to the > default state. Instead of inserting a "space" with the current >

Re: [PATCH] chardev: use remoteAddr if the chardev is client

2025-02-25 Thread Marc-André Lureau
((struct sockaddr_un *)(ps))->sun_path); > +} > case AF_INET6: > left = "["; > right = "]"; > -- > 2.48.1 > > This patch doesn't change anything, and I don't understand the problem you are trying to fix. Can you provide more details or a test scenario? thanks -- Marc-André Lureau

Re: [PATCH 5/5] ui/console-vc: implement DCH (delete) and ICH (insert) commands

2025-02-23 Thread Marc-André Lureau
ect outside the scrolling margins" [2]. > > Without these commands console is barely usable. > > [1] https://vt100.net/docs/vt510-rm/DCH.html > [1] https://vt100.net/docs/vt510-rm/ICH.html > > Signed-off-by: Roman Penyaev > Cc: "Marc-André Lureau" > Cc: qem

Re: [PATCH] ui/sdl: only compile dmabuf support if CONFIG_GBM

2025-02-17 Thread Marc-André Lureau
Hi On Mon, Feb 17, 2025 at 3:16 PM wrote: > > From: Marc-André Lureau > > Fix SDL backend compilation for win32. > > Fixes: commit 31287d1af4 ("ui/sdl2: Implement dpy dmabuf functions") Pierre-Eric, I realize this is not yet upstream. Can you update your patch? than

Re: [PATCH] dbus: add -audio dbus nsamples option

2025-02-05 Thread Marc-André Lureau
Hi On Wed, Feb 5, 2025 at 12:33 PM Markus Armbruster wrote: > > marcandre.lur...@redhat.com writes: > > > From: Marc-André Lureau > > > > Allow to set the number of audio samples per read/write to dbus. > > > > Signed-off-by: Marc-André Lureau

  1   2   3   4   5   6   7   8   9   10   >