Received: from eggs.gnu.org ([2001:4830:134:3::10]:40635) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XPtrA-0004v1-Us for qemu-devel@nongnu.org; Fri, 05 Sep 2014 09:47:23 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XPtr4-0006bD-PS for qemu-devel@nongnu.org; Fri, 05 Sep 2014 09:47:16 -0400 Received: from lputeaux-656-01-25-125.w80-12.abo.wanadoo.fr ([80.12.84.125]:47113 helo=paradis.irqsave.net) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XPtr4-0006as-Iw for qemu-devel@nongnu.org; Fri, 05 Sep 2014 09:47:10 -0400 From: =?UTF-8?q?Beno=C3=AEt=20Canet?= Date: Fri, 5 Sep 2014 15:46:14 +0200 Message-Id: <1409924778-29424-1-git-send-email-benoit.canet@nodalink.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Subject: [Qemu-devel] [PATCH 0/4] Extract block accounting statistic code in it's own module List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: =?UTF-8?q?Beno=C3=AEt=20Canet?= With the need to add new statistics it's better to modularize asap the I/= O block accounting code. This series takes care of extracting this code and making it independant = of the BlockDriverState structure. Compile tested and basically runtime tested excepted for the xen_disk.c b= ackend. Best regards Beno=C3=AEt Beno=C3=AEt Canet (4): block: Extract the BlockAcctStats structure block: Extract the block accounting code block: rename BlockAcctType members to start with BLOCK_ instead of BDRV_ block: Make the block accounting functions operate on BlockAcctStats block.c | 37 ++++++++++----------------- block/Makefile.objs | 1 + block/accounting.c | 54 ++++++++++++++++++++++++++++++++++++= +++ block/qapi.c | 19 +++++++------- dma-helpers.c | 2 +- hw/block/nvme.c | 4 +-- hw/block/virtio-blk.c | 15 ++++++----- hw/block/xen_disk.c | 8 +++--- hw/ide/ahci.c | 7 +++--- hw/ide/atapi.c | 18 +++++++------ hw/ide/core.c | 24 ++++++++++-------- hw/ide/macio.c | 19 ++++++++------ hw/scsi/scsi-disk.c | 45 ++++++++++++++++++++------------- include/block/accounting.h | 57 ++++++++++++++++++++++++++++++++++++= ++++++ include/block/block.h | 20 +++------------ include/block/block_int.h | 6 ++--- include/hw/virtio/virtio-blk.h | 1 + include/sysemu/dma.h | 1 + 18 files changed, 225 insertions(+), 113 deletions(-) create mode 100644 block/accounting.c create mode 100644 include/block/accounting.h --=20 2.1.0