From: Peter Krempa Date: Mon, 16 Sep 2019 16:57:53 +0000 (+0200) Subject: qemu: driver: Remove pointless macro QEMU_BLOCK_STAT_TOTAL X-Git-Tag: v5.8.0-rc1~69 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=535b78ff033fd1300d3ff29e9f6e9259f480ecab;p=thirdparty%2Flibvirt.git qemu: driver: Remove pointless macro QEMU_BLOCK_STAT_TOTAL Signed-off-by: Peter Krempa Reviewed-by: Ján Tomko --- diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c index ee0b817a0d..c18fa179f7 100644 --- a/src/qemu/qemu_driver.c +++ b/src/qemu/qemu_driver.c @@ -11416,18 +11416,14 @@ static int qemuDomainBlockStatsGatherTotals(qemuBlockStatsPtr data, qemuBlockStatsPtr total) { -#define QEMU_BLOCK_STAT_TOTAL(NAME) \ - total->NAME += data->NAME - - QEMU_BLOCK_STAT_TOTAL(wr_bytes); - QEMU_BLOCK_STAT_TOTAL(wr_req); - QEMU_BLOCK_STAT_TOTAL(rd_bytes); - QEMU_BLOCK_STAT_TOTAL(rd_req); - QEMU_BLOCK_STAT_TOTAL(flush_req); - QEMU_BLOCK_STAT_TOTAL(wr_total_times); - QEMU_BLOCK_STAT_TOTAL(rd_total_times); - QEMU_BLOCK_STAT_TOTAL(flush_total_times); -#undef QEMU_BLOCK_STAT_TOTAL + total->wr_bytes += data->wr_bytes; + total->wr_req += data->wr_req; + total->rd_bytes += data->rd_bytes; + total->rd_req += data->rd_req; + total->flush_req += data->flush_req; + total->wr_total_times += data->wr_total_times; + total->rd_total_times += data->rd_total_times; + total->flush_total_times += data->flush_total_times; return 0; }