xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: "Jan Beulich" <JBeulich@suse.com>
To: Corneliu ZUZU <czuzu@bitdefender.com>,
	Jun Nakajima <jun.nakajima@intel.com>,
	Kevin Tian <kevin.tian@intel.com>
Cc: Andrew Cooper <andrew.cooper3@citrix.com>, xen-devel@lists.xen.org
Subject: Re: [PATCH v3 1/8] x86/vmx_update_guest_cr: minor optimization
Date: Fri, 08 Jul 2016 05:48:02 -0600	[thread overview]
Message-ID: <577FAF1302000078000FC994@prv-mh.provo.novell.com> (raw)
In-Reply-To: <e4e39006-ae58-dc06-29ab-9ec647dda033@bitdefender.com>

>>> On 08.07.16 at 13:39, <czuzu@bitdefender.com> wrote:
> On 7/6/2016 6:49 PM, Corneliu ZUZU wrote:
>> Minor optimization @ vmx_update_guest_cr: checks if 
> v->arch.hvm_vmx.exec_control
>> was modified before actually calling vmx_update_cpu_exec_control(v).
>>
>> Signed-off-by: Corneliu ZUZU <czuzu@bitdefender.com>
>> ---
>> Changed since v2: <nothing>
>> ---
>>   xen/arch/x86/hvm/vmx/vmx.c | 5 ++++-
>>   1 file changed, 4 insertions(+), 1 deletion(-)
>>
>> diff --git a/xen/arch/x86/hvm/vmx/vmx.c b/xen/arch/x86/hvm/vmx/vmx.c
>> index df19579..8ab074f 100644
>> --- a/xen/arch/x86/hvm/vmx/vmx.c
>> +++ b/xen/arch/x86/hvm/vmx/vmx.c
>> @@ -1434,8 +1434,10 @@ static void vmx_update_guest_cr(struct vcpu *v, 
> unsigned int cr)
>>           if ( paging_mode_hap(v->domain) )
>>           {
>>               /* Manage GUEST_CR3 when CR0.PE=0. */
>> +            uint32_t old_ctls = v->arch.hvm_vmx.exec_control;
>>               uint32_t cr3_ctls = (CPU_BASED_CR3_LOAD_EXITING |
>>                                    CPU_BASED_CR3_STORE_EXITING);
>> +
>>               v->arch.hvm_vmx.exec_control &= ~cr3_ctls;
>>               if ( !hvm_paging_enabled(v) && !vmx_unrestricted_guest(v) )
>>                   v->arch.hvm_vmx.exec_control |= cr3_ctls;
>> @@ -1445,7 +1447,8 @@ static void vmx_update_guest_cr(struct vcpu *v, 
> unsigned int cr)
>>                    monitor_ctrlreg_bitmask(VM_EVENT_X86_CR3) )
>>                   v->arch.hvm_vmx.exec_control |= CPU_BASED_CR3_LOAD_EXITING;
>>   
>> -            vmx_update_cpu_exec_control(v);
>> +            if ( old_ctls != v->arch.hvm_vmx.exec_control )
>> +                vmx_update_cpu_exec_control(v);
>>           }
>>   
>>           if ( !nestedhvm_vcpu_in_guestmode(v) )
> 
> I'm wondering if you could ack this as well (if there's nothing wrong w/ 
> it) and push it to be done with it. :-)

Well, if you had pinged the patch at least once, I probably would.
I don't, however, recall having seen any such ping (only resends).

Jan


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

  reply	other threads:[~2016-07-08 11:48 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-06 15:49 [PATCH v3 0/8] x86/vm-event: Adjustments & fixes Corneliu ZUZU
2016-07-06 15:49 ` [PATCH v3 1/8] x86/vmx_update_guest_cr: minor optimization Corneliu ZUZU
2016-07-08 11:39   ` Corneliu ZUZU
2016-07-08 11:48     ` Jan Beulich [this message]
2016-07-08 11:55       ` Corneliu ZUZU
2016-07-08 12:11         ` Jan Beulich
2016-07-08 12:18   ` Ping: " Corneliu ZUZU
2016-07-11  2:37   ` Tian, Kevin
2016-07-06 15:50 ` [PATCH v3 2/8] x86/vm-event/monitor: relocate code-motion more appropriately Corneliu ZUZU
2016-07-08  7:21   ` Jan Beulich
2016-07-08 10:22     ` Corneliu ZUZU
2016-07-08 10:37       ` Jan Beulich
2016-07-08 11:33         ` Corneliu ZUZU
2016-07-08 11:53           ` Jan Beulich
2016-07-08 11:57             ` Corneliu ZUZU
2016-07-08 15:50   ` Tamas K Lengyel
2016-07-08 17:58     ` Corneliu ZUZU
2016-07-11  2:52   ` Tian, Kevin
2016-07-06 15:51 ` [PATCH v3 3/8] x86/vm-event/monitor: don't compromise monitor_write_data on domain cleanup Corneliu ZUZU
2016-07-08  7:35   ` Jan Beulich
2016-07-08 10:28     ` Corneliu ZUZU
2016-07-08 10:38       ` Jan Beulich
2016-07-06 15:52 ` [PATCH v3 4/8] x86/vm_event/monitor/cr: check for vm-event subscriber on domctl Corneliu ZUZU
2016-07-06 16:01   ` Jan Beulich
2016-07-06 16:15     ` Corneliu ZUZU
2016-07-06 16:20       ` Corneliu ZUZU
2016-07-07  7:30       ` Jan Beulich
2016-07-07  7:53         ` Corneliu ZUZU
2016-07-07  8:18   ` Corneliu ZUZU
2016-07-06 15:53 ` [PATCH v3 5/8] x86/vm_event_resume: surround VM_EVENT_REASON_MOV_TO_MSR w/ CONFIG_X86 Corneliu ZUZU
2016-07-06 15:54 ` [PATCH v3 6/8] x86/vm-event: minor ASSERT fix, add 'unlikely' Corneliu ZUZU
2016-07-07  8:27   ` Jan Beulich
2016-07-07  8:35     ` Corneliu ZUZU
2016-07-07  8:53       ` Jan Beulich
2016-07-07 23:24   ` Tamas K Lengyel
2016-07-06 15:55 ` [PATCH v3 7/8] minor fixes (formatting, comments, unused includes etc.) Corneliu ZUZU
2016-07-08  7:56   ` Jan Beulich
2016-07-08 10:37     ` Corneliu ZUZU
2016-07-06 15:55 ` [PATCH v3 8/8] minor #include change Corneliu ZUZU

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=577FAF1302000078000FC994@prv-mh.provo.novell.com \
    --to=jbeulich@suse.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=czuzu@bitdefender.com \
    --cc=jun.nakajima@intel.com \
    --cc=kevin.tian@intel.com \
    --cc=xen-devel@lists.xen.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).