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: <4CF3D06F.6010004@redhat.com>
Date:	Mon, 29 Nov 2010 18:10:23 +0200
From:	Avi Kivity <avi@...hat.com>
To:	Joerg Roedel <joerg.roedel@....com>
CC:	Marcelo Tosatti <mtosatti@...hat.com>, kvm@...r.kernel.org,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/3] KVM: X86: Introduce generic guest-mode representation

On 11/29/2010 05:38 PM, Joerg Roedel wrote:
> This patch introduces a generic representation of guest-mode
> fpr a vcpu. This currently only exists in the SVM code.
> Having this representation generic will help making the
> non-svm code aware of nesting when this is necessary.
>
>
>
> +static inline void kvm_vcpu_enter_gm(struct kvm_vcpu *vcpu)
> +{
> +	vcpu->arch.hflags |= HF_GUEST_MASK;
> +}

I don't like the name much - the "meat" is just two letters.  Please 
spell it out.  I guess we could do is_guest_mode() like we do 
is_long_mode().

> +
> +static inline bool kvm_vcpu_is_gm(struct kvm_vcpu *vcpu)
> +{
> +	return !!(vcpu->arch.hflags&  HF_GUEST_MASK);
> +}
> +

!! unneeded with bool.

Note we need to live migrate this bit, but that's outside the scope of 
this patchset.

-- 
error compiling committee.c: too many arguments to function

--
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