Re: [Qemu-devel] [PATCH 4/4] pam: setup pc.bios

2017-04-11 Thread Paolo Bonzini
On 11/04/2017 09:42, Xu, Anthony wrote: >> I think this is wrong, the high copy should remain read-only or pflash >> stops working when you remove PAM. > > I tried to set pc.bios as read-only and isa.bios as read&write, > it doesn't work. render_memory_region doesn't honor readonly > field of al

Re: [Qemu-devel] [PATCH 4/4] pam: setup pc.bios

2017-04-10 Thread Xu, Anthony
> I think this is wrong, the high copy should remain read-only or pflash > stops working when you remove PAM. I tried to set pc.bios as read-only and isa.bios as read&write, it doesn't work. render_memory_region doesn't honor readonly field of alias MemoryRegion. Two FlatRanges created for pc.bi

Re: [Qemu-devel] [PATCH 4/4] pam: setup pc.bios

2017-04-08 Thread Paolo Bonzini
On 08/04/2017 08:45, Anthony Xu wrote: > -if (!isapc_ram_fw) { > -memory_region_set_readonly(bios, true); > +if (PC_MACHINE(current_machine)->pam) { > +/* if PAM is disabled, set it as readwrite */ > +if (!isapc_ram_fw) { > +memory_region_set_readonly(b