From nobody Fri Apr 26 04:35:44 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) client-ip=205.139.110.61; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-1.mimecast.com [205.139.110.61]) by mx.zohomail.com with SMTPS id 1581351064858827.6100308821322; Mon, 10 Feb 2020 08:11:04 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-349-NhzptLTDMYaVk6aJOnI9dg-1; Mon, 10 Feb 2020 11:10:58 -0500 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id EE8D1801E6C; Mon, 10 Feb 2020 16:10:52 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 826B889F18; Mon, 10 Feb 2020 16:10:52 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 75AB7866D7; Mon, 10 Feb 2020 16:10:50 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 01AGAlhC023778 for ; Mon, 10 Feb 2020 11:10:47 -0500 Received: by smtp.corp.redhat.com (Postfix) id CB16827073; Mon, 10 Feb 2020 16:10:47 +0000 (UTC) Received: from localhost.localdomain.com (unknown [10.43.2.22]) by smtp.corp.redhat.com (Postfix) with ESMTP id 2B3AD27067; Mon, 10 Feb 2020 16:10:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581351063; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=vEi/aGIDI5KSiDb/ziHpvTb2PFVjovdhv+v7zpfO328=; b=heoiOlBdvey1NUyfkxkpOtln+024QQytZ0SPaGNkBIjQHIxom3hMYDZklxLSjdxsMCv2mG fWTmhXTcxtbe+ddAxRw3xn1bmzHj3OKoG+xl7MZMqur9vVDm1k5bo2M0yiGZaOaHVzTCKE cC9KSNSZFsIRwXmGBHFX5DloBPrjyVk= From: Pavel Mores To: libvir-list@redhat.com Subject: [libvirt PATCH 1/5] qemu: fail on attempt to set 'floor' if interface type is not 'network' Date: Mon, 10 Feb 2020 17:10:37 +0100 Message-Id: <20200210161041.515468-2-pmores@redhat.com> In-Reply-To: <20200210161041.515468-1-pmores@redhat.com> References: <20200210161041.515468-1-pmores@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-loop: libvir-list@redhat.com Cc: Pavel Mores X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-MC-Unique: NhzptLTDMYaVk6aJOnI9dg-1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" QoS 'floor' setting is documented to be only supported for interfaces of type 'network'. Fail with an error message on attempt to set 'floor' on an interface of any other type. Signed-off-by: Pavel Mores --- src/qemu/qemu_driver.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c index e69d083836..88fa56da42 100644 --- a/src/qemu/qemu_driver.c +++ b/src/qemu/qemu_driver.c @@ -11672,9 +11672,16 @@ qemuDomainSetInterfaceParameters(virDomainPtr dom, sizeof(*newBandwidth->out)); } =20 - if (net->type =3D=3D VIR_DOMAIN_NET_TYPE_NETWORK && - virDomainNetBandwidthUpdate(net, newBandwidth) < 0) - goto endjob; + if (net->type =3D=3D VIR_DOMAIN_NET_TYPE_NETWORK) { + if (virDomainNetBandwidthUpdate(net, newBandwidth) < 0) + goto endjob; + } else { + if (bandwidth->in && bandwidth->in->floor !=3D 0) { + virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", + _("'floor' is only supported for interface = type 'network' with forward type 'nat', 'route', 'open' or none")); + goto endjob; + } + } =20 if (virNetDevBandwidthSet(net->ifname, newBandwidth, false, !virDomainNetTypeSharesHostView(net)) < = 0) { --=20 2.24.1 From nobody Fri Apr 26 04:35:44 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) client-ip=205.139.110.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) by mx.zohomail.com with SMTPS id 1581351061943235.59497811200401; Mon, 10 Feb 2020 08:11:01 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-132-NAF9LpCLPcOHxUttlmbNQA-1; Mon, 10 Feb 2020 11:10:58 -0500 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 16E2E6125C; Mon, 10 Feb 2020 16:10:53 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id E5AA160BFB; Mon, 10 Feb 2020 16:10:52 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 817AF18089CD; Mon, 10 Feb 2020 16:10:50 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 01AGAmWc023789 for ; Mon, 10 Feb 2020 11:10:48 -0500 Received: by smtp.corp.redhat.com (Postfix) id C56A02706C; Mon, 10 Feb 2020 16:10:48 +0000 (UTC) Received: from localhost.localdomain.com (unknown [10.43.2.22]) by smtp.corp.redhat.com (Postfix) with ESMTP id 2604D27067; Mon, 10 Feb 2020 16:10:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581351060; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=+Y0XUAdv5tbwCmQUmn5CpH579f69EvydgbwdL6/9bLc=; b=gcp9k13vhdjEnf9UWUfKInCNiQxoa3yOYyLL3M0r1MZK5fdsEpf1XsAjUIw48d8Eq/9oec Q+8HuvXKJr36uHYr6WOcbuC/tV8lPkjO5Pr4in5G3seIEYjxi8QuRGq5SM5eXWskhyf9lR VzR6GLlvOCJZH+GbVQflQ8DW/rTuEk0= From: Pavel Mores To: libvir-list@redhat.com Subject: [libvirt PATCH 2/5] qemu: check if 'floor' is supported for given interface and network Date: Mon, 10 Feb 2020 17:10:38 +0100 Message-Id: <20200210161041.515468-3-pmores@redhat.com> In-Reply-To: <20200210161041.515468-1-pmores@redhat.com> References: <20200210161041.515468-1-pmores@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-loop: libvir-list@redhat.com Cc: Pavel Mores X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-MC-Unique: NAF9LpCLPcOHxUttlmbNQA-1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Even if an interface of type 'network', setting 'floor' is only supported if the network's forward type is nat, route, open or none. Signed-off-by: Pavel Mores --- src/network/bridge_driver.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/src/network/bridge_driver.c b/src/network/bridge_driver.c index 94212eec77..3b70e52afd 100644 --- a/src/network/bridge_driver.c +++ b/src/network/bridge_driver.c @@ -5062,9 +5062,26 @@ networkCheckBandwidth(virNetworkObjPtr obj, unsigned long long tmp_floor_sum =3D virNetworkObjGetFloorSum(obj); unsigned long long tmp_new_rate =3D 0; char ifmac[VIR_MAC_STRING_BUFLEN]; + virNetworkForwardType fwdType; + bool floorSupported; + bool floorRequested; =20 virMacAddrFormat(ifaceMac, ifmac); =20 + fwdType =3D def->forward.type; + floorSupported =3D fwdType =3D=3D VIR_NETWORK_FORWARD_NONE || + fwdType =3D=3D VIR_NETWORK_FORWARD_NAT || + fwdType =3D=3D VIR_NETWORK_FORWARD_ROUTE || + fwdType =3D=3D VIR_NETWORK_FORWARD_OPEN; + + floorRequested =3D ifaceBand && ifaceBand->in && ifaceBand->in->floor = !=3D 0; + + if (floorRequested && !floorSupported) { + virReportError(VIR_ERR_OPERATION_UNSUPPORTED, "%s", + _("'floor' is only supported for interface type 'ne= twork' with forward type 'nat', 'route', 'open' or none")); + return -1; + } + if (ifaceBand && ifaceBand->in && ifaceBand->in->floor && !(netBand && netBand->in)) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, --=20 2.24.1 From nobody Fri Apr 26 04:35:44 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) client-ip=205.139.110.61; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-2.mimecast.com [205.139.110.61]) by mx.zohomail.com with SMTPS id 15813510715161008.9544297150328; Mon, 10 Feb 2020 08:11:11 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-246-Ef4jH_f3P6CCPyO5MRbVQA-1; Mon, 10 Feb 2020 11:11:07 -0500 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 454421800D42; Mon, 10 Feb 2020 16:11:01 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 1E7AC8ED1B; Mon, 10 Feb 2020 16:11:01 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id CB969866DD; Mon, 10 Feb 2020 16:11:00 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 01AGAnFZ023794 for ; Mon, 10 Feb 2020 11:10:49 -0500 Received: by smtp.corp.redhat.com (Postfix) id C115427073; Mon, 10 Feb 2020 16:10:49 +0000 (UTC) Received: from localhost.localdomain.com (unknown [10.43.2.22]) by smtp.corp.redhat.com (Postfix) with ESMTP id 1FDEF27067; Mon, 10 Feb 2020 16:10:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581351070; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=JN+0eaMDrHBmAWfe7E+ZMz2yY8p3rZtb6aMrgmh8TLY=; b=eM+yTdmT+vxwRMi0Mo0zxPoKKdTON6zLqysfWWE6EmkteNERI3qRBlt4EI7eSQuyTf/o0O UFXZTlWxd7T3ra3CpSDBav66eHK1KJ4F9SB5Ckmwlb1qY6aaImJ0w9AAaJTrbWfpZsDlSJ WUiY36VAbEVK78t/f7rRA8jISzf2uJs= From: Pavel Mores To: libvir-list@redhat.com Subject: [libvirt PATCH 3/5] qemu: call networkPlugBandwidth() for all types of network Date: Mon, 10 Feb 2020 17:10:39 +0100 Message-Id: <20200210161041.515468-4-pmores@redhat.com> In-Reply-To: <20200210161041.515468-1-pmores@redhat.com> References: <20200210161041.515468-1-pmores@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-loop: libvir-list@redhat.com Cc: Pavel Mores X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-MC-Unique: Ef4jH_f3P6CCPyO5MRbVQA-1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" To fix the actual bug, it was necessary to make networkPlugBandwidth() be called also for 'bridge'-type networks implemented using macvtap's 'bridge' mode (previously it was only called for those implemented on top of an existing bridge). However, it seems beneficial to call it for other network types as well, at least because it removes an inconsistency in types of bandwidth configuration changes permissible in inactive and active domain configs. Signed-off-by: Pavel Mores Reviewed-by: Michal Privoznik --- src/network/bridge_driver.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/network/bridge_driver.c b/src/network/bridge_driver.c index 3b70e52afd..513ae59e68 100644 --- a/src/network/bridge_driver.c +++ b/src/network/bridge_driver.c @@ -4571,8 +4571,6 @@ networkAllocatePort(virNetworkObjPtr obj, return -1; } =20 - if (networkPlugBandwidth(obj, &port->mac, port->bandwidth, &port->= class_id) < 0) - return -1; break; =20 case VIR_NETWORK_FORWARD_HOSTDEV: { @@ -4637,8 +4635,6 @@ networkAllocatePort(virNetworkObjPtr obj, } } =20 - if (networkPlugBandwidth(obj, &port->mac, port->bandwidth, &po= rt->class_id) < 0) - return -1; break; } =20 @@ -4736,6 +4732,9 @@ networkAllocatePort(virNetworkObjPtr obj, return -1; } =20 + if (networkPlugBandwidth(obj, &port->mac, port->bandwidth, &port->clas= s_id) < 0) + return -1; + if (virNetworkObjMacMgrAdd(obj, driver->dnsmasqStateDir, port->ownername, &port->mac) < 0) return -1; --=20 2.24.1 From nobody Fri Apr 26 04:35:44 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) client-ip=205.139.110.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) by mx.zohomail.com with SMTPS id 1581351076608619.2553750608961; Mon, 10 Feb 2020 08:11:16 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-402-RZQUVtYxPfepzcdPzRHGHA-1; Mon, 10 Feb 2020 11:11:12 -0500 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 6F737107ACCA; Mon, 10 Feb 2020 16:11:05 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 440DB5E642; Mon, 10 Feb 2020 16:11:05 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id DE48118089CF; Mon, 10 Feb 2020 16:11:04 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 01AGAojo023806 for ; Mon, 10 Feb 2020 11:10:50 -0500 Received: by smtp.corp.redhat.com (Postfix) id BB3E427067; Mon, 10 Feb 2020 16:10:50 +0000 (UTC) Received: from localhost.localdomain.com (unknown [10.43.2.22]) by smtp.corp.redhat.com (Postfix) with ESMTP id 1AD8F2707D; Mon, 10 Feb 2020 16:10:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581351075; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=CrtJPt5mVdMCQY76rQ0PprX2A9SKiZydV2tXYErA/e0=; b=jGB1Dq8M/EZA800RafbIlciznUexNIz/KijoNt9hX58N1xTLp6sq6sb/cUKgFocES/wwRv QgNpczusfykcwIiDDMMkFPdfAhydulXS/DW9QNoNUJ4Wp1jh8AMLz9vQvHvRMh09TWVmjR QW1HV7DaHoTZGlhazXqJA4a2l3m6Mso= From: Pavel Mores To: libvir-list@redhat.com Subject: [libvirt PATCH 4/5] docs: QoS parameter 'floor' is supported for 'open' networks too Date: Mon, 10 Feb 2020 17:10:40 +0100 Message-Id: <20200210161041.515468-5-pmores@redhat.com> In-Reply-To: <20200210161041.515468-1-pmores@redhat.com> References: <20200210161041.515468-1-pmores@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-loop: libvir-list@redhat.com Cc: Pavel Mores X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-MC-Unique: RZQUVtYxPfepzcdPzRHGHA-1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Relevant code seems to treat forward modes 'route', 'nat', 'open' and none the same but documentation hasn't reflected that so far. Signed-off-by: Pavel Mores Reviewed-by: Michal Privoznik --- docs/formatnetwork.html.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/formatnetwork.html.in b/docs/formatnetwork.html.in index 2448fb09e7..3d807ecab6 100644 --- a/docs/formatnetwork.html.in +++ b/docs/formatnetwork.html.in @@ -631,7 +631,7 @@ goes through one point where QoS decisions can take place, hence why this attribute works only for virtual networks for now (that is <interface type=3D'network'/> with a - forward type of route, nat, or no forward at all). Moreover, the + forward type of route, nat, open or no forward at all). Moreover= , the virtual network the interface is connected to is required to have at least inbound QoS set (average at least). If using the floor attribute users don't need to speci= fy --=20 2.24.1 From nobody Fri Apr 26 04:35:44 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) client-ip=205.139.110.61; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-1.mimecast.com [205.139.110.61]) by mx.zohomail.com with SMTPS id 1581351070832415.0018907024736; Mon, 10 Feb 2020 08:11:10 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-78-eyc5p_UUNiqz09-xE83u8g-1; Mon, 10 Feb 2020 11:11:06 -0500 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 39DD28010D6; Mon, 10 Feb 2020 16:11:01 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 0DDE460C87; Mon, 10 Feb 2020 16:11:01 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id C1E1518089D0; Mon, 10 Feb 2020 16:11:00 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 01AGAppb023815 for ; Mon, 10 Feb 2020 11:10:51 -0500 Received: by smtp.corp.redhat.com (Postfix) id B5B5E27068; Mon, 10 Feb 2020 16:10:51 +0000 (UTC) Received: from localhost.localdomain.com (unknown [10.43.2.22]) by smtp.corp.redhat.com (Postfix) with ESMTP id 15A1F27067; Mon, 10 Feb 2020 16:10:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581351069; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=FBv9T3Z5/rH5brTRW4mfWrpm0piSPAa/b9k7Dhxt2Sc=; b=AwzfA7aBKWEeIVEdo7CvzAaWfbcL3Qf0r45jnvhbIz4WZ4zLpJso8+dDrfNr6LuQ318xIa +EqvkzuajA1mdV7X67wAMU4OENovsE2azd1x37RluXpt/hOi3kBGA1C4LpYlV6683ZDbcb +vl8Sq7SBFGz0eehfabxsmpgnCc9FFE= From: Pavel Mores To: libvir-list@redhat.com Subject: [libvirt PATCH 5/5] qemu: reuse convenience variable introduced in a00b97f27672b3 Date: Mon, 10 Feb 2020 17:10:41 +0100 Message-Id: <20200210161041.515468-6-pmores@redhat.com> In-Reply-To: <20200210161041.515468-1-pmores@redhat.com> References: <20200210161041.515468-1-pmores@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-loop: libvir-list@redhat.com Cc: Pavel Mores X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-MC-Unique: eyc5p_UUNiqz09-xE83u8g-1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Since we have the result of a compound condition named now we can use it to simplify another complex condition to make it more readable. Signed-off-by: Pavel Mores --- src/network/bridge_driver.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/network/bridge_driver.c b/src/network/bridge_driver.c index 513ae59e68..584c78cadb 100644 --- a/src/network/bridge_driver.c +++ b/src/network/bridge_driver.c @@ -5081,8 +5081,7 @@ networkCheckBandwidth(virNetworkObjPtr obj, return -1; } =20 - if (ifaceBand && ifaceBand->in && ifaceBand->in->floor && - !(netBand && netBand->in)) { + if (floorRequested && !(netBand && netBand->in)) { virReportError(VIR_ERR_OPERATION_UNSUPPORTED, _("Invalid use of 'floor' on interface with MAC " "address %s - network '%s' has no inbound QoS set= "), --=20 2.24.1