[libvirt] [PATCH v2] spec: drop anything older than Fedora 13

2014-08-22 Thread Eric Blake
RHEL 5 is based on libvirt 0.8.2, as was Fedora 13. RHEL 5 also happens to be the oldest box that we actively support with a buildbot, so it is time to clean up some crufty conditionals in the spec file that no longer are necessary for modern Fedora. Although it is probably okay to make further s

Re: [libvirt] [PATCH] qemu: check for active domain after agent interaction

2014-08-22 Thread Eric Blake
On 08/21/2014 12:50 AM, Martin Kletzander wrote: > On Wed, Aug 20, 2014 at 03:35:08PM -0600, Eric Blake wrote: >> Commit b606bbb41 reminded me that any time we drop locks to run >> back-to-back guest interaction commands, we have to check that >> the guest didn't disappear in between the two comman

Re: [libvirt] [PATCH] blockcopy: allow block device destination

2014-08-22 Thread Eric Blake
Ping On 08/13/2014 02:00 PM, Eric Blake wrote: > To date, anyone performing a block copy and pivot ends up with > the destination being treated as . While this > works for data access for a block device, it has at least one > noticeable shortcoming: virDomainGetBlockInfo() reports allocation > di

[libvirt] [PATCH v2 2/2] parallels: login to parallels SDK

2014-08-22 Thread Dmitry Guryanov
Add files parallels_sdk.c and parallels_sdk.h for code which works with SDK, so libvirt's code will not mix with dealing with parallels SDK. To use Parallels SDK you must first call PrlApi_InitEx function, and then you will be able to connect to a server with PrlSrv_LoginLocalEx function. When you

[libvirt] [PATCH v2 1/2] parallels: build with parallels SDK

2014-08-22 Thread Dmitry Guryanov
Executing prlctl command is not an optimal way to interact with Parallels Cloud Server (PCS), it's better to use parallels SDK, which is a remote API to paralles dispatcher service. We prepared opensource version of this SDK and published it on github, it's distributed under LGPL license. Here is

[libvirt] [PATCH v2 0/2] parallels: use parallels SDK instead of prlctl tool

2014-08-22 Thread Dmitry Guryanov
This patchset begins reworking of parallels driver. We have published Opensource version of parallels SDK (under LGPL license), so libvirt can link with it. Dmitry Guryanov (2): parallels: build with parallels SDK parallels: login to parallels SDK configure.ac | 11 +-

Re: [libvirt] [PATCH] Fix spacing around commas

2014-08-22 Thread Eric Blake
On 08/22/2014 07:14 AM, Michal Privoznik wrote: > On some places in the libvirt code we have: > > f(a,z) > > instead of > > f(a, z) > > This trivial patch fixes couple of such occurrences. > > Signed-off-by: Michal Privoznik > --- > > Pushed under trivial rule. Do we have a syntax-check

Re: [libvirt] [PATCH 0/3] Resolve some Coverity issues

2014-08-22 Thread John Ferlan
On 08/22/2014 11:28 AM, John Ferlan wrote: > Resolve some issues seen by my daily Coverity run. > > Interesting that they didn't show up on the internal Jenkins Coverity > scanner, but did show up on my daily run. Perhaps because I have 7.0.3 > and the Jenkins has 7.0.0... I also see 7.5.0 is a

Re: [libvirt] [PATCH v4 1/3] conf: Extend and introduce

2014-08-22 Thread Daniel P. Berrange
On Fri, Aug 22, 2014 at 10:51:18AM -0600, Eric Blake wrote: > On 08/22/2014 10:43 AM, Daniel P. Berrange wrote: > > >>> > >>> hvm > >>> -/usr/lib/xen/boot/hvmloader > >>> + >>> type='rom'>/usr/lib/xen/boot/hvmloader

Re: [libvirt] [PATCH v4 1/3] conf: Extend and introduce

2014-08-22 Thread Eric Blake
On 08/22/2014 10:43 AM, Daniel P. Berrange wrote: >>> >>> hvm >>> -/usr/lib/xen/boot/hvmloader >>> +>> type='rom'>/usr/lib/xen/boot/hvmloader >> >> readonly='yes' is a bit more typical of other XML constructs. >> >

Re: [libvirt] [PATCH v4 2/3] qemu: Implement extended loader and nvram

2014-08-22 Thread Eric Blake
On 08/21/2014 02:50 AM, Michal Privoznik wrote: > QEMU now supports UEFI with the following command line: > > -drive > file=/usr/share/OVMF/OVMF_CODE.fd,if=pflash,format=raw,unit=0,readonly=on \ > -drive file=/usr/share/OVMF/OVMF_VARS.fd,if=pflash,format=raw,unit=1 \ > > where the first line

Re: [libvirt] [PATCH 2/3] virnetsocket: Resolve Coverity RESOURCE_LEAK

2014-08-22 Thread John Ferlan
On 08/22/2014 12:42 PM, John Ferlan wrote: > > > On 08/22/2014 11:49 AM, Michal Privoznik wrote: >> On 22.08.2014 17:28, John Ferlan wrote: >>> Since '1b807f92d' - Coverity complains that in the error paths of >>> both virFork() and virProcessWait() that the 'passfd' will not be closed >>> >>>

