Re: [Qemu-devel] [PATCH] block/curl: Implement the libcurl timer callback interface

2014-01-24 Thread Kevin Wolf
Am 24.01.2014 um 14:56 hat Paolo Bonzini geschrieben: > From: Peter Maydell > > libcurl versions 7.16.0 and later have a timer callback interface which > must be implemented in order for libcurl to make forward progress (it > will sometimes rely on being called back on the timeout if there are >

[Qemu-devel] [PATCH] block/curl: Implement the libcurl timer callback interface

2014-01-24 Thread Paolo Bonzini
From: Peter Maydell libcurl versions 7.16.0 and later have a timer callback interface which must be implemented in order for libcurl to make forward progress (it will sometimes rely on being called back on the timeout if there are no file descriptors registered). Implement the callback, and use a

Re: [Qemu-devel] [PATCH] block/curl: Implement the libcurl timer callback interface

2014-01-16 Thread Paolo Bonzini
Il 16/01/2014 10:55, Peter Maydell ha scritto: > On 16 January 2014 08:38, Paolo Bonzini wrote: >> Il 15/01/2014 23:15, Peter Maydell ha scritto: >>> > +curl_multi_socket_action(s->multi, CURL_SOCKET_TIMEOUT, 0, &running); >>> The libcurl docs say "This function was added in libcurl 7.15.4

Re: [Qemu-devel] [PATCH] block/curl: Implement the libcurl timer callback interface

2014-01-16 Thread Peter Maydell
On 16 January 2014 08:38, Paolo Bonzini wrote: > Il 15/01/2014 23:15, Peter Maydell ha scritto: >> >>> > +curl_multi_socket_action(s->multi, CURL_SOCKET_TIMEOUT, 0, &running); >> The libcurl docs say "This function was added in libcurl 7.15.4, and >> is deemed stable since 7.16.0. " So if we

Re: [Qemu-devel] [PATCH] block/curl: Implement the libcurl timer callback interface

2014-01-16 Thread Kevin Wolf
Am 16.01.2014 um 10:24 hat Richard W.M. Jones geschrieben: > > On further investigation, the "No such file or directory" error occurs > when using snapshot=on. > > ie: > > This fails: > > ./x86_64-softmmu/qemu-system-x86_64 -drive > 'file=http://127.0.0.1/~rjones/cirros-0.3.1-x86_64-disk.img,i

Re: [Qemu-devel] [PATCH] block/curl: Implement the libcurl timer callback interface

2014-01-16 Thread Richard W.M. Jones
On further investigation, the "No such file or directory" error occurs when using snapshot=on. ie: This fails: ./x86_64-softmmu/qemu-system-x86_64 -drive 'file=http://127.0.0.1/~rjones/cirros-0.3.1-x86_64-disk.img,if=virtio,snapshot=on' This works: ./x86_64-softmmu/qemu-system-x86_64 -drive

Re: [Qemu-devel] [PATCH] block/curl: Implement the libcurl timer callback interface

2014-01-16 Thread Richard W.M. Jones
On Wed, Jan 15, 2014 at 11:06:23PM +0100, Paolo Bonzini wrote: > Il 15/01/2014 18:23, Peter Maydell ha scritto: > > libcurl versions 7.16.0 and later have a timer callback interface which > > must be implemented in order for libcurl to make forward progress (it > > will sometimes rely on being call

Re: [Qemu-devel] [PATCH] block/curl: Implement the libcurl timer callback interface

2014-01-16 Thread Paolo Bonzini
Il 15/01/2014 22:56, Peter Maydell ha scritto: > > We have had endless problems with it, including upstream discussions > > with curl people, summarised in this bug: > > > > https://bugzilla.redhat.com/show_bug.cgi?id=971790 > > Looking through the thread from upstream, I see they basically > said

Re: [Qemu-devel] [PATCH] block/curl: Implement the libcurl timer callback interface

2014-01-16 Thread Paolo Bonzini
Il 15/01/2014 23:15, Peter Maydell ha scritto: > >> > +curl_multi_socket_action(s->multi, CURL_SOCKET_TIMEOUT, 0, &running); > The libcurl docs say "This function was added in libcurl 7.15.4, and > is deemed stable since 7.16.0. " So if we want to keep supporting > pre-7.16 libcurl then we ne

Re: [Qemu-devel] [PATCH] block/curl: Implement the libcurl timer callback interface

2014-01-15 Thread Peter Maydell
On 15 January 2014 22:06, Paolo Bonzini wrote: > Il 15/01/2014 18:23, Peter Maydell ha scritto: >> libcurl versions 7.16.0 and later have a timer callback interface which >> must be implemented in order for libcurl to make forward progress (it >> will sometimes rely on being called back on the tim

Re: [Qemu-devel] [PATCH] block/curl: Implement the libcurl timer callback interface

2014-01-15 Thread Paolo Bonzini
Il 15/01/2014 18:23, Peter Maydell ha scritto: > libcurl versions 7.16.0 and later have a timer callback interface which > must be implemented in order for libcurl to make forward progress (it > will sometimes rely on being called back on the timeout if there are > no file descriptors registered).

Re: [Qemu-devel] [PATCH] block/curl: Implement the libcurl timer callback interface

2014-01-15 Thread Peter Maydell
On 15 January 2014 21:37, Richard W.M. Jones wrote: > On Wed, Jan 15, 2014 at 05:23:58PM +, Peter Maydell wrote: >> libcurl versions 7.16.0 and later have a timer callback interface which >> must be implemented in order for libcurl to make forward progress (it >> will sometimes rely on being c

Re: [Qemu-devel] [PATCH] block/curl: Implement the libcurl timer callback interface

2014-01-15 Thread Richard W.M. Jones
On Wed, Jan 15, 2014 at 05:23:58PM +, Peter Maydell wrote: > libcurl versions 7.16.0 and later have a timer callback interface which > must be implemented in order for libcurl to make forward progress (it > will sometimes rely on being called back on the timeout if there are > no file descripto

[Qemu-devel] [PATCH] block/curl: Implement the libcurl timer callback interface

2014-01-15 Thread Peter Maydell
libcurl versions 7.16.0 and later have a timer callback interface which must be implemented in order for libcurl to make forward progress (it will sometimes rely on being called back on the timeout if there are no file descriptors registered). Implement the callback, and use a QEMU AIO timer to ens