On Fri, May 12, 2017 at 09:16:31PM +0200, Paolo Bonzini wrote: > On 12/05/2017 20:55, Xu, Anthony wrote: > > If that's the case, QEMU/TCG should work with SeaBios even with ignoring > > A20. > > > > During SeaBios boot, there are >350 port 92 access, if we don't need to > > handle A20, > > we can make A20 configurable in Seabios, It may reduce SeaBios boot time. > > Yes, that's a good idea.
SeaBIOS defaults to enabling A20 and it's a rare beast that disables it. One could change x86.h:set_a20 and romlayout.S:transition32 to only issue the outb() if the inb() indicates a change is needed. That would likely eliminate half the accesses. I'd be surprised if it would impact the overall boot time though. SeaBIOS only touches the port on a cpu mode switch and I would have thought that was heavier than an IO port access. Maybe that is skewed on KVM though. -Kevin