lkml.org 
[lkml]   [2012]   [Apr]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH RFC V6 0/11] Paravirtualized ticketlocks
    On 04/02/2012 03:21 PM, Raghavendra K T wrote:
    > On 04/01/2012 07:23 PM, Avi Kivity wrote:
    > > On 04/01/2012 04:48 PM, Raghavendra K T wrote:
    > >>>> I have patch something like below in mind to try:
    > diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c
    > index 5127668..3fa912a 100644
    > --- a/virt/kvm/kvm_main.c
    > +++ b/virt/kvm/kvm_main.c
    > @@ -1557,12 +1557,17 @@ void mark_page_dirty(struct kvm *kvm, gfn_t gfn)
    > mark_page_dirty_in_slot(kvm, memslot, gfn);
    > }
    >
    > +#define YIELD_THRESHOLD 2048
    > +static void kvm_vcpu_try_yield_to(struct kvm_vcpu *me);
    > /*
    > * The vCPU has executed a HLT instruction with in-kernel mode enabled.
    > */
    > void kvm_vcpu_block(struct kvm_vcpu *vcpu)
    > {
    [...]
    > + if (loop_count++ % YIELD_THRESHOLD)
    > + schedule();
    > + else
    > + kvm_vcpu_try_yield_to(vcpu);
    > }
    >
    > +static void kvm_vcpu_try_yield(struct kvm_vcpu *me)

    yes, it is kvm_vcpu_try_yield_to. had changed the name just before
    sending. sorry.



    \
     
     \ /
      Last update: 2012-04-02 14:19    [from the cache]
    ©2003-2014 Jasper Spaans. hosted at Digital Ocean