All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jeremy Fitzhardinge <jeremy@goop.org>
To: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Cc: "xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>,
	Marek Marczykowski <marmarek@mimuw.edu.pl>
Subject: Re: blkfront problem in pvops kernel when barriers enabled
Date: Wed, 07 Sep 2011 11:58:38 -0700	[thread overview]
Message-ID: <4E67BEDE.6080301@goop.org> (raw)
In-Reply-To: <20110907174314.GM32190@dumpdata.com>

On 09/07/2011 10:43 AM, Konrad Rzeszutek Wilk wrote:
> On Wed, Sep 07, 2011 at 10:34:49AM -0700, Jeremy Fitzhardinge wrote:
>> On 09/06/2011 06:47 PM, Konrad Rzeszutek Wilk wrote:
>>> (on 3.1rc2) Looking to xenstore now there is 'feature-flush-cache=1' and
>>> no 'feature-barrier'. So it is ok.
>>> <scratches head>
>>>
>>> I can only think of 2.6.38-3 XenOLinux doing it - and it is a bug
>>> to do it. It really ought to _not_ advertise 'feature-barrier' and
>>> instead advertise 'feature-flush-cache'.
>> Does that mean that older guests which don't understand flush-cache will
>> be left with no way to force writes to stable storage?  Seems to me that
> Correct.
>> even if the backend would prefer flush-cache, it should also advertise
>> barriers.
> But doing it incorrectly is bad - really bad.

Well, there's "bad performance" and "bad oops we lost data".  If the
backend emulates a barrier by doing a drain, flush, write, drain, flush
then I think that should be safe, but definitely not quick.

>> However, that raises the question of how to express the preferred
>> mechanism if multiple are available.  You could assume that flush-cache
>> is always preferred if available, but that's pretty clunky.
> That is how I did it in the frontend.

OK, how about this for a cheapo idea: make the
feature-barrier/flush-cache files contain a priority: 0 = "do not use",
non-zero = bigger the better?  That way we can have barrier-preferring
backends also support flush.  I suppose.

Really, frontends should also try to make do with whatever the backend
supports, even if its not preferred as well.

    J

  reply	other threads:[~2011-09-07 18:58 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-04 10:49 blkfront problem in pvops kernel when barriers enabled Marek Marczykowski
2011-09-06 16:32 ` Konrad Rzeszutek Wilk
2011-09-06 16:55   ` Konrad Rzeszutek Wilk
2011-09-06 17:47     ` Marek Marczykowski
2011-09-06 17:16   ` Marek Marczykowski
2011-09-07  1:47     ` Konrad Rzeszutek Wilk
2011-09-07  9:50       ` Jan Beulich
2011-09-07 10:19         ` Jan Beulich
2011-09-07 17:41           ` Konrad Rzeszutek Wilk
2011-09-08  8:06             ` Jan Beulich
2011-09-08 13:11               ` Konrad Rzeszutek Wilk
2011-09-07 17:34       ` Jeremy Fitzhardinge
2011-09-07 17:43         ` Konrad Rzeszutek Wilk
2011-09-07 18:58           ` Jeremy Fitzhardinge [this message]
2011-09-07 19:31             ` Konrad Rzeszutek Wilk
2011-12-01 19:08     ` 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=4E67BEDE.6080301@goop.org \
    --to=jeremy@goop.org \
    --cc=konrad.wilk@oracle.com \
    --cc=marmarek@mimuw.edu.pl \
    --cc=xen-devel@lists.xensource.com \
    /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.