From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NCeQQ-0002GP-0p for qemu-devel@nongnu.org; Mon, 23 Nov 2009 14:18:14 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NCeQL-0002Fx-Im for qemu-devel@nongnu.org; Mon, 23 Nov 2009 14:18:13 -0500 Received: from [199.232.76.173] (port=59215 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NCeQL-0002Fu-Fz for qemu-devel@nongnu.org; Mon, 23 Nov 2009 14:18:09 -0500 Received: from mx1.redhat.com ([209.132.183.28]:9374) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NCeQK-0001Uf-VS for qemu-devel@nongnu.org; Mon, 23 Nov 2009 14:18:09 -0500 Date: Mon, 23 Nov 2009 21:18:00 +0200 From: Gleb Natapov Subject: Re: [Qemu-devel] Re: POST failure (loop) with isapc and seabios Message-ID: <20091123191800.GA13854@redhat.com> References: <20091120225113.GD24539@morn.localdomain> <20091122123503.GH3193@redhat.com> <20091122151052.GK3193@redhat.com> <20091122153842.GA13491@morn.localdomain> <20091123111601.GH2999@redhat.com> <17CE86C19414401F869FD85A63BF1250@FSCPC> <20091123180759.GA10115@redhat.com> <2294BD1266BA4DA1A2A7D6F9B7AEF316@FSCPC> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <2294BD1266BA4DA1A2A7D6F9B7AEF316@FSCPC> List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Sebastian Herbszt Cc: Kevin O'Connor , qemu-devel@nongnu.org On Mon, Nov 23, 2009 at 08:12:32PM +0100, Sebastian Herbszt wrote: > Gleb Natapov wrote: > >On Mon, Nov 23, 2009 at 06:57:47PM +0100, Sebastian Herbszt wrote: > >>Gleb Natapov wrote: > >>>On Sun, Nov 22, 2009 at 10:38:42AM -0500, Kevin O'Connor wrote: > >>>>On Sun, Nov 22, 2009 at 05:10:53PM +0200, Gleb Natapov wrote: > >>>>> On Sun, Nov 22, 2009 at 04:07:56PM +0100, Sebastian Herbszt wrote: > >>>>> > Gleb Natapov wrote: > >>>>> > >May be make qemu to map it writable if isapc is specified. > >>>>> > > > I don't think keeping the segment writable after POST is > >>>>a good idea. > >>>>> > > Isn't it writable now after POST with pcipc? Why this is > >>>>not a good > >>>>> idea? > >>>> > >>>>SeaBIOS and bochs bios will make the f-segment readonly at the end of > >>>>post. See make_bios_readonly() in src/shadow.c. > >>>> > >>>I see SeaBIOS does this, but I don't see where bochs bios does this. > >> > >>bios_lock_shadow_ram() in rombio32.c. > >> > >This functions is called far from end of the post and it doesn't change > >mapping to be read only as far as I can see. > > Bochs bios only keeps the memory writable inside rombios32. bios_lock_shadow_ram() > clears the upper 4 bits (7:4) and then sets bit 4 to 1 making the value of the bit pair 5:4 > (pci register 0x59) 01 being read only. > Ah correct. I missed that read/write status is in bits 7:4 not 0:3. -- Gleb.