Re: [libvirt] [PATCH 2/2] parallels: login to parallels SDK

2014-08-22 Thread Dmitry Guryanov
On Friday 22 August 2014 16:38:11 Michal Privoznik wrote: > On 21.08.2014 22:36, Dmitry Guryanov wrote: > > Add files parallels_sdk.c and parallels_sdk.h for code > > which works with SDK, so libvirt's code will not mix with > > dealing with parallels SDK. > > > > To use Parallels SDK you must fir

Re: [libvirt] [PATCH v4 1/3] conf: Extend and introduce

2014-08-22 Thread Daniel P. Berrange
On Fri, Aug 22, 2014 at 10:41:13AM -0600, Eric Blake wrote: > On 08/21/2014 02:50 AM, Michal Privoznik wrote: > > Up to now, users can configure BIOS via the element. With > > the upcoming implementation of UEFI this is not enough as BIOS and > > UEFI are conceptually different. For instance, whil

Re: [libvirt] [PATCH 3/3] xenconfig: Resolve Coverity RESOURCE_LEAK

2014-08-22 Thread John Ferlan
On 08/22/2014 11:28 AM, John Ferlan wrote: > Since '337a13628' - Coverity complains that 'net' is VIR_ALLOC()'d, but > on various 'cleanup' exit paths from the code there is no corresponding > cleanup. Since 'net' is eventually appended onto a list of nets we don't > want to delete the last one

Re: [libvirt] [PATCH 2/3] virnetsocket: Resolve Coverity RESOURCE_LEAK

2014-08-22 Thread John Ferlan
On 08/22/2014 11:49 AM, Michal Privoznik wrote: > On 22.08.2014 17:28, John Ferlan wrote: >> Since '1b807f92d' - Coverity complains that in the error paths of >> both virFork() and virProcessWait() that the 'passfd' will not be closed >> >> Signed-off-by: John Ferlan >> --- >> src/rpc/virnetso

Re: [libvirt] [PATCH v4 1/3] conf: Extend and introduce

