pplies to QEMU as well - once we drop support
for CentOS 6 we should also drop support for any QEMU version that
doesn't support CentOS 6.
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
n :) I would definitely never have risked anything like that
in my previous life as a system administrator.
And of course we want to support way more than just RHEL and related
distros: this is about making the support shallower, not narrower :)
Cheers.
--
Andrea Bolognani
Software Engineer - Virtu
on eg. Ubuntu 12.04 instead of 14.04...
Thank you for taking the time to engage in this discussion, it's
been quite informative :)
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
= NULL && virStringListLength(cells) > 2) {
+if (cells != NULL &&
+virStringListLength((const char * const *) cells) > 2) {
if (virStorageBackendSheepdogAddVolume(conn, pool, cells[1]) < 0)
goto cleanup;
}
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
detected that device is not
available in QEMU, what's the point of adding '-usb' at all?
The only situation I can think of in which this approach actually
helps is when QEMU changes the default controller model associated
with '-usb', which I believe is going to happen on ppc64 to move
from OHCI to XHCI. But then again that's not going to be very good
for guest ABI stability, is it?
I guess the idea is to make a last-ditch effort to provide some
sort of USB controller, any sort of USB controller, to the guest
even though to the best of libvirt's knowledge the support just
isn't there.
So this is the current situation AFAIK. Suggestions on how to
improve it are very welcome :)
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
Mock libraries are used with LD_PRELOAD from test binaries that
are already linked against those libraries, so they will be able
to resolve the symbols anyway.
---
tests/Makefile.am | 6 --
1 file changed, 6 deletions(-)
diff --git a/tests/Makefile.am b/tests/Makefile.am
index c5986f0..fb862c
On Wed, 2016-02-10 at 17:36 +0100, Michal Privoznik wrote:
> On 10.02.2016 17:12, Andrea Bolognani wrote:
> > Mock libraries are used with LD_PRELOAD from test binaries that
> > are already linked against those libraries, so they will be able
> > to resolve the symbols anywa
This reverts commit 6aa90452aa63cb1e1ffa84ff5f93f5873bf810a0.
Turns out that not linking against libvirt and gnulib is okay for
regular Linux (and FreeBSD) builds, but makes mingw very unhappy.
.../virnetserverclientmock_la-virnetserverclientmock.o:
In function `virNetSocketGetSELinuxContex
at(a, b, strlen())' \
s/strlen()/strlen(b)/
ACK with at least the second fixed.
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
Returns: 0 if the execution succeeded, 1 if the script was not found
or invalid parameters, and -1 if script returned an error
so I wonder if it should be changed to 1 instead... The script can't
have returned an error if we haven't been able to build its path :)
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
Commit d82170d introduced a workaround for domtop: in that example
program, we define a symbol called ERROR for our own use, but since
a symbol with the same name is already defined in one of mingw's
header files, we get a warning when using that compiler.
domsuspend defines the same problematic s
On Wed, 2016-02-10 at 18:09 +, Daniel P. Berrange wrote:
> On Wed, Feb 10, 2016 at 06:33:21PM +0100, Andrea Bolognani wrote:
> > This reverts commit 6aa90452aa63cb1e1ffa84ff5f93f5873bf810a0.
> >
> > Turns out that not linking against libvirt and gnulib is okay for
&
;
Which is a good idea anyway, I guess :)
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
On Thu, 2016-02-11 at 09:49 +, Daniel P. Berrange wrote:
> On Thu, Feb 11, 2016 at 09:54:45AM +0100, Andrea Bolognani wrote:
> > On Wed, 2016-02-10 at 18:09 +, Daniel P. Berrange wrote:
> > > On Wed, Feb 10, 2016 at 06:33:21PM +0100, Andrea Bolognani wrote:
> >
This patches make sure mock libraries do not link against either
too many or too few libraries.
Cheers.
Andrea Bolognani (2):
tests: Use plain close() in mock code
tests: Link mock libraries against gnulib and gnulib only
tests/Makefile.am| 21 +++--
tests
Mock libraries should not be linked against libvirt, but some of
them did - fix that.
On the other hand, not linking against gnulib can cause build
failures on mingw, so define a new $(MOCKLIBS_LIBS) variable and
use it everywhere.
---
tests/Makefile.am | 21 +++--
1 file changed,
The virportallocatortest.c file is compiled both as a test case
and as a mock library; in the latter case, it can't use
VIR_FORCE_CLOSE() because mock libraries are not linked against
libvirt.
Replace VIR_FORCE_CLOSE() with plain close() to solve the issue.
---
tests/virportallocatortest.c | 2 +-
On Thu, 2016-02-11 at 11:17 +, Daniel P. Berrange wrote:
> On Thu, Feb 11, 2016 at 12:15:39PM +0100, Andrea Bolognani wrote:
> > This patches make sure mock libraries do not link against either
> > too many or too few libraries.
> >
> > Cheers.
> >
> >
.diff$$)
Yup, my bad.
I'll try to split off the mock part of virportallocatortest.c instead, so we
can still enjoy this check for the non-mock part of the test case. Stay tuned.
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
virportallocatormock was the only one using it, and has been
changed accordingly.
---
tests/Makefile.am| 10 +-
tests/virportallocatortest.c | 2 +-
2 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 1fe7d6b..359610f 1006
All mock libraries were called vir*mock except for this one; now
the naming is consistent across the board.
---
tests/Makefile.am | 14 +++---
tests/{virmockdbus.c => virdbusmock.c} | 2 +-
tests/virfirewalltest.c| 2 +-
tests/virpolkittest.c
Instead of compiling either the mock or the non-mock part of the
file based on a compiler flag, split the mock part off to its
own file.
---
tests/Makefile.am| 4 +-
tests/virportallocatormock.c | 108 ++
tests/virportallocatortest.c | 110 +++-
As mock libraries are not to be linked against libvirt, the
sc_prohibit_close syntax-check rule does not apply.
This fixes a syntax-check failure introduced by commit a03cbfe0fb.
---
cfg.mk | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/cfg.mk b/cfg.mk
index 3f78842..5b864af
Commit a03cbfe0fb introduced a syntax-check failure: patch
1/4 prepares for 2/4, where the failure is actually fixed.
Patches 3/4 and 4/4 improve the naming consistency for mock
libraries by shuffling files around a bit.
Cheers.
Andrea Bolognani (4):
tests: Split off the mock part of the
On Thu, 2016-02-11 at 15:45 +0100, Ján Tomko wrote:
> On Thu, Feb 11, 2016 at 02:36:28PM +0100, Andrea Bolognani wrote:
> > Instead of compiling either the mock or the non-mock part of the
> > file based on a compiler flag, split the mock part off to its
> > own fil
On Thu, 2016-02-11 at 12:34 +0100, Andrea Bolognani wrote:
> On Thu, 2016-02-11 at 11:17 +, Daniel P. Berrange wrote:
> > On Thu, Feb 11, 2016 at 12:15:39PM +0100, Andrea Bolognani wrote:
> > > This patches make sure mock libraries do not link against either
> > > to
proper solution by any stretch of the imagination, but I'm
afraid that we're currently limiting a bunch of other tests to
Linux only while they would work on other platforms as well...
Let's get the mingw build working again for now: going through
the tests to decide which one shoul
On Fri, 2016-02-12 at 16:32 +0100, Michal Privoznik wrote:
> On 10.02.2016 19:44, Andrea Bolognani wrote:
> > Commit d82170d introduced a workaround for domtop: in that example
> > program, we define a symbol called ERROR for our own use, but since
> > a symbol with the
on, but I think that was mostly to keep things simple and not
because the QMP command approach was wrong?
IOW Dan, if we went ahead with the QMP command approach, would you
oppose it? Peter Xu has posted some RFC QEMU patches yesterday...
Cheers.
--
Andrea Bolognani
Software Engineer - Virtual
c | 2 +-
> src/util/virstoragefile.c | 2 +-
> tools/virsh.c | 2 +-
> 7 files changed, 7 insertions(+), 7 deletions(-)
I will never not love this kind of patch :)
ACK
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing lis
irtualization type, architecture and machine type as
inputs.
Since GIC is only available for the virt machine type on ARM hosts,
and the GIC versions might be limited by using TCG instead of KVM,
it seems like it would fit nicely...
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization T
On Tue, 2016-02-16 at 12:09 +, Peter Maydell wrote:
> On 16 February 2016 at 12:05, Andrea Bolognani wrote:
> > The idea is to add this information to domain capabilities, which
> > already have virtualization type, architecture and machine type as
> > inputs.
>
On Tue, 2016-02-16 at 12:15 +, Daniel P. Berrange wrote:
> On Tue, Feb 16, 2016 at 01:05:45PM +0100, Andrea Bolognani wrote:
> > On Tue, 2016-02-16 at 10:15 +, Daniel P. Berrange wrote:
> > > > Back to GIV. Recognized values of gic-version are fixed at compile
>
an do in libvirt beside passing through whatever value the user
has specified in the domain XML and report QEMU's error on failure?
I had underestimated the performance implications of spawning more
QEMU processes, thanks for highlighting them.
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
ments and pushed the series; the
documentation update you recommended will be prepared and posted
shortly.
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
Since no value in the virGICVersion enumeration is negative, a clever
enough compiler can report an error such as
src/conf/domain_conf.c:15337:75: error: comparison of unsigned enum
expression < 0 is always false [-Werror,-Wtautological-compare]
if ((def->gic_version = virGICVersionTypeFro
Recent changes to the handling of GIC version, specifically commit
2a7b11eafb67, have clearly defined what values are acceptable for the
version attribute of the element. Update the documentation
accordingly.
---
docs/formatdomain.html.in | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
d
GIC v2 is the default, but checking against that specific version when
we want to know whether the default has been selected is potentially
error prone; using an alias instead makes it safer.
---
src/qemu/qemu_command.c | 7 +++
src/qemu/qemu_domain.c | 4 ++--
src/util/virgic.h | 3 +++
This was of course not meant to be a reply to the other patch,
but to be a separate thread... Sigh.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
here are a few cases where probing in advance would simply not
be feasible.
Any probing code added to libvirt would have to be kept around
forever to ensure compatibility with current QEMU versions, so it
should IMHO be seen as a last resort in case we can't live without
GIC versio
8,12 @@ mymain(void)
> QEMU_CAPS_DEVICE_VIRTIO_GPU,
> QEMU_CAPS_DEVICE_VIRTIO_GPU_VIRGL,
> QEMU_CAPS_DEVICE_VIDEO_PRIMARY);
> +DO_TEST("video-virtio-gpu-spice-gl", QEMU_CAPS_DEVICE,
Drop QEMU_CAPS_DEVICE here, we no longer support QEMU versions
that lack -device so that capability is always enabled[1].
Cheers.
[1] Just realized I accidentaly introduced it again in this test
program with one of my recent commits, better clean up :)
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
1,format=qcow2,\
-if=none,id=drive-ide0-0-0,cache=none \
+-drive file=/var/lib/libvirt/images/QEMUGuest1,format=qcow2,if=none,\
+id=drive-ide0-0-0,cache=none \
-device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \
-spice port=0,gl=on \
-device virtio-vga,id=video0,virgl=on,bus=pci.
Since commit 51045df01b3c, the QEMU_CAPS_DEVICE capability is enabled
automatically and shouldn't be passed as an argument to DO_TEST();
however, commit 998a936c4c1a accidentally introduced few such uses.
---
tests/qemuxml2argvtest.c | 10 +-
1 file changed, 5 insertions(+), 5 deletions(-)
orever. We already support lots and lots of similar cases
in libvirt, the difference being that in this case we would add
support for a new command *knowing in advance* that it will become
obsolete as soon as a proper implementation is available.
It might still be the right thing to do! I just w
break;
> > default:
> > break;
> > }
> >
> > but other people probably feel differently :)
>
> I understand your concern, but having that switch seems worse to me.
> Maybe we should make it statically explicit that VIR_TRISTATE_BOOL_YES
> == VIR_TRISTATE_SWITCH_ON..
Well, it's certainly more verbose but also more explicit. I, for one,
had to do a double take because I didn't notice right away that you
were using virTristateSwitch* in that case, and was wondering how it
could work at all. At the very least, I believe it deserves an
explanatory comment.
Let's wait for other people to weigh in on these three remaining
issues...
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
On Fri, 2016-02-19 at 13:47 +0100, Peter Krempa wrote:
> On Fri, Feb 19, 2016 at 13:25:38 +0100, Andrea Bolognani wrote:
> > Since commit 51045df01b3c, the QEMU_CAPS_DEVICE capability is enabled
> > automatically and shouldn't be passed as an argument to DO_TEST();
> > ho
nking about it some more, I'm starting to think
that we should report the same information as the kernel whenever
possible, and enhance it with hints such as capacity for tools
and admins, but carefully avoid being too clever for our own good.
We can paper over most of the differences between x8
On Fri, 2016-02-19 at 10:56 -0500, John Ferlan wrote:
>
> On 02/18/2016 10:28 AM, Andrea Bolognani wrote:
> > Recent changes to the handling of GIC version, specifically commit
> > 2a7b11eafb67, have clearly defined what values are acceptable for the
> > version attribute
On Fri, 2016-02-19 at 11:05 -0500, John Ferlan wrote:
>
> On 02/18/2016 10:28 AM, Andrea Bolognani wrote:
> > GIC v2 is the default, but checking against that specific version when
> > we want to know whether the default has been selected is potentially
> > error prone
On Tue, 2016-01-26 at 18:59 -0500, John Ferlan wrote:
> On 01/25/2016 11:21 AM, Andrea Bolognani wrote:
> > Mostly labels names and whitespace.
> >
> > No functional changes.
> > ---
> > src/util/virhostdev.c | 23 ++-
> > 1 file
No functional changes.
---
Pushed under the trivial rule.
tests/virhostdevtest.c | 16
tests/virpcitest.c | 2 +-
2 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/tests/virhostdevtest.c b/tests/virhostdevtest.c
index 1b30681..cadb66a 100644
--- a/tests/virhostd
0?
That's probably not it, I have 2.5.0 and I get the same
error when trying to apply it with 'git am'.
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
, SYSFS_CPU_PRESENT)) {
> /* These files are readable for all. */
> ret = (mode == F_OK || mode == R_OK) ? 0 : -1;
> } else if (STREQ(path, "/proc/mounts")) {
ACK once the commit message has been polished up.
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
The virHostdevIsVirtualFunction() was called exactly twice, and in
both cases the return value was saved to a temporary variable before
being checked. This would be okay if it improved readability, but in
this case is pretty pointless.
Get rid of the temporary variable and check the return value
d
virNetDevIsVirtualFunction() returns 1 if the interface is a
virtual function, 0 if it isn't and -1 on error. This means that,
despite the name suggesting otherwise, using it as a predicate is
not correct.
Fix two callers that were doing so adding an explicit check on
the return value.
---
src/ut
On Thu, 2016-02-25 at 15:51 +0100, Michal Privoznik wrote:
> On 25.02.2016 14:02, Andrea Bolognani wrote:
> >
> > The virHostdevIsVirtualFunction() was called exactly twice, and in
> > both cases the return value was saved to a temporary variable before
> > being checke
On Thu, 2016-02-25 at 15:51 +0100, Michal Privoznik wrote:
> On 25.02.2016 14:02, Andrea Bolognani wrote:
> >
> > virNetDevIsVirtualFunction() returns 1 if the interface is a
> > virtual function, 0 if it isn't and -1 on error. This means that,
> > despite the nam
he compiler will
complain about unused functions.
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
ute which takes the value "sdl", "vnc", "rdp" or "desktop":
> +attribute which takes the value "sdl", "vnc", "spice", "rdp" or
> +"desktop":
>
> "s
On Fri, 2016-02-26 at 11:52 +, Richard W.M. Jones wrote:
> On Fri, Feb 26, 2016 at 12:43:42PM +0100, Andrea Bolognani wrote:
> >
> > On Fri, 2016-02-26 at 10:00 +, Richard W.M. Jones wrote:
> > >
> > > Trivial documentation fix.
> > >
reading of
the output of 'info qtree' and poking around the guest is correct)
and the domain XML should reflect this fact.
Deviating from the actual (virtual) hardware is something that's
bound to come back and bite us at some point, I'm afraid, and we
should avoid it.
Cheers.
-
;t be found. (the
> latter assumes that aarch64 supports those controllers).
>
> Does that make any sense? I could try to code some of this up if you
> could test it (or help me get setup to test it myself).
I'm not sure I fully understand all of the above, but I'll pitch
in with my own proposal regardless :)
First, we make sure that
is always added automatically to the domain XML when using the
mach-virt machine type. Then, if
is present as well we default to virtio-pci, otherwise we use
the current default of virtio-mmio. This should allow management
applications, based on knowledge about the guest OS, to easily
pick between the two address schemes.
Does this sound like a good idea?
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
on top of the v1.2.9-maint branch.
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
On Fri, 2016-02-26 at 19:15 +0100, Andrea Bolognani wrote:
> On Fri, 2016-02-26 at 18:54 +0100, Florian Hubold wrote:
> >
> > Thanks for the previous fix, can I apply this also on top of v1.2.9-maint
> > branch
> > or does it require some subsequent commits from HEAD?
On Mon, 2016-02-22 at 09:35 +0800, Peter Xu wrote:
> On Fri, Feb 19, 2016 at 01:33:09PM +0100, Andrea Bolognani wrote:
> >
> > I didn't say it would be hard :)
> >
> > I just said that such compatibility code would have to be kept
> > around forever. We al
---
src/util/virhostdev.c | 7 ---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/src/util/virhostdev.c b/src/util/virhostdev.c
index 5be61cd..48a44bc 100644
--- a/src/util/virhostdev.c
+++ b/src/util/virhostdev.c
@@ -833,9 +833,10 @@ virHostdevReAttachPCIDevices(virHostdevManag
Ensure the code behaves properly even for situations that were not
being considered before, such as simply detaching devices from the
host without attaching them to a guest and attaching devices as
managed even though they had already been manually detached from
the host.
---
tests/virhostdevtest.
This is not just a cosmetic change: the name of the variable now
gives a hint about what it is supposed to be used for.
---
src/util/virhostdev.c | 234 +-
1 file changed, 117 insertions(+), 117 deletions(-)
diff --git a/src/util/virhostdev.c b/src/
virPCIDeviceListCount()'s return type is size_t, so variables that
store its return value should be of that type.
---
tests/virhostdevtest.c | 24 +---
1 file changed, 9 insertions(+), 15 deletions(-)
diff --git a/tests/virhostdevtest.c b/tests/virhostdevtest.c
index 77b119b..
Replace the term "loop" with the more generic "step". This allows us
to be more flexible and eg. have a step that consists in a single
function call.
Don't include the number of steps in the first comment of the
function, so that we can add or remove steps without having to worry
about keeping tha
When checking the number of devices added to a device list, use the
nhostdevs variable instead of its value, so that the test can keep
working even if more hostdevs are added.
---
tests/virhostdevtest.c | 14 +++---
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/tests/virhos
These comments explain the difference between a virPCIDevice
instance used for lookups and an actual device instance; some
information is also provided for specific uses.
---
src/util/virhostdev.c | 38 ++
1 file changed, 38 insertions(+)
diff --git a/src/util/
This variable is only used internally by the macro, so it's better to
move its definition inside the macro as well.
---
tests/virhostdevtest.c | 31 +--
1 file changed, 17 insertions(+), 14 deletions(-)
diff --git a/tests/virhostdevtest.c b/tests/virhostdevtest.c
index
Acronyms should be written in all caps.
---
src/util/virhostdev.c | 12 ++--
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/src/util/virhostdev.c b/src/util/virhostdev.c
index 46a385c..a7fb8b1 100644
--- a/src/util/virhostdev.c
+++ b/src/util/virhostdev.c
@@ -57,7 +57,7 @@ s
The only possible return values are true and false, so the return
type should be bool instead of int.
---
src/util/virhostdev.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/util/virhostdev.c b/src/util/virhostdev.c
index f08502b..d3e15b7 100644
--- a/src/util/virhostdev.
The new order aligns better with the virHostdev prefix.
---
src/util/virhostdev.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/src/util/virhostdev.c b/src/util/virhostdev.c
index d3e15b7..e2accb4 100644
--- a/src/util/virhostdev.c
+++ b/src/util/virhostdev.c
@@ -750,7 +
virHostdevGetPCIHostDeviceList() is similar but does not filter out
devices that are not in the active list; that said, we are looking
up the device in the active list just a few lines after anyway, so
we might as well just keep a single function around.
This also helps stress the fact the objects
ikely that I might have gotten something
wrong :) I haven't been able to figure out a way to split
it into smaller chunks, sorry
23 Another bug fix
24 Test the changes made by the rest of the series
Cheers.
Andrea Bolognani (24):
tests: hostdev: Remove mag
We might be just fine looking up the information in pcidevs, but
it wouldn't save us any trouble and it's better to be consistent.
---
src/util/virhostdev.c | 41 ++---
1 file changed, 22 insertions(+), 19 deletions(-)
diff --git a/src/util/virhostdev.c b/src/u
NULL checks are performed implicitly in the rest of the module,
including other allocations in the very same function.
---
src/util/virhostdev.c | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/src/util/virhostdev.c b/src/util/virhostdev.c
index 48a44bc..098207e 100644
-
Instead of considering each single step its own test case, create
high level test cases that reproduce a certain scenario.
---
tests/virhostdevtest.c | 119 -
1 file changed, 97 insertions(+), 22 deletions(-)
diff --git a/tests/virhostdevtest.c b/te
---
src/util/virhostdev.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/src/util/virhostdev.c b/src/util/virhostdev.c
index adc4eec..5be61cd 100644
--- a/src/util/virhostdev.c
+++ b/src/util/virhostdev.c
@@ -727,9 +727,6 @@ virHostdevPreparePCIDevices(virHostdevManagerPtr
hostdev_mgr,
Instead of forcing the values for the unbind_from_stub, remove_slot
and reprobe properties, look up the actual device and use that when
calling virPCIDeviceReattach().
This ensures the device is restored to its original state after
reattach: for example, if it was not bound to any driver before
de
If 'last_processed_hostdev_vf != -1' is false then, since the
loop counter 'i' starts at 0, 'i <= last_processed_hostdev_vf'
can't possibly be true and the loop body will never be executed.
Hence, the first check is completely redundant and can be safely
removed.
---
src/util/virhostdev.c | 3 +--
Always call CHECK_LIST_COUNT() to check the size of both the active
and inactive devices list.
---
tests/virhostdevtest.c | 34 --
1 file changed, 28 insertions(+), 6 deletions(-)
diff --git a/tests/virhostdevtest.c b/tests/virhostdevtest.c
index c1321b1..8dc92f6 1
Unmanaged devices, as the name suggests, are not detached
automatically from the host by libvirt before being attached to a
guest: it's the user's responsability to detach them manually
beforehand. If that preliminary step has not been performed, the
attach operation can't complete successfully.
I
We're in the hostdev module, so mgr is not an ambiguous name, and
in fact it's already used in some cases. Switch all the code over.
Take the chance to shorten declaration of
virHostdevIsPCINodeDeviceUsedData structures.
---
src/util/virhostdev.c | 155 +---
After this patch, ownership of virPCIDevice instances is very easy
to keep track of: for each host PCI device, the only instance that
actually matters is the one inside one of the bookkeeping list.
Whenever some operation needs to be performed on a PCI device, the
actual device is looked up first;
Change the extremely generic count1 and count2 to the more
descriptive active_count and inactive_count.
---
tests/virhostdevtest.c | 82 +-
1 file changed, 41 insertions(+), 41 deletions(-)
diff --git a/tests/virhostdevtest.c b/tests/virhostdevtest.
When we want to look up a device in a device list and we already
have the IDs from another source, we can simply use
virPCIDeviceListFindByIDs() instead of creating a temporary device
object.
---
src/util/virhostdev.c | 59 ---
1 file changed, 28 ins
r on
> Zanata. Are the translation moved into some new location?
Unfortunately I don't have the answer to this question, but I'm sure
someone else on the list will be able to explain what's going on...
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
lib
On Mon, 2016-03-07 at 22:03 -0500, Laine Stump wrote:
> On 03/07/2016 12:24 PM, Andrea Bolognani wrote:
> >
> > NULL checks are performed implicitly in the rest of the module,
> > including other allocations in the very same function.
> > ---
> > src/util/virho
f someone adds a variable called "count" to a function that uses
> this macro.
>
> Otherwise ACK.
I changed it to 'actualCount' before pushing, and explained the
reason for the change in the commit message.
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
On Mon, 2016-03-07 at 22:02 -0500, Laine Stump wrote:
> On 03/07/2016 12:24 PM, Andrea Bolognani wrote:
> >
> > ---
> > src/util/virhostdev.c | 3 ---
> > 1 file changed, 3 deletions(-)
> >
> > diff --git a/src/util/virhostdev.c b/src/util/virhost
On Mon, 2016-03-07 at 21:57 -0500, Laine Stump wrote:
> On 03/07/2016 12:24 PM, Andrea Bolognani wrote:
> >
> > Instead of considering each single step its own test case, create
> > high level test cases that reproduce a certain scenario.
> > ---
> &g
mber what a pcie-switch-downstream-port is.
This still doesn't help when it comes to providing PCI or PCIe
slots suitable for hotplugging: if you want to have three PCIe
devices at startup and still be able to hotplug up to two PCIe
devices later on, my understanding is that you would need t
On Wed, 2016-03-09 at 21:12 -0500, Cole Robinson wrote:
> @@ -45,6 +49,8 @@ h1, h2, h3, h4, h5, h6 {
> margin: 0px;
> padding: 0px;
> margin-top: 0.5em;
> + margin-bottom: 0.5em;
> + border-bottom:1px solid #aaa;
^ Missing space here
Cheers.
--
Now that headers and menu items are using a bigger font and more
generous spacing, they don't really need to be bold to stand out.
---
This applies on top of Cole's series
https://www.redhat.com/archives/libvir-list/2016-March/msg00323.html
docs/apps.html.in | 2 +-
docs/generic.css | 2 +-
pdated as
well to match the updated looks of the website.
I've also posted a small follow-up patch to improve the
style further:
https://www.redhat.com/archives/libvir-list/2016-March/msg00378.html
Cheers.
--
Andrea Bolognani
Software Engineer - Virtualization Team
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
the world where aarch64 uses pci for
> everything
I think it's way too early to flip the switch and default to
PCI addresses: my understanding is that guest OS support is
expected to be spotty at best for at least a couple more
years.
Cheers.
--
Andrea Bolognani
Software Engineer
501 - 600 of 8359 matches
Mail list logo