| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Also fix warning due to unexpected pipe item type
The specific item type that was not being handled was
PIPE_ITEM_TYPE_INVAL_ONE (#102). This item type is used by the cursor
channel, but the analogous item for the display channel is
PIPE_ITEM_TYPE_INVAL_PALLET_CACHE. Use this value instead.
The exact warning follows:
(/usr/bin/qemu-kvm:24458): Spice-Warning **:
../../server/dcc-send.c:2442:dcc_send_item: should not be reached
(/usr/bin/qemu-kvm:24458): Spice-CRITICAL **:
../../server/dcc.c:1595:release_item_before_push: invalid item type
|
| |
|
| |
|
| |
|
|
|
|
| |
Just move some declarations around
|
|
|
|
|
| |
Remove that hideous template header that should really be regular code
since it's specialized and instanciated only for pixmap.
|
| |
|
| |
|
|
|
|
|
| |
The stat functions in worker are not generic enough to deserve to be
"non-worker", so just pass the worker instance.
|
|
|
|
| |
Move code around to declare and place it where it fits better.
|
| |
|
|
|
|
|
| |
Now that worker is created before running, and run() returns success,
there is no point in using MESSAGE_READY.
|
| |
|
| |
|
|
|
|
| |
Group enums with their respective struct location.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This fixes the following scary racy corruption after glib loop switch:
==28173==
==28173== Debugger has detached. Valgrind regains control. We
continue.
==28173== Invalid read of size 8
==28173== at 0x4C7871E: reds_stream_read (reds.c:4521)
==28173== by 0x4C2F9D7: red_peer_receive (red_channel.c:209)
==28173== by 0x4C2FB59: red_peer_handle_incoming (red_channel.c:255)
==28173== by 0x4C2FF36:
red_channel_client_receive (red_channel.c:329)
==28173== by 0x4C33D6D: red_channel_client_event (red_channel.c:1577)
==28173== by 0x4C65098: watch_func (red_worker.c:10292)
==28173== by 0x504DDAB: g_io_unix_dispatch (giounix.c:167)
==28173== by 0x4FFACB6: g_main_dispatch (gmain.c:3065)
==28173== by 0x4FFBA0D: g_main_context_dispatch (gmain.c:3641)
==28173== by 0x4FFBBFF: g_main_context_iterate (gmain.c:3712)
==28173== by 0x4FFC028: g_main_loop_run (gmain.c:3906)
==28173== by 0x4C6ABF2: red_worker_main (red_worker.c:12180)
==28173== Address 0x7d688e0 is 32 bytes inside a block of size 160
free'd
==28173== at 0x4A074C4: free (in
/usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
==28173== by 0x4C78A84: reds_stream_free (reds.c:4594)
==28173== by 0x4C34E2E:
red_channel_client_disconnect (red_channel.c:1865)
==28173== by 0x4C30363:
red_channel_client_default_peer_on_error (red_channel.c:417)
==28173== by 0x4C3011B: red_peer_handle_outgoing (red_channel.c:372)
==28173== by 0x4C3305F: red_channel_client_send (red_channel.c:1298)
==28173== by 0x4C33FB6:
red_channel_client_begin_send_message (red_channel.c:1616)
==28173== by 0x4C5F4B4:
display_begin_send_message (red_worker.c:8360)
==28173== by 0x4C61DE8: display_channel_send_item (red_worker.c:9164)
==28173== by 0x4C30C69:
red_channel_client_send_item (red_channel.c:599)
==28173== by 0x4C332BB: red_channel_client_push (red_channel.c:1351)
==28173== by 0x4C33C3A:
red_channel_client_handle_message (red_channel.c:1545)
|
|
|
|
|
|
| |
Clean up, more extensible.
Avoid server hanging when no client are connected.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
usage: replay <cmdfile> <port> <client command line>
will run the commands from cmdfile ignoring timestamps, right after a
connection is established from the client, and will SIGINT the client
on end of cmdfile, and exit itself after waiting for the client.
spicy-stats from spice-gtk is useful for testing, it prints the summary
of the traffic on each channel.
You can also run with no client by doing:
replay <cmdfile>
For example, the 300 MB file (compressed to 4 MB with xz -9) available
at [1] produces the following output:
spicy-stats total bytes read:
total bytes read:
inputs: 214
display: 1968983
cursor: 390
main: 256373
You could run it directly like so:
curl http://annarchy.freedesktop.org/~alon/win7_boot_shutdown.cmd.xz | xzcat | server/tests/replay - 12345 `which spicy-stats` -h localhost -p 12345
Known Problems:
* Implementation is wrong. Should do a single device->host conversion
(i.e. get_virt), and then marshall/demarshall that (i.e. RedDrawable).
* segfault on file read done resulting in the above spicy-stats not
being reproducable (well, up to 1% yes).
[1] http://annarchy.freedesktop.org/~alon/win7_boot_shutdown.cmd.xz
Now based on glib including using an asyncqueue for reading the playback
file, and proper freeing of the allocated commands, with --slow,
--compression and a progress timer, and doesn't use more then nsurfaces.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
if the environment variable in the title is set and can be
opened for writing a log of all display commands (no cursor
commands yet) and any QXLWorker calls (particularily primary
create and destroy) will be logged to that file, and possible
to replay using the replay utility introduced later.
For an example file (4 MB download, 300 MB after unpack with xz,
these 300 MB are themselves reduced from 1.2GB using zlib compression
for any chunk):
(old file without a header)
http://annarchy.freedesktop.org/~alon/win7_boot_shutdown.cmd.xz
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently hand crafted with some sed scripts and alot of vim macros from
red_parse_qxl after considering the logger in qemu/hw/qxl-logger.c and seeing
it was incomplete. The only problem with logging from the server and
not from qemu is that it requires coordinated shutdown to avoid half a message.
Should be automatically generated from a declarative syntax, i.e. qxl.proto.
Note: zlib compression is introduced in a disabled state, see ZLIB
define
Now with a simple versioned header and generated ids by the server
instead of based on the recorded file, and doesn't use more then 1024
surfaces (configurable).
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
case of buggy driver (or recording)
|
| |
|
|
|
|
|
| |
They are just utils functions around read and write, let's not use
different naming.
|
|
|
|
|
| |
It doesn't make much sense to have static function declarations in a
header, even a private header. So move them down into the source file.
|
|
|
|
|
|
|
|
| |
inputs_channel_handle_parsed() is casting its void * argument to
a uint8_t * buf before recasting this 'buf' variable to different
other types. This intermediate 'buf' variable is not needed, especially
as we can then benefit from implicit casts from void * to the type we
need.
|
|
|
|
| |
Cosmetic change.
|
|
|
|
|
|
| |
When handling a KEY_UP message, the various variables were called
'key_down', and they were called 'key_up' when handling KEY_DOWN
messages. This commit makes the naming consistent.
|
| |
|
|
|
|
|
|
| |
The client has been superseded by virt-viewer (
http://virt-manager.org/download/sources/virt-viewer/ ) and is no longer
being maintained.
|
|
|
|
|
|
|
|
| |
- Add lz4 encoder to compress an image of type LZ4 (see spice_common).
- Add code in red_worker to use LZ4 when it is enabled, and the client
supports it through its display capability, or fallback to LZ.
- Add enable_lz4 switch in the configure script. Show LZ4 support at the
end.
|
|
|
|
|
|
| |
SPICE_REQUIRES is only used to generate the Requires.private line of
spice-server.pc. The server code is not using xinerama, so we don't need
to list xinerama in Requires.private.
|
|
|
|
|
|
|
| |
Xinerama support is only used for the X11 client, but is currently
being checked even for server only builds. This commit ensures Xinerama
is not checked for/added to spice-server.pc when not building the
client.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Fixes the following build error:
In file included from
/home/elmarco/src/spice-new/src/spice/server/tests/test_display_base.h:4:0,
from
/home/elmarco/src/spice-new/src/spice/server/tests/test_display_no_ssl.c:11:
/home/elmarco/src/spice-new/src/spice/server/spice.h:23:27:
fatal error: spice-version.h: No such file or directory
#include "spice-version.h"
^
|
|
|
|
| |
Several functions use core interfaces, add and explicit include.
|
|
|
|
| |
This function is not related to migration.
|
|
|
|
| |
As suggested by Christophe on the mailing list.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The multimedia time is defined by the server side monotonic time [1],
but the drawing time-stamp is done in guest side, so it requires
synchronization between host and guest. This is expensive, when no audio
is playing, there is a ~30x/sec wakeup to update the qxl device mmtime,
and it requires marking dirty the rom region.
Instead, the video timestamping can be done more efficiently on server
side, without visible drawbacks.
[1] a better timestamp could be the audio time, since audio players are
usually sync with audio time)
Related to:
https://bugzilla.redhat.com/show_bug.cgi?id=912763
|
|
|
|
|
|
|
| |
Editing the hexadecimal value of spice-version and keeping it in sync
with actual release is a bit tedious. Let's generate it
automatically (although handling of bumps will need temporarily static
versions, when 0.12 -> 1.0 for example)
|
|
|
|
| |
Make it easier to read the Spice server API.
|
|
|
|
| |
Those are already declared in <spice/qxl_dev.h>.
|