public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Christian Borntraeger <borntraeger@de.ibm.com>
To: kvm-devel@lists.sourceforge.net
Cc: Marcelo Tosatti <marcelo@kvack.org>
Subject: Re: [PATCH] virtio-blk: allow more than one in-flight request
Date: Thu, 27 Mar 2008 18:45:14 +0100	[thread overview]
Message-ID: <200803271845.14059.borntraeger@de.ibm.com> (raw)
In-Reply-To: <20080327162948.GB8659@dmt>

Am Donnerstag, 27. März 2008 schrieb Marcelo Tosatti:
> 
> Allow more than one in-flight request in the virtio ring. This allows
> the host driver to submit requests in parallel.
[...]
> diff --git a/drivers/block/virtio_blk.c b/drivers/block/virtio_blk.c
> index 3b1a68d..5bb041f 100644
> --- a/drivers/block/virtio_blk.c
> +++ b/drivers/block/virtio_blk.c
[...]
> @@ -202,7 +204,8 @@ static int virtblk_probe(struct virtio_device *vdev)
>  		goto out_free_vblk;
>  	}
> 
> -	vblk->pool = mempool_create_kmalloc_pool(1,sizeof(struct virtblk_req));
> +	vblk->pool = mempool_create_kmalloc_pool(VIRTIO_BLK_POOL_SIZE,
> +                        sizeof(struct virtblk_req));
>  	if (!vblk->pool) {
>  		err = -ENOMEM;
>  		goto out_free_vq;
[...]

Huh? I dont understand. You only change the number of pre-allocated pool 
entries. mempool_alloc should allow several allocations, even with 1 as 
initialization value. The pre-initialized value is only for oom situations. 
No?

Christian

-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace

  reply	other threads:[~2008-03-27 17:45 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-27 16:29 [PATCH] virtio-blk: allow more than one in-flight request Marcelo Tosatti
2008-03-27 17:45 ` Christian Borntraeger [this message]
2008-03-27 20:30   ` Marcelo Tosatti
2008-03-27 23:22 ` Rusty Russell

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=200803271845.14059.borntraeger@de.ibm.com \
    --to=borntraeger@de.ibm.com \
    --cc=kvm-devel@lists.sourceforge.net \
    --cc=marcelo@kvack.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox