From: "Jan Beulich" <JBeulich@suse.com>
To: "Konrad Rzeszutek Wilk" <konrad.wilk@oracle.com>
Cc: "Konrad Rzeszutek Wilk" <konrad@kernel.org>,
"xen-devel" <xen-devel@lists.xen.org>,
<linux-kernel@vger.kernel.org>, <stable@vger.kernel.org>
Subject: Re: [Xen-devel] [PATCH 3/3] xen/blkback: Check for insane amounts of request on the ring.
Date: Mon, 28 Jan 2013 16:18:59 +0000 [thread overview]
Message-ID: <5106B30302000078000BA2A2@nat28.tlf.novell.com> (raw)
In-Reply-To: <20130128154231.GF4838@konrad-lan.dumpdata.com>
>>> On 28.01.13 at 16:42, Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> wrote:
> On Mon, Jan 28, 2013 at 11:07:46AM +0000, Jan Beulich wrote:
>> >>> On 25.01.13 at 19:43, Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> wrote:
>> > @@ -764,6 +768,9 @@ __do_block_io_op(struct xen_blkif *blkif)
>> > rp = blk_rings->common.sring->req_prod;
>> > rmb(); /* Ensure we see queued requests up to 'rp'. */
>> >
>> > + if (RING_REQUEST_PROD_OVERFLOW(&blk_rings->common, rp, rc))
>> > + return -EACCES;
>>
>> Actually I wonder whether we need the new macro at all: It seems
>> to me that using RING_REQUEST_CONS_OVERFLOW(&blk_rings->common, rp)
>> here would achieve the same effect.
>
> But it would not. The RING_REQUEST_CONS_OVERFLOW only check that the
> non-shared ring entries (rsp_prod and rsp_prod_pvt) are less than
> the size of the ring (32). In other words - they check whether we want
> to process more requests as we still have a back-log of responses to
> deal with.
So did you not notice that here 'rp' (i.e. req_prod) is being passed,
not 'rc'?
Jan
next prev parent reply other threads:[~2013-01-28 16:19 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-25 17:32 [PATCH] block backend fixes for v3.8 (and stable) v1 Konrad Rzeszutek Wilk
2013-01-25 17:32 ` [PATCH 1/3] xen/blkback: Don't trust the handle from the frontend Konrad Rzeszutek Wilk
2013-01-28 11:09 ` [Xen-devel] " Jan Beulich
2013-01-25 17:32 ` [PATCH 2/3] xen/ring: Add a new macro to detect whether there is an overflow in requests and response Konrad Rzeszutek Wilk
2013-01-25 17:45 ` [Xen-devel] " Roger Pau Monné
2013-01-25 18:29 ` Konrad Rzeszutek Wilk
2013-01-25 18:41 ` Konrad Rzeszutek Wilk
2013-01-25 18:41 ` Konrad Rzeszutek Wilk
2013-01-25 17:32 ` [PATCH 3/3] xen/blkback: Check for insane amounts of request on the ring Konrad Rzeszutek Wilk
2013-01-25 18:43 ` Konrad Rzeszutek Wilk
2013-01-28 11:07 ` [Xen-devel] " Jan Beulich
2013-01-28 15:42 ` Konrad Rzeszutek Wilk
2013-01-28 16:18 ` Jan Beulich [this message]
2013-01-28 16:47 ` Konrad Rzeszutek Wilk
2013-01-28 11:38 ` David Vrabel
2013-01-28 15:44 ` Konrad Rzeszutek Wilk
2013-01-28 16:03 ` David Vrabel
2013-01-28 16:13 ` Konrad Rzeszutek Wilk
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=5106B30302000078000BA2A2@nat28.tlf.novell.com \
--to=jbeulich@suse.com \
--cc=konrad.wilk@oracle.com \
--cc=konrad@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=stable@vger.kernel.org \
--cc=xen-devel@lists.xen.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
all inboxes | Powered by JetHome®