2014-08-22 Thread Eric Blake
On 08/21/2014 02:50 AM, Michal Privoznik wrote: > Up to now, users can configure BIOS via the element. With > the upcoming implementation of UEFI this is not enough as BIOS and > UEFI are conceptually different. For instance, while BIOS is ROM, UEFI > is programmable flash (although all writes to

Re: [libvirt] [PATCH 2/2] parallels: login to parallels SDK

2014-08-22 Thread Dmitry Guryanov
On Friday 22 August 2014 16:38:11 Michal Privoznik wrote: > On 21.08.2014 22:36, Dmitry Guryanov wrote: > > Add files parallels_sdk.c and parallels_sdk.h for code > > which works with SDK, so libvirt's code will not mix with > > dealing with parallels SDK. > > > > To use Parallels SDK you must fir

Re: [libvirt] [PATCH 3/3] xenconfig: Resolve Coverity RESOURCE_LEAK

2014-08-22 Thread Ján Tomko
On 08/22/2014 05:28 PM, John Ferlan wrote: > Since '337a13628' - Coverity complains that 'net' is VIR_ALLOC()'d, but > on various 'cleanup' exit paths from the code there is no corresponding > cleanup. Since 'net' is eventually appended onto a list of nets we don't > want to delete the last one -

Re: [libvirt] [PATCH 2/3] virnetsocket: Resolve Coverity RESOURCE_LEAK

2014-08-22 Thread Ján Tomko
On 08/22/2014 05:28 PM, John Ferlan wrote: > Since '1b807f92d' - Coverity complains that in the error paths of > both virFork() and virProcessWait() that the 'passfd' will not be closed > > Signed-off-by: John Ferlan > --- > src/rpc/virnetsocket.c | 8 ++-- > 1 file changed, 6 insertions(+),

Re: [libvirt] [PATCH 1/3] commandtest: Resolve Coverity RESOURCE_LEAK

2014-08-22 Thread Ján Tomko
On 08/22/2014 05:28 PM, John Ferlan wrote: > Since '62f263a73' - Coverity complains if the !pidfile path is taken, > then newfd1 would be leaked. > > Signed-off-by: John Ferlan > --- > tests/commandtest.c | 1 + > 1 file changed, 1 insertion(+) ACK Jan signature.asc Description: OpenPGP dig

Re: [libvirt] [PATCH 1/2] parallels: build with parallels SDK

2014-08-22 Thread Dmitry Guryanov
On Friday 22 August 2014 16:38:17 Michal Privoznik wrote: > On 21.08.2014 22:36, Dmitry Guryanov wrote: > > Executing prlctl command is not an optimal way to interact with > > Parallels Cloud Server (PCS), it's better to use parallels SDK, > > which is a remote API to paralles dispatcher service. >

Re: [libvirt] [PATCH 3/3] xenconfig: Resolve Coverity RESOURCE_LEAK

2014-08-22 Thread Michal Privoznik
On 22.08.2014 17:28, John Ferlan wrote: Since '337a13628' - Coverity complains that 'net' is VIR_ALLOC()'d, but on various 'cleanup' exit paths from the code there is no corresponding cleanup. Since 'net' is eventually appended onto a list of nets we don't want to delete the last one - be sure t

Re: [libvirt] [PATCH 2/3] virnetsocket: Resolve Coverity RESOURCE_LEAK

2014-08-22 Thread Michal Privoznik
On 22.08.2014 17:28, John Ferlan wrote: > Since '1b807f92d' - Coverity complains that in the error paths of > both virFork() and virProcessWait() that the 'passfd' will not be closed > > Signed-off-by: John Ferlan > --- > src/rpc/virnetsocket.c | 8 ++-- > 1 file changed, 6 insertions(+),

Re: [libvirt] [PATCH 1/3] commandtest: Resolve Coverity RESOURCE_LEAK

2014-08-22 Thread Michal Privoznik
On 22.08.2014 17:28, John Ferlan wrote: Since '62f263a73' - Coverity complains if the !pidfile path is taken, then newfd1 would be leaked. Signed-off-by: John Ferlan --- tests/commandtest.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/commandtest.c b/tests/commandtest.c index b3

[libvirt] [PATCH 3/3] xenconfig: Resolve Coverity RESOURCE_LEAK

2014-08-22 Thread John Ferlan
Since '337a13628' - Coverity complains that 'net' is VIR_ALLOC()'d, but on various 'cleanup' exit paths from the code there is no corresponding cleanup. Since 'net' is eventually appended onto a list of nets we don't want to delete the last one - be sure to set it to NULL, but still call the free

[libvirt] [PATCH 2/3] virnetsocket: Resolve Coverity RESOURCE_LEAK

2014-08-22 Thread John Ferlan
Since '1b807f92d' - Coverity complains that in the error paths of both virFork() and virProcessWait() that the 'passfd' will not be closed Signed-off-by: John Ferlan --- src/rpc/virnetsocket.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/rpc/virnetsocket.c b/sr

[libvirt] [PATCH 1/3] commandtest: Resolve Coverity RESOURCE_LEAK

2014-08-22 Thread John Ferlan
Since '62f263a73' - Coverity complains if the !pidfile path is taken, then newfd1 would be leaked. Signed-off-by: John Ferlan --- tests/commandtest.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/commandtest.c b/tests/commandtest.c index b3287fa..5f52a00 100644 --- a/tests/commandtes

[libvirt] [PATCH 0/3] Resolve some Coverity issues

2014-08-22 Thread John Ferlan
Resolve some issues seen by my daily Coverity run. Interesting that they didn't show up on the internal Jenkins Coverity scanner, but did show up on my daily run. Perhaps because I have 7.0.3 and the Jenkins has 7.0.0... I also see 7.5.0 is available - I'll give that a go too... John Ferlan (3):

Re: [libvirt] [PATCH v2 1/3] virfile: Refactor safezero, introduce virFileFdPosixFallocate

2014-08-22 Thread Daniel P. Berrange
On Fri, Aug 22, 2014 at 04:15:14PM +0100, Daniel P. Berrange wrote: > On Fri, Aug 22, 2014 at 10:56:47AM -0400, John Ferlan wrote: > > > > > > On 08/22/2014 10:46 AM, Daniel P. Berrange wrote: > > > On Mon, Aug 11, 2014 at 04:30:19PM -0400, John Ferlan wrote: > > >> Currently the safezero() funct

[libvirt] [PATCH 3/3] qemu: add support for splash-timeout

2014-08-22 Thread Martin Kletzander
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1021703 Signed-off-by: Martin Kletzander --- src/qemu/qemu_command.c | 15 +++ .../qemuxml2argv-boot-menu-enable-with-timeout.args | 15 +++ tests/qemuxml2argvtest.c

Re: [libvirt] [PATCH v2 1/3] virfile: Refactor safezero, introduce virFileFdPosixFallocate

2014-08-22 Thread Daniel P. Berrange
On Fri, Aug 22, 2014 at 10:56:47AM -0400, John Ferlan wrote: > > > On 08/22/2014 10:46 AM, Daniel P. Berrange wrote: > > On Mon, Aug 11, 2014 at 04:30:19PM -0400, John Ferlan wrote: > >> Currently the safezero() function uses build conditionals to choose either > >> the posix_fallocate() or mmap(

[libvirt] [PATCH 1/3] docs, conf: add support for bootmenu timeout

2014-08-22 Thread Martin Kletzander
Signed-off-by: Martin Kletzander --- docs/formatdomain.html.in | 7 +- docs/schemas/domaincommon.rng | 5 src/conf/domain_conf.c | 21 ++-- src/conf/domain_conf.h | 2 ++

[libvirt] [PATCH 0/3] Add support for boot menu timeout

2014-08-22 Thread Martin Kletzander
This is basically just for qemu's '-boot splash-time' parameter. Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1021703 Martin Kletzander (3): docs, conf: add support for bootmenu timeout qemu: add capability probing for splash-timeout qemu: add support for splash-timeout docs/form

[libvirt] [PATCH 2/3] qemu: add capability probing for splash-timeout

2014-08-22 Thread Martin Kletzander
Signed-off-by: Martin Kletzander --- src/qemu/qemu_capabilities.c | 5 + src/qemu/qemu_capabilities.h | 1 + tests/qemucapabilitiesdata/caps_1.5.3-1.caps | 1 + tests/qemucapabilitiesdata/caps_1.6.0-1.caps | 1 + tests/qemucapabilitiesdata/caps_1.6.50-1

Re: [libvirt] [PATCHv2] qemu: min_guarantee: Parameter 'min_guarantee' not supported

2014-08-22 Thread Ján Tomko
On 08/13/2014 10:07 AM, Erik Skultety wrote: > The 'min_guarantee' is used by VMware ESX and OpenVZ drivers, > with qemu however, libvirt should report error when starting a domain, > because this element is not used. > Resolves https://bugzilla.redhat.com/show_bug.cgi?id=1122455 > --- > docs/form

Re: [libvirt] [PATCHv3] numatune: setting --mode does not work well

2014-08-22 Thread Ján Tomko
On 08/22/2014 04:05 PM, Erik Skultety wrote: > When trying to set numatune mode directly using virsh numatune command, > correct error is raised, however numatune structure was not deallocated, > thus resulting in creating an empty numatune element in the guest XML, > if none was present before. Ru

Re: [libvirt] [PATCH] iotune: setting an invalid value now reports error

2014-08-22 Thread Ján Tomko
On 08/21/2014 02:28 PM, Erik Skultety wrote: > When trying to set an invalid value into iotune element, standard > behavior was to not report any error, rather to reset all affected > subelements of the iotune element back to 0 which results in ignoring > those particular subelements by XML generat

Re: [libvirt] [PATCH v2 1/3] virfile: Refactor safezero, introduce virFileFdPosixFallocate

2014-08-22 Thread John Ferlan
On 08/22/2014 10:46 AM, Daniel P. Berrange wrote: > On Mon, Aug 11, 2014 at 04:30:19PM -0400, John Ferlan wrote: >> Currently the safezero() function uses build conditionals to choose either >> the posix_fallocate() or mmap() with a fallback to safewrite() in order to >> preallocate a file. >> >>

Re: [libvirt] [PATCH v2 1/3] virfile: Refactor safezero, introduce virFileFdPosixFallocate

2014-08-22 Thread Daniel P. Berrange
On Mon, Aug 11, 2014 at 04:30:19PM -0400, John Ferlan wrote: > Currently the safezero() function uses build conditionals to choose either > the posix_fallocate() or mmap() with a fallback to safewrite() in order to > preallocate a file. > > This patch will modify the logic in order to allow fallba

Re: [libvirt] [PATCH v2 3/3] virstoragefile: Refactor virStorageFileResize

2014-08-22 Thread Daniel P. Berrange
On Fri, Aug 22, 2014 at 04:32:09PM +0200, Ján Tomko wrote: > On 08/21/2014 06:51 PM, John Ferlan wrote: > ACK to safezero implementation with all four methods: > > int > safezero(int fd, off_t offset, off_t len) > { > if (virFileFdPosixFallocate(fd, offset, len) == 0) > return 0; >

Re: [libvirt] [PATCH v2 3/3] virstoragefile: Refactor virStorageFileResize

2014-08-22 Thread John Ferlan
On 08/22/2014 10:32 AM, Ján Tomko wrote: > On 08/21/2014 06:51 PM, John Ferlan wrote: >> >> <...snip...> >> Hmm.. Perhaps a better way to do this would be to modify safezero() to >> add a 4th boolean parameter "resize" and make the "safezero_mmap()" be >> the false side and the check/call to SYS

Re: [libvirt] [PATCH 2/2] parallels: login to parallels SDK

2014-08-22 Thread Michal Privoznik
On 21.08.2014 22:36, Dmitry Guryanov wrote: Add files parallels_sdk.c and parallels_sdk.h for code which works with SDK, so libvirt's code will not mix with dealing with parallels SDK. To use Parallels SDK you must first call PrlApi_InitEx function, and then you will be able to connect to a serv

Re: [libvirt] [PATCH 1/2] parallels: build with parallels SDK

2014-08-22 Thread Michal Privoznik
On 21.08.2014 22:36, Dmitry Guryanov wrote: Executing prlctl command is not an optimal way to interact with Parallels Cloud Server (PCS), it's better to use parallels SDK, which is a remote API to paralles dispatcher service. We prepared opensource version of this SDK and published it on github,

Re: [libvirt] [PATCH v2 3/3] virstoragefile: Refactor virStorageFileResize

2014-08-22 Thread Ján Tomko
On 08/21/2014 06:51 PM, John Ferlan wrote: > > > On 08/21/2014 11:53 AM, Ján Tomko wrote: >> On 08/11/2014 10:30 PM, John Ferlan wrote: >>> Currently virStorageFileResize() function uses build conditionals to >>> choose either the posix_fallocate() or mmap() with no fallback in order >>> to preal

[libvirt] [PATCHv3] numatune: setting --mode does not work well

2014-08-22 Thread Erik Skultety
When trying to set numatune mode directly using virsh numatune command, correct error is raised, however numatune structure was not deallocated, thus resulting in creating an empty numatune element in the guest XML, if none was present before. Running the same command aftewards results in a success

Re: [libvirt] [PATCH v2 4/5] Parallels: Add domainCreateWithFlags() function.

2014-08-22 Thread aburluka
This check supresses unused variable warning. I thought that it would be rather natural that just ATTRIBUTE_UNUSED. This flags will be used in new version of our driver based on our published SDK (https://github.com/Parallels/parallels-sdk). You are perfectly right, this code is a quite similiar

[libvirt] [PATCH] Fix spacing around commas

2014-08-22 Thread Michal Privoznik
On some places in the libvirt code we have: f(a,z) instead of f(a, z) This trivial patch fixes couple of such occurrences. Signed-off-by: Michal Privoznik --- Pushed under trivial rule. HACKING | 2 +- docs/hacking.html.in| 2 +- examples/o

Re: [libvirt] [PATCH v5 3/3] qemu: Automatically create NVRAM store

2014-08-22 Thread Laszlo Ersek
On 08/22/14 14:43, Michal Privoznik wrote: > On 22.08.2014 14:26, Laszlo Ersek wrote: >> one question >> >> On 08/22/14 14:08, Michal Privoznik wrote: >>> When using split UEFI image, it may come handy if libvirt manages per >>> domain _VARS file automatically. While the _CODE file is RO and can be

Re: [libvirt] [PATCH v2 4/5] Parallels: Add domainCreateWithFlags() function.

2014-08-22 Thread Ján Tomko
On 08/22/2014 01:04 PM, Alexander Burluka wrote: > domainCreateWithFlags function is used by OpenStack Nova to boot > instance. > --- > src/parallels/parallels_driver.c | 50 > > 1 file changed, 50 insertions(+) > > diff --git a/src/parallels/parallels_dr

Re: [libvirt] [PATCH v2 2/5] Parallels: fix error with video card RAM dimension

2014-08-22 Thread Ján Tomko
On 08/22/2014 01:04 PM, Alexander Burluka wrote: > Libvirt measures vram in Kbytes, not in bytes, so calculation > of Mbytes was incorrect. PCS server can take vram argument > with units, so I added K postfix to make params a little bit clearer. > --- > src/parallels/parallels_driver.c | 4 ++-- >

Re: [libvirt] [PATCH v2 3/5] Parallels: Change config report errors code.

2014-08-22 Thread Ján Tomko
On 08/22/2014 01:04 PM, Alexander Burluka wrote: > Wrong error code in config errors reporting was used. Fixed it. > --- > src/parallels/parallels_driver.c | 81 > > 1 file changed, 41 insertions(+), 40 deletions(-) ACK and pushed. Jan signature.asc D

Re: [libvirt] [PATCH v2 1/5] Parallels: add virNodeGetCPUMap().

2014-08-22 Thread Ján Tomko
On 08/22/2014 01:04 PM, Alexander Burluka wrote: > That function caused errors in libvirtd logs when OpenStack Nova > starts VM instance. > --- > src/parallels/parallels_driver.c | 11 +++ > 1 file changed, 11 insertions(+) > > diff --git a/src/parallels/parallels_driver.c > b/src/parall

Re: [libvirt] [PATCH v5 3/3] qemu: Automatically create NVRAM store

2014-08-22 Thread Michal Privoznik
On 22.08.2014 14:26, Laszlo Ersek wrote: one question On 08/22/14 14:08, Michal Privoznik wrote: When using split UEFI image, it may come handy if libvirt manages per domain _VARS file automatically. While the _CODE file is RO and can be shared among multiple domains, you certainly don't want t

Re: [libvirt] [PATCH v5 3/3] qemu: Automatically create NVRAM store

2014-08-22 Thread Laszlo Ersek
one question On 08/22/14 14:08, Michal Privoznik wrote: > When using split UEFI image, it may come handy if libvirt manages per > domain _VARS file automatically. While the _CODE file is RO and can be > shared among multiple domains, you certainly don't want to do that on > the _VARS file. This la

[libvirt] [PATCH v5 3/3] qemu: Automatically create NVRAM store

2014-08-22 Thread Michal Privoznik
When using split UEFI image, it may come handy if libvirt manages per domain _VARS file automatically. While the _CODE file is RO and can be shared among multiple domains, you certainly don't want to do that on the _VARS file. This latter one needs to be per domain. So at the domain startup process

[libvirt] [PATCH v5 2/3] qemu: Implement extended loader and nvram

2014-08-22 Thread Michal Privoznik
QEMU now supports UEFI with the following command line: -drive file=/usr/share/OVMF/OVMF_CODE.fd,if=pflash,format=raw,unit=0,readonly=on \ -drive file=/usr/share/OVMF/OVMF_VARS.fd,if=pflash,format=raw,unit=1 \ where the first line reflects and the second one . Moreover, these two lines obso

[libvirt] [PATCH v5 1/3] conf: Extend and introduce

2014-08-22 Thread Michal Privoznik
Up to now, users can configure BIOS via the element. With the upcoming implementation of UEFI this is not enough as BIOS and UEFI are conceptually different. For instance, while BIOS is ROM, UEFI is programmable flash (although all writes to code section are denied). Therefore we need new attribut

[libvirt] [PATCH v5 0/3] OVMF exposure

2014-08-22 Thread Michal Privoznik
Diff to v4: -rebased onto current master -introduced nvram/@template as requested by Dan -yet another Laszlo's review worked in Michal Privoznik (3): conf: Extend and introduce qemu: Implement extended loader and nvram qemu: Automatically create NVRAM store docs/formatdomain.html.in

[libvirt] [PATCH v2 5/5] Parallels: add events emiting while creating domain.

2014-08-22 Thread Alexander Burluka
--- src/parallels/parallels_driver.c | 9 + 1 file changed, 9 insertions(+) diff --git a/src/parallels/parallels_driver.c b/src/parallels/parallels_driver.c index d0f49b9..6a64ef4 100644 --- a/src/parallels/parallels_driver.c +++ b/src/parallels/parallels_driver.c @@ -2433,6 +2433,7 @@ pa

[libvirt] [PATCH v2 2/5] Parallels: fix error with video card RAM dimension

2014-08-22 Thread Alexander Burluka
Libvirt measures vram in Kbytes, not in bytes, so calculation of Mbytes was incorrect. PCS server can take vram argument with units, so I added K postfix to make params a little bit clearer. --- src/parallels/parallels_driver.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git

[libvirt] [PATCH v2 1/5] Parallels: add virNodeGetCPUMap().

2014-08-22 Thread Alexander Burluka
That function caused errors in libvirtd logs when OpenStack Nova starts VM instance. --- src/parallels/parallels_driver.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/src/parallels/parallels_driver.c b/src/parallels/parallels_driver.c index bb9538f..6534fdb 100644 --- a/src/par

[libvirt] [PATCH v2 4/5] Parallels: Add domainCreateWithFlags() function.

2014-08-22 Thread Alexander Burluka
domainCreateWithFlags function is used by OpenStack Nova to boot instance. --- src/parallels/parallels_driver.c | 50 1 file changed, 50 insertions(+) diff --git a/src/parallels/parallels_driver.c b/src/parallels/parallels_driver.c index 0373830..d0f49b9 1

[libvirt] [PATCH v2 3/5] Parallels: Change config report errors code.

2014-08-22 Thread Alexander Burluka
Wrong error code in config errors reporting was used. Fixed it. --- src/parallels/parallels_driver.c | 81 1 file changed, 41 insertions(+), 40 deletions(-) diff --git a/src/parallels/parallels_driver.c b/src/parallels/parallels_driver.c index 3806e5e..037

[libvirt] [PATCH v2 0/5] Parallels: patchset

2014-08-22 Thread Alexander Burluka
Another patchset for Parallels libvirt driver. This patchset includes some minor bugfixing and adds some functions required to start OpenStack Changes in v2: fixed wrong error codes in config error handling. Alexander Burluka (5): Parallels: add virNodeGetCPUMap(). Parallels: fix error with

Re: [libvirt] [PATCH 0/3] storage: zfs: implement download and upload

2014-08-22 Thread Michal Privoznik
On 15.08.2014 10:44, Roman Bogorodskiy wrote: Roman Bogorodskiy (3): fdstream: report error if virSetNonBlock fails fdstream: introduce virFDStreamOpenBlockDevice storage: zfs: implement download and upload src/fdstream.c| 30 +++--- src/f

[libvirt] [PATCH v1 3/6] qemu: Add cap flag QEMU_CAPS_IVSHMEM

2014-08-22 Thread Maxime Leroy
Ivshmem is supported by QEMU since 0.13 release. Signed-off-by: Maxime Leroy --- src/qemu/qemu_capabilities.c | 3 +++ src/qemu/qemu_capabilities.h | 1 + tests/qemucapabilitiesdata/caps_1.2.2-1.caps | 1 + tests/qemucapabilitiesdata/caps_1.3.1-1.caps | 1

[libvirt] [PATCH v1 4/6] qemu: Build command line for ivshmem device

2014-08-22 Thread Maxime Leroy
This patch implements support for the ivshmem device in QEMU. Example from this xml: 32 The following QEMU line is built: -device ivshmem,size=32m,vectors=32,chardev=charshmem0,msi=on, ioeventfd=on,role=master -chardev socket,path=/tmp/socket-ivshmem0

[libvirt] [PATCH v1 5/6] tests: Add tests for ivshmem device handling

2014-08-22 Thread Maxime Leroy
Add XML parsing and qemu command line tests for the ivshmem device support. Signed-off-by: Maxime Leroy --- tests/qemuxml2argvdata/qemuxml2argv-ivshmem.args | 10 +++ tests/qemuxml2argvdata/qemuxml2argv-ivshmem.xml | 35 tests/qemuxml2argvtest.c

[libvirt] [PATCH v1 1/6] doc: schema: Add documentation for the shmem support

2014-08-22 Thread Maxime Leroy
This patch documents XML elements used for support of shmem devices. Considering there could be other shared memory related devices, this patch introduces a general device model, called shmem device. Currenly "ivshmem" is the only shared memory model supported. About ivshmem, please see the follo

[libvirt] [PATCH v1 6/6] ivshmem: add start param to server attribute

2014-08-22 Thread Maxime Leroy
With the new start param, we are able to start the ivshmem-server. With this xml: 32 Libvirt will execute an ivshmem-server: /usr/bin/ivshmem-server -m ivshmem0 -S /tmp/ivshmem0.sock \ -p /var/run/libvirt/ivshmem-server/ivshd-ivshmem0.pid -n 32 Signed-off-by: Max

[libvirt] [PATCH v1 2/6] conf: Parse and format shmem device XML

2014-08-22 Thread Maxime Leroy
This patch adds configuration support for the shmem device as described in the schema in the previous patch. Signed-off-by: Maxime Leroy --- src/conf/domain_conf.c | 249 ++- src/conf/domain_conf.h | 41 src/libvirt_private.syms | 2 +

[libvirt] [PATCH v1 0/6] ivshmem support

2014-08-22 Thread Maxime Leroy
The following patches are an implementation of a new shmem device to support ivshmem in libvirt. Any feedback is welcome. Changes since RFC: - replace by a more generic term - remove role attribute - libvirt is able to start and stop an ivshmem server - update xml format from: 32

Re: [libvirt] [PATCH v4 3/3] qemu: Automatically create NVRAM store

2014-08-22 Thread Laszlo Ersek
On 08/22/14 12:24, Daniel P. Berrange wrote: > On Fri, Aug 22, 2014 at 12:12:52PM +0200, Laszlo Ersek wrote: >> On 08/22/14 11:56, Daniel P. Berrange wrote: >>> On Fri, Aug 22, 2014 at 11:38:06AM +0200, Laszlo Ersek wrote: On 08/22/14 10:54, Daniel P. Berrange wrote: > On Fri, Aug 22, 2014

Re: [libvirt] [PATCH] virsh: Fix help info for freepages

2014-08-22 Thread Michal Privoznik
On 21.08.2014 05:19, Li Yang wrote: Signed-off-by: Li Yang --- tools/virsh-host.c |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/virsh-host.c b/tools/virsh-host.c index ae14311..ad821b3 100644 --- a/tools/virsh-host.c +++ b/tools/virsh-host.c @@ -263,10 +263

Re: [libvirt] [PATCH v4 3/3] qemu: Automatically create NVRAM store

2014-08-22 Thread Daniel P. Berrange
On Fri, Aug 22, 2014 at 12:12:52PM +0200, Laszlo Ersek wrote: > On 08/22/14 11:56, Daniel P. Berrange wrote: > > On Fri, Aug 22, 2014 at 11:38:06AM +0200, Laszlo Ersek wrote: > >> On 08/22/14 10:54, Daniel P. Berrange wrote: > >>> On Fri, Aug 22, 2014 at 10:27:29AM +0200, Laszlo Ersek wrote: >

Re: [libvirt] [PATCH] util: compare floor attribute in virNetDevBandwidthEqual

2014-08-22 Thread Michal Privoznik
On 22.08.2014 12:10, Martin Kletzander wrote: Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1064770 Signed-off-by: Martin Kletzander --- src/util/virnetdevbandwidth.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/util/virnetdevbandwidth.c b/src/util/virne

Re: [libvirt] [PATCH v4 3/3] qemu: Automatically create NVRAM store

2014-08-22 Thread Laszlo Ersek
On 08/22/14 11:56, Daniel P. Berrange wrote: > On Fri, Aug 22, 2014 at 11:38:06AM +0200, Laszlo Ersek wrote: >> On 08/22/14 10:54, Daniel P. Berrange wrote: >>> On Fri, Aug 22, 2014 at 10:27:29AM +0200, Laszlo Ersek wrote: On 08/21/14 11:05, Daniel P. Berrange wrote: > So the user has the

[libvirt] [PATCH] util: compare floor attribute in virNetDevBandwidthEqual

2014-08-22 Thread Martin Kletzander
Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1064770 Signed-off-by: Martin Kletzander --- src/util/virnetdevbandwidth.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/util/virnetdevbandwidth.c b/src/util/virnetdevbandwidth.c index 1e00116..5fa231a 100644 ---

Re: [libvirt] [PATCH v4 3/3] qemu: Automatically create NVRAM store

2014-08-22 Thread Daniel P. Berrange
On Fri, Aug 22, 2014 at 11:38:06AM +0200, Laszlo Ersek wrote: > On 08/22/14 10:54, Daniel P. Berrange wrote: > > On Fri, Aug 22, 2014 at 10:27:29AM +0200, Laszlo Ersek wrote: > >> On 08/21/14 11:05, Daniel P. Berrange wrote: > >>> So the user has the ability to specify a arbitrary BIOS in the XML,

[libvirt] [PATCH] libvirt: lxc: Add Get/Set vcpus for lxc

2014-08-22 Thread Li Yang
1.Add function to get vcpu count for lxc(vcpucount) 2.Add function to set vcpu count for lxc(setvcpus) Signed-off-by: Li Yang --- src/lxc/lxc_driver.c | 159 ++ 1 files changed, 159 insertions(+), 0 deletions(-) diff --git a/src/lxc/lxc_driver.c

[libvirt] [PATCH 2/3] virDriverLoadModule: Honor libvirt func name tranlsation

2014-08-22 Thread Michal Privoznik
There's this unwritten rule in libvirt that vir_function is translated into virFunction when needed (e.g. in remote protocol definition, python, ...). Up till now we ignored such translation in driver module loading and did fine. Well, we didn't have any module with an underscore in its name. But t

Re: [libvirt] [PATCH v4 3/3] qemu: Automatically create NVRAM store

2014-08-22 Thread Laszlo Ersek
On 08/22/14 10:54, Daniel P. Berrange wrote: > On Fri, Aug 22, 2014 at 10:27:29AM +0200, Laszlo Ersek wrote: >> On 08/21/14 11:05, Daniel P. Berrange wrote: >>> On Thu, Aug 21, 2014 at 10:50:24AM +0200, Michal Privoznik wrote: diff --git a/src/qemu/qemu.conf b/src/qemu/qemu.conf index 7bb

[libvirt] [PATCH 1/3] virdrivermoduletest: Test all the modules

2014-08-22 Thread Michal Privoznik
Even though we kept adding new and new modules (e.g. vbox or bhyve) the test wasn't updated. Do that now. Moreover, while it's not crucial, it's nice to reorder test cases to match the order in which the daemon loads the modules. Signed-off-by: Michal Privoznik --- tests/virdrivermoduletest.c |

[libvirt] [PATCH 0/3] Fix VirtualBox registration

2014-08-22 Thread Michal Privoznik
This is supposed to fix bug report which appeared on the list [1]. The driver registration ordering is back as it was, but the subdrivers are registered before. Unfortunately, if we don't want to dig vbox network and storage code out, we have to compile the sources couple of times. Michal Privozni

[libvirt] [PATCH 3/3] vbox: Register per partes

2014-08-22 Thread Michal Privoznik
Since times when vbox moved to the daemon (due to some licensing issue) the subdrivers that vbox implements were registered, but not opened since our generic subdrivers took priority. I've tried to fix this in 65b7d553f39ff9 but it was not correct. Apparently moving vbox driver registration upfront

[libvirt] [PATCH] build: fix mingw build with virCommandReorderFDs

2014-08-22 Thread Martin Kletzander
Signed-off-by: Martin Kletzander --- Notes: pushed as a build-breaker src/util/vircommand.c | 4 ++-- src/util/virutil.c| 12 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/src/util/vircommand.c b/src/util/vircommand.c index 3b3e6f5..1d6dbd9 100644 --- a/s

Re: [libvirt] [PATCH v4 3/3] qemu: Automatically create NVRAM store

2014-08-22 Thread Daniel P. Berrange
On Fri, Aug 22, 2014 at 10:27:29AM +0200, Laszlo Ersek wrote: > On 08/21/14 11:05, Daniel P. Berrange wrote: > > On Thu, Aug 21, 2014 at 10:50:24AM +0200, Michal Privoznik wrote: > >> diff --git a/src/qemu/qemu.conf b/src/qemu/qemu.conf > >> index 7bbbe09..79bba36 100644 > >> --- a/src/qemu/qemu.co

Re: [libvirt] RFC: sVirt disk isolation with network based storage

2014-08-22 Thread Daniel P. Berrange
On Thu, Aug 21, 2014 at 03:47:14PM -0400, Paul Moore wrote: > On Thursday, August 21, 2014 10:48:05 AM Daniel J Walsh wrote: > > I think we should setup a meeting to discuss this and figure out our option. > > Sorry I'm slow to the party, I'm at LSS/LinuxCon this week and the network > has > bee

Re: [libvirt] [PATCH v4 3/3] qemu: Automatically create NVRAM store

2014-08-22 Thread Laszlo Ersek
On 08/21/14 11:05, Daniel P. Berrange wrote: > On Thu, Aug 21, 2014 at 10:50:24AM +0200, Michal Privoznik wrote: >> diff --git a/src/qemu/qemu.conf b/src/qemu/qemu.conf >> index 7bbbe09..79bba36 100644 >> --- a/src/qemu/qemu.conf >> +++ b/src/qemu/qemu.conf >> @@ -487,3 +487,17 @@ >> # Defaults to

Re: [libvirt] [PATCH v4 3/3] qemu: Automatically create NVRAM store

2014-08-22 Thread Laszlo Ersek
comments below On 08/21/14 10:50, Michal Privoznik wrote: > When using split UEFI image, it may come handy if libvirt manages per > domain _VARS file automatically. While the _CODE file is RO and can be > shared among multiple domains, you certainly don't want to do that on > the _VARS file. This

Re: [libvirt] [PATCH v4 1/3] conf: Extend and introduce

2014-08-22 Thread Laszlo Ersek
On 08/21/14 10:50, Michal Privoznik wrote: > Up to now, users can configure BIOS via the element. With > the upcoming implementation of UEFI this is not enough as BIOS and > UEFI are conceptually different. For instance, while BIOS is ROM, UEFI > is programmable flash (although all writes to code

Re: [libvirt] [PATCH v4 2/3] qemu: Implement extended loader and nvram

2014-08-22 Thread Laszlo Ersek
On 08/21/14 10:50, Michal Privoznik wrote: > QEMU now supports UEFI with the following command line: > > -drive > file=/usr/share/OVMF/OVMF_CODE.fd,if=pflash,format=raw,unit=0,readonly=on \ > -drive file=/usr/share/OVMF/OVMF_VARS.fd,if=pflash,format=raw,unit=1 \ > > where the first line refl