[dpdk-dev] [PATCH v2] net/virtio: avoid annoying IOPL call related errors
Timothy Redaelli
tredaelli at redhat.com
Fri Nov 23 18:15:12 CET 2018
On Fri, 23 Nov 2018 17:36:20 +0300
Ilya Maximets <i.maximets at samsung.com> wrote:
> In case of running with not enough capabilities, i.e. running as
> non-root user any application linked with DPDK prints the message
> about IOPL call failure even if it was just called like
> './testpmd --help'. For example, this beaks most of the OVS unit
> tests if it built with DPDK support.
>
> Let's register the virtio driver unconditionally and print error
> message while probing the device. Silent iopl() call left in the
> constructor to have privileges as early as possible as it was before.
>
> Signed-off-by: Ilya Maximets <i.maximets at samsung.com>
> ---
>
> Version 2:
> * Fixed possible fd leak on BSD.
>
> We can avoid test failures in OVS by filtering the output
> like this:
> https://patchwork.ozlabs.org/project/openvswitch/list/?series=77706
>
> But it still looks very inconvenient for me to have this
> message in the output of every command for the DPDK linked app.
>
> drivers/net/virtio/virtio_ethdev.c | 11 ++++++-----
> lib/librte_eal/bsdapp/eal/eal.c | 6 ++++--
> 2 files changed, 10 insertions(+), 7 deletions(-)
Without this commit, if you link OVS as shared library
(--enable-shared), you'll also have this annoying message every time
you open a new (bash) shell, as user, due to OVS bash-completion:
[tredaell at aldebaran ~]$ bash
rte_virtio_pmd_init(): IOPL call failed - cannot use virtio PMD
rte_virtio_pmd_init(): IOPL call failed - cannot use virtio PMD
[tredaell at aldebaran ~]$
Acked-By: Timothy Redaelli <tredaelli at redhat.com>
More information about the dev
mailing list