Re: [SeaBIOS] [PATCH] x86emu: Correctly handle 0x66 prefix for some instructions

2012-03-08 Thread Guillem Jover
On Thu, 2012-03-08 at 22:57:30 +, Julian Pidancet wrote: > On Wed, Mar 7, 2012 at 7:04 PM, Guillem Jover wrote: > > On Wed, 2012-03-07 at 17:54:57 +, Julian Pidancet wrote: > > > So according to the manual, it should be BP, not EBP. > > > > The register being decreased should match the one

[SeaBIOS] [PATCH] x86emu: Correctly handle 0x66 prefix for some instructions

2012-03-08 Thread Julian Pidancet
Some instructions are not emulated correctly by x86emu when they are prefixed by the 0x66 opcode. I've identified problems in the emulation of these intructions: ret, enter, leave, iret and some forms of call. Most of the time, the problem is that these instructions should push or pop 32-bit value

Re: [SeaBIOS] [PATCH] x86emu: Correctly handle 0x66 prefix for some instructions

2012-03-08 Thread Julian Pidancet
On Wed, Mar 7, 2012 at 7:04 PM, Guillem Jover wrote: > On Wed, 2012-03-07 at 17:54:57 +, Julian Pidancet wrote: >> So according to the manual, it should be BP, not EBP. > > The register being decreased should match the one being used to address > the stack, and the one to use depends on the de

Re: [SeaBIOS] [PATCH] x86emu: Correctly handle 0x66 prefix for some instructions

2012-03-07 Thread Guillem Jover
On Wed, 2012-03-07 at 17:54:57 +, Julian Pidancet wrote: > On Wed, Mar 7, 2012 at 1:46 PM, Guillem Jover wrote: > > On Mon, 2012-03-05 at 17:49:08 +, Julian Pidancet wrote: > >> diff --git a/hw/xfree86/x86emu/ops.c b/hw/xfree86/x86emu/ops.c > >> index 5d3cac1..440b8dc 100644 > >> --- a/hw/

Re: [SeaBIOS] [PATCH] x86emu: Correctly handle 0x66 prefix for some instructions

2012-03-07 Thread Guillem Jover
Hi! On Mon, 2012-03-05 at 17:49:08 +, Julian Pidancet wrote: > diff --git a/hw/xfree86/x86emu/ops.c b/hw/xfree86/x86emu/ops.c > index 5d3cac1..440b8dc 100644 > --- a/hw/xfree86/x86emu/ops.c > +++ b/hw/xfree86/x86emu/ops.c > @@ -8787,11 +8795,16 @@ static void x86emuOp_enter(u8 X86EMU_UNUSED(op

Re: [SeaBIOS] [PATCH] x86emu: Correctly handle 0x66 prefix for some instructions

2012-03-07 Thread Julian Pidancet
On Wed, Mar 7, 2012 at 7:04 PM, Guillem Jover wrote: > On Wed, 2012-03-07 at 17:54:57 +, Julian Pidancet wrote: >> On Wed, Mar 7, 2012 at 1:46 PM, Guillem Jover wrote: >> > On Mon, 2012-03-05 at 17:49:08 +, Julian Pidancet wrote: >> >> diff --git a/hw/xfree86/x86emu/ops.c b/hw/xfree86/x86

Re: [SeaBIOS] [PATCH] x86emu: Correctly handle 0x66 prefix for some instructions

2012-03-07 Thread Julian Pidancet
On Wed, Mar 7, 2012 at 1:46 PM, Guillem Jover wrote: > Hi! > > On Mon, 2012-03-05 at 17:49:08 +, Julian Pidancet wrote: >> diff --git a/hw/xfree86/x86emu/ops.c b/hw/xfree86/x86emu/ops.c >> index 5d3cac1..440b8dc 100644 >> --- a/hw/xfree86/x86emu/ops.c >> +++ b/hw/xfree86/x86emu/ops.c >> @@ -87

Re: [SeaBIOS] [PATCH] x86emu: Correctly handle 0x66 prefix for some instructions

2012-03-06 Thread Julian Pidancet
On 03/05/12 15:51, Peter Stuge wrote: > Julian Pidancet wrote: >> Sorry for the noise. None of these emails got through to the >> xorg-devel mailing list. Will retry later. > > I would appreciate if you looked at the coreboot x86emu as well. > > http://review.coreboot.org/gitweb?p=coreboot.git;a=

Re: [SeaBIOS] [PATCH] x86emu: Correctly handle 0x66 prefix for some instructions

2012-03-05 Thread Peter Stuge
Julian Pidancet wrote: > Sorry for the noise. None of these emails got through to the > xorg-devel mailing list. Will retry later. I would appreciate if you looked at the coreboot x86emu as well. http://review.coreboot.org/gitweb?p=coreboot.git;a=tree;f=src/devices/oprom/x86emu //Peter ___

Re: [SeaBIOS] [PATCH] x86emu: Correctly handle 0x66 prefix for some instructions

2012-03-05 Thread Julian Pidancet
Sorry for the noise. None of these emails got through to the xorg-devel mailing list. Will retry later. -- Julian ___ SeaBIOS mailing list SeaBIOS@seabios.org http://www.seabios.org/mailman/listinfo/seabios

[SeaBIOS] [PATCH] x86emu: Correctly handle 0x66 prefix for some instructions

2012-03-05 Thread Julian Pidancet
Some instructions are not emulated correctly by x86emu when they are prefixed by the 0x66 opcode. I've identified problems in the emulation of these intructions: ret, enter, leave, iret and some forms of call. Most of the time, the problem is that these instructions should push or pop 32-bit value