[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] switch vcpu on physical cpu



On Mon, Mar 3, 2014 at 8:10 PM, xennn <openbg@xxxxxx> wrote:
> hello all
>
> I would like to ask about switching vcpu-s on physcial one when we have
> paravirtualization.
>
> I think tha actual switching is happaning at switch_kernel_stack(struct vcpu
> *v) function in domain.c file.
>
>
> static inline void switch_kernel_stack(struct vcpu *v)
> {
>     struct tss_struct *tss = &this_cpu(init_tss);
>     tss->esp1 = v->arch.pv_vcpu.kernel_sp;
>     tss->ss1  = v->arch.pv_vcpu.kernel_ss;
> }
>
> Here the actual task switching is happen - the kernel stack of the current
> physical cpu is get by this_cpu()
> and afther that the kernel stack of that current task is changed to the
> vcpu's one.  So the task is swiched to the new vcpu state.
>
> Is that correct?
>
> I would like to ask what is tss_struct - task structure, task stack segment
> structure or something else?
Hi xennn,

I think TSS here is referring to "Task State Segment". It's an x86
specific feature [0]. If you would like an accurate description, you
can look at IA{32,64} Software Developers Manual [1]

[0] http://en.wikipedia.org/wiki/Task_State_Segment
[1] 
http://www.intel.com/content/www/us/en/processors/architectures-software-developer-manuals.html


>
> Best Regards
>
>
>
>
> --
> View this message in context: 
> http://xen.1045712.n5.nabble.com/switch-vcpu-on-physical-cpu-tp5721484.html
> Sent from the Xen - Dev mailing list archive at Nabble.com.
>
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@xxxxxxxxxxxxx
> http://lists.xen.org/xen-devel



-- 
Karim Allah Ahmed.

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


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.