[Spice-devel] Dead lock in usbredir

2014-12-15 Thread hustxyj
Hi I met a dead lock in usbredir. When a device with interrupt endpoint was plugged in, the func usbredirhost_start_interrupt_receiving may be called, which locked the host first. Then submitted the transfer and call usbi_fd_notification, which called libusb_lock_events(ctx). Another thread "s

[Spice-devel] [xf86-video-qxl v6] Enable smartcard support for XSpice.

2014-12-15 Thread Jeremy White
This is done by creating a Unix domain socket to which smartcard messages are transferred, using the vscard protocol. A further system library, spiceccid, is used to provide an interface into pcsc-lite, specifically the pcsc-lite daemon, so that regular Unix applications can access the passed thro

Re: [Spice-devel] [xf86-video-qxl v5] Enable smartcard support for XSpice.

2014-12-15 Thread Jeremy White
I'll send a v6 in a bit; thanks for the review. That looks correct to me, but it's maybe better to memmove outside the loop, such that memmove is called once every read and not for every message processed. Maybe it does not matter as this was not noticed so far, so messages mostly come one at a

Re: [Spice-devel] [PATCH 1/3] inputs: Fix key_up/key_down naming mismatch

2014-12-15 Thread Jonathon Jongsma
On Fri, 2014-12-12 at 17:19 +0100, Christophe Fergeau wrote: > 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. > --- > server/inputs_channel.c | 10 +- >

Re: [Spice-devel] [xf86-video-qxl v5] Enable smartcard support for XSpice.

2014-12-15 Thread Jeremy White
Hi Uri, +AC_ARG_ENABLE([ccid], +[AS_HELP_STRING([--enable-ccid], +[Build the spiceccid SmartCard driver (default is no)])], +[enable_ccid=$enableval], +[enable_ccid=no]) +AC_ARG_WITH(ccid-module-dir, +[AS_HELP_STRING([--with-ccid-module

[Spice-devel] [PATCH 6/4] build-sys: Replace cpu detection error with warning

2014-12-15 Thread Christophe Fergeau
configure.ac currently errors out when trying to build on non-x86/non-ARM CPUs. Since the previous commits improved big endian support a lot, this commit replaces the error with a warning at configure time to make testing on big endian platforms easier. --- configure.ac | 18 +++--- 1

[Spice-devel] [PATCH 5/4] build-sys: Remove unused 'X86_64' conditional

2014-12-15 Thread Christophe Fergeau
X86_64 was defined as an AM_CONDITIONAL, but then nothing was using it. This commit gets rid of it. --- This patch and the next one comes at the end of the ppc patch series and replace patch 1/4 Christophe configure.ac | 1 - 1 file changed, 1 deletion(-) diff --git a/configure.ac b/configure.

Re: [Spice-devel] [PATCH 1/4] ppc: Get rid of CPU detection in configure.ac

2014-12-15 Thread Christophe Fergeau
On Fri, Dec 12, 2014 at 12:24:49PM -0500, Marc-André Lureau wrote: > Hi > > - Original Message - > > If we add support for big endian CPUs, this check becomes obsolete, we > > should fix bugs as they are reported on the untested archs. > > --- > > configure.ac | 18 -- > >

Re: [Spice-devel] [PATCH 2/4] ppc: Fix endianness handling in initial SPICE connection

2014-12-15 Thread Christophe Fergeau
On Fri, Dec 12, 2014 at 12:32:10PM -0500, Marc-André Lureau wrote: > > > - Original Message - > > This commit fixes enough endianness issues that it's possible to > > connect to a spice-server/qemu running on a big-endian box with a client > > running on a little-endian machine. > > > >

[Spice-devel] [spice-common 2/2] ppc: build-sys: Add big-endian support

2014-12-15 Thread Christophe Fergeau
From: Erlon Cruz A few files (the generated marshalling code and pixman-related utils) make use of WORDS_BIGENDIAN in order to do the right thing depending on endianness. configure.ac must call AC_C_BIGENDIAN for it to be defined. Signed-off-by: Erlon R. Cruz Signed-off-by: Rafael F. Santos Si

[Spice-devel] [spice-common 1/2] ppc: Fix lz magic endianness

2014-12-15 Thread Christophe Fergeau
From: Erlon Cruz Signed-off-by: Erlon R. Cruz Signed-off-by: Rafael F. Santos Signed-off-by: Fabiano Fidêncio --- common/lz.c | 4 +++- configure.ac | 1 + m4/spice-deps.m4 | 12 3 files changed, 16 insertions(+), 1 deletion(-) diff --git a/common/lz.c b/common/lz.c i

Re: [Spice-devel] [spice-common v2 07/11] build-sys: Move smartcard check to m4 macro

2014-12-15 Thread Christophe Fergeau
On Tue, Dec 09, 2014 at 09:23:48AM -0600, Jonathon Jongsma wrote: > ACK to this series, although it would be more accurate here (and in the > other macro docs) to say that it *appends* to $PREFIX_CFLAGS/LIBS rather > than *sets* them. I've now pushed this series with the change you suggested. Chr

Re: [Spice-devel] [xf86-video-qxl v5] Enable smartcard support for XSpice.

2014-12-15 Thread Uri Lublin
On 12/12/2014 09:39 PM, Jeremy White wrote: On 12/12/2014 12:16 PM, Marc-André Lureau wrote: +while (1) { +rc = read(ccid->fd, buf + pos, sizeof(buf) - pos); +if (rc == -1) +if (errno == EINTR) +continue; +else +break;

Re: [Spice-devel] [xf86-video-qxl v5] Enable smartcard support for XSpice.

2014-12-15 Thread Uri Lublin
Hi Jeremy, If you're sending v6, please consider the comments below. Most likely can be added later as separate patches. On 12/11/2014 11:04 PM, Jeremy White wrote: This is done by creating a Unix domain socket to which smartcard messages are transferred, using the vscard protocol. A further s