Re: [PATCH 1/2] Revert "network: Check for QOS before blindly using it"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Em sex., 22 de nov. de 2019 às 14:09, Erik Skultety
<eskultet@xxxxxxxxxx> escreveu:
>
> This reverts commit f4db846c32c0a1e99a0f62b340273e48f8a98ed3.
>
> This patch results in the following error when trying to start
> essentially any VM with default network:

This kind of issue should be caught by test driver, shouldn't it?

--
Julio Faracco

>
> unsupported configuration: QOS must be defined for network 'default'
>
> Coverity didn't see that the bandwidth == NULL it complained about in
> virNetDevBandwidthPlug was already checked properly in
> networkCheckBandwidth, thus causing networkPlugBandwidth to return 0
> and finish before a call to virNetDevBandwidthPlug would have been even
> made.
>
> Signed-off-by: Erik Skultety <eskultet@xxxxxxxxxx>
> ---
>  src/network/bridge_driver.c | 14 --------------
>  1 file changed, 14 deletions(-)
>
> diff --git a/src/network/bridge_driver.c b/src/network/bridge_driver.c
> index 9c49c70564..68bb916501 100644
> --- a/src/network/bridge_driver.c
> +++ b/src/network/bridge_driver.c
> @@ -4567,13 +4567,6 @@ networkAllocatePort(virNetworkObjPtr obj,
>              return -1;
>          }
>
> -        if (!port->bandwidth) {
> -            virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
> -                           _("QOS must be defined for network '%s'"),
> -                           netdef->name);
> -            return -1;
> -        }
> -
>          if (networkPlugBandwidth(obj, &port->mac, port->bandwidth, &port->class_id) < 0)
>              return -1;
>          break;
> @@ -4640,13 +4633,6 @@ networkAllocatePort(virNetworkObjPtr obj,
>                  }
>              }
>
> -            if (!port->bandwidth) {
> -                virReportError(VIR_ERR_CONFIG_UNSUPPORTED,
> -                               _("QOS must be defined for network '%s'"),
> -                               netdef->name);
> -                return -1;
> -            }
> -
>              if (networkPlugBandwidth(obj, &port->mac, port->bandwidth, &port->class_id) < 0)
>                  return -1;
>              break;
> --
> 2.23.0
>
> --
> libvir-list mailing list
> libvir-list@xxxxxxxxxx
> https://www.redhat.com/mailman/listinfo/libvir-list
>


--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux