From: Avi Kivity <avi@redhat.com>
To: Gleb Natapov <gleb@redhat.com>
Cc: mtosatti@redhat.com, kvm@vger.kernel.org
Subject: Re: [PATCH] KVM: mark segments accessed on HW task switch
Date: Mon, 25 Jan 2010 14:53:09 +0200 [thread overview]
Message-ID: <4B5D9435.2010707@redhat.com> (raw)
In-Reply-To: <20100125122419.GB8483@redhat.com>
On 01/25/2010 02:24 PM, Gleb Natapov wrote:
> On Mon, Jan 25, 2010 at 01:12:36PM +0200, Avi Kivity wrote:
>
>> On 01/25/2010 01:11 PM, Gleb Natapov wrote:
>>
>>> On Mon, Jan 25, 2010 at 01:08:13PM +0200, Avi Kivity wrote:
>>>
>>>> On 01/25/2010 12:01 PM, Gleb Natapov wrote:
>>>>
>>>>> On HW task switch newly loaded segments should me marked as accessed.
>>>>>
>>>>> @@ -4775,6 +4766,11 @@ int kvm_load_segment_descriptor(struct kvm_vcpu *vcpu, u16 selector,
>>>>> kvm_seg.unusable = 1;
>>>>>
>>>>> kvm_set_segment(vcpu,&kvm_seg, seg);
>>>>> + if (selector&& !kvm_seg.unusable&& kvm_seg.s) {
>>>>> + /* mark segment as accessed */
>>>>> + seg_desc.type |= 1;
>>>>> + save_guest_segment_descriptor(vcpu, selector,&seg_desc);
>>>>> + }
>>>>> return 0;
>>>>> }
>>>>>
>>>> What about an error return from s_g_s_d?
>>>>
>>>>
>>> What can or should we do about it?
>>>
>>>
>> If -EFAULT, propagate to userspace.
>>
>>
> We don't handle it anywhere in task switch emulation. Separate patch?
>
>
Things like 'return kvm_write_guest_virt()' do handle it.
--
error compiling committee.c: too many arguments to function
next prev parent reply other threads:[~2010-01-25 12:53 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-25 10:01 [PATCH] KVM: mark segments accessed on HW task switch Gleb Natapov
2010-01-25 11:08 ` Avi Kivity
2010-01-25 11:11 ` Gleb Natapov
2010-01-25 11:12 ` Avi Kivity
2010-01-25 12:24 ` Gleb Natapov
2010-01-25 12:53 ` Avi Kivity [this message]
2010-01-25 14:22 ` Gleb Natapov
2010-01-25 14:52 ` Avi Kivity
2010-01-25 21:34 ` Marcelo Tosatti
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=4B5D9435.2010707@redhat.com \
--to=avi@redhat.com \
--cc=gleb@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=mtosatti@redhat.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.