qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Stefan Hajnoczi <stefanha@gmail.com>
To: Christoph Hellwig <hch@lst.de>
Cc: Kevin Wolf <kwolf@redhat.com>,
	Anthony Liguori <aliguori@us.ibm.com>,
	qemu-devel <qemu-devel@nongnu.org>,
	Prerna Saxena <prerna@linux.vnet.ibm.com>
Subject: [Qemu-devel] Re: Write cache enable from guest at runtime
Date: Tue, 15 Mar 2011 11:21:28 +0000	[thread overview]
Message-ID: <AANLkTimfCpJB2CUE8hac7pcE3Ny_mtDj+b-RwtoEn1va@mail.gmail.com> (raw)
In-Reply-To: <20110315105040.GA25001@lst.de>

On Tue, Mar 15, 2011 at 10:50 AM, Christoph Hellwig <hch@lst.de> wrote:
> On Mon, Mar 14, 2011 at 07:15:14PM +0000, Stefan Hajnoczi wrote:
>> Sounds like a good idea.  Feel free to post the patches RFC and I or
>> someone else can debug and polish them if you don't have time.
>
> By looking at your document and doing what you recommend against I think I
> got a much simpler solution than what I had before.
>
> I didn't know we could actually write to the config space.  The vpcu
> synchronous behaviour is not a problem as it's done seldomly, and we
> can trivially check against errors by reading the value back.
>
> I've just started building this variant, and it seems surprisingly simple.

I didn't think about the just reading the value back.

What do you think about reopening the file via /proc/$pid/fd/$old_fd?
I wrote a test and had a look at the proc fd code.  It seems to work
fine and doesn't require an O_SYNC runtime change kernel patch.  It
allows us to fall back to the old fd if the new file cannot be opened
and it works even when the old file has been deleted.

Stefan

      reply	other threads:[~2011-03-15 11:21 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-14 17:07 [Qemu-devel] Write cache enable from guest at runtime Stefan Hajnoczi
2011-03-14 17:16 ` [Qemu-devel] " Christoph Hellwig
2011-03-14 19:15   ` Stefan Hajnoczi
2011-03-15 10:50     ` Christoph Hellwig
2011-03-15 11:21       ` Stefan Hajnoczi [this message]

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=AANLkTimfCpJB2CUE8hac7pcE3Ny_mtDj+b-RwtoEn1va@mail.gmail.com \
    --to=stefanha@gmail.com \
    --cc=aliguori@us.ibm.com \
    --cc=hch@lst.de \
    --cc=kwolf@redhat.com \
    --cc=prerna@linux.vnet.ibm.com \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).