From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH] Add realmode test for CALL FAR IMM instruction Date: Wed, 25 Aug 2010 09:50:47 +0300 Message-ID: <4C74BD47.5030101@redhat.com> References: <4C74B3ED.9060105@cn.fujitsu.com> <4C74B526.1040205@cn.fujitsu.com> Mime-Version: 1.0 Content-Type: text/plain; charset=GB2312 Content-Transfer-Encoding: 7bit Cc: Marcelo Tosatti , kvm@vger.kernel.org To: Wei Yongjun Return-path: Received: from mx1.redhat.com ([209.132.183.28]:57172 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752419Ab0HYGu5 (ORCPT ); Wed, 25 Aug 2010 02:50:57 -0400 In-Reply-To: <4C74B526.1040205@cn.fujitsu.com> Sender: kvm-owner@vger.kernel.org List-ID: On 08/25/2010 09:16 AM, Wei Yongjun wrote: > Signed-off-by: Wei Yongjun > --- > x86/realmode.c | 6 ++++++ > 1 files changed, 6 insertions(+), 0 deletions(-) > > diff --git a/x86/realmode.c b/x86/realmode.c > index a833829..2e12680 100644 > --- a/x86/realmode.c > +++ b/x86/realmode.c > @@ -437,6 +437,9 @@ void test_call(void) > "ret\n\t" > "2:\t"); > MK_INSN(call_far1, "lcallw *(%ebx)\n\t"); > + MK_INSN(call_far2, ".byte 0x9a\n\t" > + ".word retf\n\t" > + ".word 0x00\n\t"); Why .byte encoding? won't "lcallw $0, $retf" (or the other way round) work? -- I have a truly marvellous patch that fixes the bug which this signature is too narrow to contain.