lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <4E718567.9080702@cn.fujitsu.com>
Date:	Thu, 15 Sep 2011 12:56:07 +0800
From:	Xiao Guangrong <xiaoguangrong@...fujitsu.com>
To:	Avi Kivity <avi@...hat.com>
CC:	Marcelo Tosatti <mtosatti@...hat.com>,
	LKML <linux-kernel@...r.kernel.org>, KVM <kvm@...r.kernel.org>
Subject: Re: [PATCH v3 03/11] KVM: x86: retry non-page-table writing instruction

On 09/14/2011 06:19 PM, Xiao Guangrong wrote:
> On 09/14/2011 05:53 PM, Avi Kivity wrote:
>> On 09/13/2011 09:24 PM, Xiao Guangrong wrote:
>>>>>
>>>>>  +static bool retry_instruction(struct x86_emulate_ctxt *ctxt,
>>>>>  +                  unsigned long cr2,  int emulation_type)
>>>>>  +{
>>>>>  +    if (!vcpu->arch.mmu.direct_map&&   !mmu_is_nested(vcpu))
>>>>>  +        gpa = kvm_mmu_gva_to_gpa_write(vcpu, cr2, NULL);
>>>>
>>>>  If mmu_is_nested() cr2 is an ngpa, we have to translate it to a gpa, no?
>>>>
>>>
>>> Yeah, will fix it.
>>>
>>> And this bug also exists in the current code: it always uses L2 gpa to emulate
>>> write operation.
>>
>> Can you please send this fix separately, so it can be backported if needed?
>>
> 
> Sure, i will do it as soon as possible. :-)

I am so sorry, the current code is good, it has already translated L2 gpa to
L1 gpa:

vcpu->arch.nested_mmu.translate_gpa = translate_nested_gpa;

Please ignore it.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