qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Laszlo Ersek <lersek@redhat.com>
To: Jordan Justen <jljusten@gmail.com>
Cc: Jordan Justen <jordan.l.justen@intel.com>,
	Kevin O'Connor <kevin@koconnor.net>,
	David Woodhouse <dwmw2@infradead.org>,
	qemu-devel <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] [PATCH v7 1/4] isapc: Fix non-KVM qemu boot (read/write memory for isapc BIOS)
Date: Fri, 31 May 2013 14:40:09 +0200	[thread overview]
Message-ID: <51A89A29.4090004@redhat.com> (raw)
In-Reply-To: <CAFe8ug_pZE+t0wwpnKWW_QqkeTHTp1-U6OA=0NqvnQfcrUbXhA@mail.gmail.com>

On 05/31/13 06:41, Jordan Justen wrote:
> On Thu, May 30, 2013 at 7:06 PM, Kevin O'Connor <kevin@koconnor.net> wrote:
>> On Wed, May 29, 2013 at 01:27:24AM -0700, Jordan Justen wrote:
>>> The isapc machine with seabios currently requires the BIOS region
>>> to be read/write memory rather than read-only memory.
>>>
>>> KVM currently cannot support the BIOS as a ROM region, but qemu
>>> in non-KVM mode can. Based on this, isapc machine currently only
>>> works with KVM.
>>>
>>> To work-around this isapc issue, this change avoids marking the
>>> BIOS as readonly for isapc.
>>
>> How about changing the code to always make the ROM read/write (instead
>> of doing it only on isapc).  Currently, if the rom is marked as
>> read-only, then SeaBIOS makes it read/write as the first thing it
>> does.  So, making it read-only doesn't really serve any purpose.
> 
> Are you talking about PAM registers? I think these should only affect
> 0xe0000-0xfffff and 0xfffe000-0xffffffff. So, the PAM registers should
> only impact part of the potential ROM range.
> 
> Also, I think the PAM registers should default to ROM mode after reset
> and on power-on.

I think we've been here before...

- always resetting the PAM registers broke S3 resume:
http://thread.gmane.org/gmane.comp.emulators.qemu/195931/focus=195932
http://thread.gmane.org/gmane.comp.emulators.qemu/195931/focus=196081

- there was a patch to distinguish soft reset from hard reset:
http://thread.gmane.org/gmane.comp.emulators.qemu/195351

- another approach for soft vs. hard, and how it relates to resume:
http://thread.gmane.org/gmane.comp.emulators.qemu/198545/focus=198546

I believe currently qemu doesn't distinguish soft from hard reset. Hard
reset would have to reset PAM registers, soft reset must not. Since we
only have one (mixed?) kind, and S3 resume depends on PAM registers
being intact, we can't clear them during the one kind of reset that we
currently have.

No idea what the final resolution was, but I vaguely believe none of the
"distinguish soft from hard reset" submissions got all aspects right, or
some such.

Thanks,
Laszlo

  reply	other threads:[~2013-05-31 12:38 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-29  8:27 [Qemu-devel] [PATCH v7 0/4] KVM flash memory support Jordan Justen
2013-05-29  8:27 ` [Qemu-devel] [PATCH v7 1/4] isapc: Fix non-KVM qemu boot (read/write memory for isapc BIOS) Jordan Justen
2013-05-31  2:06   ` Kevin O'Connor
2013-05-31  4:41     ` Jordan Justen
2013-05-31 12:40       ` Laszlo Ersek [this message]
2013-05-31 12:48         ` Paolo Bonzini
2013-05-31 12:48     ` Paolo Bonzini
2013-06-01  3:44       ` Kevin O'Connor
2013-05-29  8:27 ` [Qemu-devel] [PATCH v7 2/4] kvm: add kvm_readonly_mem_enabled Jordan Justen
2013-05-29  8:27 ` [Qemu-devel] [PATCH v7 3/4] kvm: support using KVM_MEM_READONLY flag for regions Jordan Justen
2013-05-29  8:27 ` [Qemu-devel] [PATCH v7 4/4] pc_sysfw: allow flash (-pflash) memory to be used with KVM Jordan Justen
2013-05-31 18:48 ` [Qemu-devel] [PATCH v7 0/4] KVM flash memory support Anthony Liguori

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=51A89A29.4090004@redhat.com \
    --to=lersek@redhat.com \
    --cc=dwmw2@infradead.org \
    --cc=jljusten@gmail.com \
    --cc=jordan.l.justen@intel.com \
    --cc=kevin@koconnor.net \
    --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).