From d6b144b1fe3024f1f116de41a0274f0f5ced39de Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= Date: Fri, 13 Sep 2019 17:04:41 +0100 Subject: [PATCH] network: add debug when bandwidth settings are not applied MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit To aid in troubleshooting add some debug messages wrt bandwidth settings and networks. Reviewed-by: Laine Stump Signed-off-by: Daniel P. Berrangé --- src/network/bridge_driver.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/network/bridge_driver.c b/src/network/bridge_driver.c index 6a97bb17e2..c54be96407 100644 --- a/src/network/bridge_driver.c +++ b/src/network/bridge_driver.c @@ -5192,9 +5192,14 @@ networkCheckBandwidth(virNetworkObjPtr obj, return -1; } + if (!netBand || !netBand->in) { + VIR_DEBUG("No network bandwidth controls present"); + /* no QoS required, claim success */ + return 1; + } if (((!ifaceBand || !ifaceBand->in || !ifaceBand->in->floor) && - (!oldBandwidth || !oldBandwidth->in || !oldBandwidth->in->floor)) || - !netBand || !netBand->in) { + (!oldBandwidth || !oldBandwidth->in || !oldBandwidth->in->floor))) { + VIR_DEBUG("No old/new interface bandwidth floor"); /* no QoS required, claim success */ return 1; }