From: "Daniel P. Berrange" <berrange@redhat.com>
To: Niilona <niilona@gmail.com>
Cc: linux-pci@vger.kernel.org, libvir-list <libvir-list@redhat.com>
Subject: Re: [libvirt] PATCH: pci-subsystem: ixgbe: SR-IOV: kernel way to order driver's virtfn -entries is odd causing libvirt failures.
Date: Thu, 24 Oct 2013 09:12:05 +0100 [thread overview]
Message-ID: <20131024081205.GA7503@redhat.com> (raw)
In-Reply-To: <CAE5WV7OXKGvOCTOyZyK5cOCA2nxpN1WcDdqj9h+pakyhgT2sTA@mail.gmail.com>
On Thu, Oct 24, 2013 at 09:52:31AM +0300, Niilona wrote:
> Hi.
>
> As Bjorn Helgaas recommend, this might be the item to discuss in the wider area.
> -----------------------------------
>
> There is a behavior effecting virtfn -entries in sysfs, when amount of
> them increases over 10.
> Run VM's through LIBVIRT -> QEMU/KVM, this causes :
> - MAC address setting by LIBVIRT disordered ie. setting targeted to wrong VF.
> - VLAN setting by LIBVIRT overall failed
>
> Basics of this are in "/libvirt-x.x.x/src/util/virpci.c" ; in function below,
> which don't order virtfn entries correctly.
>
> /*
> * Returns virtual functions of a physical function
> */
> int
> virPCIGetVirtualFunctions(const char *sysfs_path,
> virPCIDeviceAddressPtr **virtual_functions,
> unsigned int *num_virtual_functions)
> {
>
> But I let you to decide which is best way to fix this, as if every
> application reads "virtfn" entries from PF's directory, they all need
> to sort entries in alphabet. order to avoid this
> influence.
> So personally I did get over this by adding pre-zeroes to names to
> have them in sorted order in PF's directory.
Libvirt has to work correctly with all existing released kernels,
so we have to fix libvirt to deal with ordering correctly. Thus
changing the kernel naming here doesn't really help. We need to
fix libvirt to deal with this.
Daniel
--
|: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org -o- http://virt-manager.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|
prev parent reply other threads:[~2013-10-24 8:12 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-24 6:52 PATCH: pci-subsystem: ixgbe: SR-IOV: kernel way to order driver's virtfn -entries is odd causing libvirt failures Niilona
2013-10-24 8:12 ` Daniel P. Berrange [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20131024081205.GA7503@redhat.com \
--to=berrange@redhat.com \
--cc=libvir-list@redhat.com \
--cc=linux-pci@vger.kernel.org \
--cc=niilona@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).