From: Xiao Guangrong <xiaoguangrong@linux.vnet.ibm.com>
To: Gleb Natapov <gleb@redhat.com>
Cc: Peter Maydell <peter.maydell@linaro.org>,
Anthony Liguori <aliguori@us.ibm.com>,
Juan Quintela <quintela@redhat.com>,
"Justen, Jordan L" <jordan.l.justen@intel.com>,
Patch Tracking <patches@linaro.org>,
qemu-devel <qemu-devel@nongnu.org>,
Markus Armbruster <armbru@redhat.com>,
Jordan Justen <jljusten@gmail.com>
Subject: Re: [Qemu-devel] Use of flash for x86 BIOS
Date: Mon, 08 Apr 2013 17:19:57 +0800 [thread overview]
Message-ID: <51628BBD.3010604@linux.vnet.ibm.com> (raw)
In-Reply-To: <20130408084311.GE17919@redhat.com>
On 04/08/2013 04:43 PM, Gleb Natapov wrote:
> On Mon, Apr 08, 2013 at 01:18:10AM -0700, Jordan Justen wrote:
>> On Sun, Apr 7, 2013 at 11:06 PM, Xiao Guangrong
>> <xiaoguangrong@linux.vnet.ibm.com> wrote:
>>> On 03/23/2013 03:09 AM, Jordan Justen wrote:
>>>
>>>> Admittedly, I've been completely ineffectual in resolving the kvm
>>>> portion. More recently I tried to make use of KVM_MEM_READONLY to
>>>> address this. I was able to get an VM exit on writes to flash, but not
>>>> able to get the memory region to convert to full device mode so VM
>>>> exits would occur on reads as well. I am once again stalled...
>>>
>>> Hi Jordan,
>>>
>>> What's memory region you want to get? I should admit that I do not
>>> have enough background of flash, could you please explain this
>>> requirement more detail?
>>
>> The flash memory requires two modes.
>>
>> Read/Execute mode:
>> * Initial state
>> * Writes will trap to QEMU, and may transition to Device mode based on
>> QEMU device emulation
>>
>> Device mode:
>> * Region is not executable
>> * All reads & writes will trap to QEMU
>> * May transition back to Read/Execute mode based on QEMU device emulation
>>
>> Using KVM_MEM_READONLY I was able to get Read/Execute mode to work,
>> but I was not able to get the memory region to transition to Device
>> mode. (I couldn't get reads to trap to QEMU.)
>>
> You need to drop memslot when you transition to Device mode.
Yes. After delete the memslot, you can intercept both write and read. ;)
prev parent reply other threads:[~2013-04-08 9:21 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-03-19 18:24 [Qemu-devel] [PATCH 0/2] Implement migration support for pflash_cfi01 Peter Maydell
2013-03-19 18:24 ` [Qemu-devel] [PATCH 1/2] pflash_cfi01: Drop unused 'bypass' field Peter Maydell
2013-03-19 18:24 ` [Qemu-devel] [PATCH 2/2] pflash_cfi01: Implement migration support Peter Maydell
2013-03-26 13:32 ` Peter Maydell
2013-03-21 7:45 ` [Qemu-devel] Use of flash for x86 BIOS (was: [PATCH 0/2] Implement migration support for pflash_cfi01) Markus Armbruster
2013-03-22 16:42 ` Peter Maydell
2013-03-22 18:51 ` [Qemu-devel] Use of flash for x86 BIOS Markus Armbruster
2013-03-22 19:09 ` [Qemu-devel] Use of flash for x86 BIOS (was: [PATCH 0/2] Implement migration support for pflash_cfi01) Jordan Justen
2013-03-22 19:48 ` [Qemu-devel] Use of flash for x86 BIOS Markus Armbruster
2013-04-03 13:48 ` Laszlo Ersek
2013-04-03 18:38 ` Jordan Justen
2013-04-12 15:33 ` Markus Armbruster
2013-04-08 6:06 ` Xiao Guangrong
2013-04-08 8:18 ` Jordan Justen
2013-04-08 8:43 ` Gleb Natapov
2013-04-08 9:19 ` Xiao Guangrong [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=51628BBD.3010604@linux.vnet.ibm.com \
--to=xiaoguangrong@linux.vnet.ibm.com \
--cc=aliguori@us.ibm.com \
--cc=armbru@redhat.com \
--cc=gleb@redhat.com \
--cc=jljusten@gmail.com \
--cc=jordan.l.justen@intel.com \
--cc=patches@linaro.org \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=quintela@redhat.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.