All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kevin Wolf <kwolf@redhat.com>
To: qemu-block@nongnu.org
Cc: kwolf@redhat.com, mreitz@redhat.com, pbonzini@redhat.com,
	qemu-devel@nongnu.org
Subject: [Qemu-devel] [PATCH 3/9] block: Remove bdrv_aio_pdiscard()
Date: Thu, 20 Oct 2016 15:46:03 +0200	[thread overview]
Message-ID: <1476971169-31604-4-git-send-email-kwolf@redhat.com> (raw)
In-Reply-To: <1476971169-31604-1-git-send-email-kwolf@redhat.com>

It is unused now.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
---
 block/io.c            | 29 -----------------------------
 block/trace-events    |  1 -
 include/block/block.h |  3 ---
 3 files changed, 33 deletions(-)

diff --git a/block/io.c b/block/io.c
index b136c89..ff93ba1 100644
--- a/block/io.c
+++ b/block/io.c
@@ -2196,35 +2196,6 @@ BlockAIOCB *bdrv_aio_flush(BlockDriverState *bs,
     return &acb->common;
 }
 
-static void coroutine_fn bdrv_aio_pdiscard_co_entry(void *opaque)
-{
-    BlockAIOCBCoroutine *acb = opaque;
-    BlockDriverState *bs = acb->common.bs;
-
-    acb->req.error = bdrv_co_pdiscard(bs, acb->req.offset, acb->req.bytes);
-    bdrv_co_complete(acb);
-}
-
-BlockAIOCB *bdrv_aio_pdiscard(BlockDriverState *bs, int64_t offset, int count,
-                              BlockCompletionFunc *cb, void *opaque)
-{
-    Coroutine *co;
-    BlockAIOCBCoroutine *acb;
-
-    trace_bdrv_aio_pdiscard(bs, offset, count, opaque);
-
-    acb = qemu_aio_get(&bdrv_em_co_aiocb_info, bs, cb, opaque);
-    acb->need_bh = true;
-    acb->req.error = -EINPROGRESS;
-    acb->req.offset = offset;
-    acb->req.bytes = count;
-    co = qemu_coroutine_create(bdrv_aio_pdiscard_co_entry, acb);
-    qemu_coroutine_enter(co);
-
-    bdrv_co_maybe_schedule_bh(acb);
-    return &acb->common;
-}
-
 void *qemu_aio_get(const AIOCBInfo *aiocb_info, BlockDriverState *bs,
                    BlockCompletionFunc *cb, void *opaque)
 {
diff --git a/block/trace-events b/block/trace-events
index 05fa13c..aff8a96 100644
--- a/block/trace-events
+++ b/block/trace-events
@@ -9,7 +9,6 @@ blk_co_preadv(void *blk, void *bs, int64_t offset, unsigned int bytes, int flags
 blk_co_pwritev(void *blk, void *bs, int64_t offset, unsigned int bytes, int flags) "blk %p bs %p offset %"PRId64" bytes %u flags %x"
 
 # block/io.c
-bdrv_aio_pdiscard(void *bs, int64_t offset, int count, void *opaque) "bs %p offset %"PRId64" count %d opaque %p"
 bdrv_aio_flush(void *bs, void *opaque) "bs %p opaque %p"
 bdrv_aio_readv(void *bs, int64_t sector_num, int nb_sectors, void *opaque) "bs %p sector_num %"PRId64" nb_sectors %d opaque %p"
 bdrv_aio_writev(void *bs, int64_t sector_num, int nb_sectors, void *opaque) "bs %p sector_num %"PRId64" nb_sectors %d opaque %p"
diff --git a/include/block/block.h b/include/block/block.h
index 107c603..99a15a6 100644
--- a/include/block/block.h
+++ b/include/block/block.h
@@ -314,9 +314,6 @@ BlockAIOCB *bdrv_aio_writev(BdrvChild *child, int64_t sector_num,
                             BlockCompletionFunc *cb, void *opaque);
 BlockAIOCB *bdrv_aio_flush(BlockDriverState *bs,
                            BlockCompletionFunc *cb, void *opaque);
-BlockAIOCB *bdrv_aio_pdiscard(BlockDriverState *bs,
-                              int64_t offset, int count,
-                              BlockCompletionFunc *cb, void *opaque);
 void bdrv_aio_cancel(BlockAIOCB *acb);
 void bdrv_aio_cancel_async(BlockAIOCB *acb);
 
-- 
1.8.3.1

  parent reply	other threads:[~2016-10-20 13:46 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-20 13:46 [Qemu-devel] [PATCH 0/9] block-backend: Use coroutine for flush/discard/ioctl Kevin Wolf
2016-10-20 13:46 ` [Qemu-devel] [PATCH 1/9] block: Use blk_co_flush() for all BB level flushes Kevin Wolf
2016-10-20 16:13   ` Eric Blake
2016-10-20 13:46 ` [Qemu-devel] [PATCH 2/9] block: Use blk_co_pdiscard() for all BB level discard Kevin Wolf
2016-10-20 16:18   ` Eric Blake
2016-10-20 13:46 ` Kevin Wolf [this message]
2016-10-20 17:32   ` [Qemu-devel] [PATCH 3/9] block: Remove bdrv_aio_pdiscard() Eric Blake
2016-10-21 10:59     ` Kevin Wolf
2016-10-21 13:45       ` Eric Blake
2016-10-20 13:46 ` [Qemu-devel] [PATCH 4/9] block: Use blk_co_ioctl() for all BB level ioctls Kevin Wolf
2016-10-20 17:40   ` Eric Blake
2016-10-20 13:46 ` [Qemu-devel] [PATCH 5/9] raw-posix: Don't use bdrv_ioctl() Kevin Wolf
2016-10-20 17:45   ` Eric Blake
2016-10-20 13:46 ` [Qemu-devel] [PATCH 6/9] block: Remove bdrv_ioctl() Kevin Wolf
2016-10-20 17:47   ` Eric Blake
2016-10-20 13:46 ` [Qemu-devel] [PATCH 7/9] block: Introduce .bdrv_co_ioctl() driver callback Kevin Wolf
2016-10-20 17:51   ` Eric Blake
2016-10-20 13:46 ` [Qemu-devel] [PATCH 8/9] raw: Implement .bdrv_co_ioctl instead of .bdrv_aio_ioctl Kevin Wolf
2016-10-20 17:52   ` Eric Blake
2016-10-20 13:46 ` [Qemu-devel] [PATCH 9/9] block: Remove bdrv_aio_ioctl() Kevin Wolf
2016-10-20 17:53   ` Eric Blake
2016-10-20 14:37 ` [Qemu-devel] [PATCH 0/9] block-backend: Use coroutine for flush/discard/ioctl Paolo Bonzini
2016-10-20 15:20 ` no-reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1476971169-31604-4-git-send-email-kwolf@redhat.com \
    --to=kwolf@redhat.com \
    --cc=mreitz@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-block@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.