All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ting Shen <christieshum@gmail.com>
To: "Ke, Liping" <liping.ke@intel.com>
Cc: Xen-devel <xen-devel@lists.xensource.com>
Subject: Re: Re: need help about CPU offline/hotplug in Xen Unstable
Date: Wed, 13 May 2009 13:40:51 +0800	[thread overview]
Message-ID: <765824370905122240w12ead828n94352c2e2cea17c0@mail.gmail.com> (raw)
In-Reply-To: <E2263E4A5B2284449EEBD0AAB751098402C4E34470@PDSMSX501.ccr.corp.intel.com>


[-- Attachment #1.1: Type: text/plain, Size: 1732 bytes --]

Yes, It works well. Thank you very much indeed!

2009/5/13 Ke, Liping <liping.ke@intel.com>

>  please try below test code piece. Hope it could help you.
>
> Thanks& Regards,
> Criping
>
> #include <stdio.h>
> #include <stdlib.h>
>
> #include <xenctrl.h>
>
> int main(int argc, char *argv[] )
> {
>     int cpu, xc_id;
>     if ( argc < 2) {
>         printf("Please input offline CPU-id\n");
>         exit(0);
>     }
>     cpu = atoi(argv[1]);
>     printf("Offline CPU %d\n", cpu);
>     xc_id = xc_interface_open();
>     xc_cpu_offline(xc_id, cpu);
>     printf("CPU offlined\n");
>     xc_interface_close(xc_id);
>     return 0;
> }
>
>  ------------------------------
> *From:* xen-devel-bounces@lists.xensource.com [mailto:
> xen-devel-bounces@lists.xensource.com] *On Behalf Of *
> ChristieShum@gmail.com
> *Sent:* 2009年5月13日 12:30
> *To:* Xen-devel
> *Subject:* Re: Re: [Xen-devel] need help about CPU offline/hotplug in Xen
> Unstable
>
> Thanks a lot.
> Is there a sample or tutorial for how to implement the offline process
> using this library?
>
> On May 12, 2009 11:02pm, Keir Fraser <keir.fraser@eu.citrix.com> wrote:
> > On 12/05/2009 15:47, "Ting Shen" christieshum@gmail.com> wrote:
> >
> >
> >
> > > Then I downloaded the stable version from xen.org http://xen.org>  and
> >
> > > installed.
> >
> > > But since the document is not updated, I don't know the detail method
> to
> >
> > > offline a physical CPU.
> >
> >
> >
> > It's available as a library function (xc_cpu_offline) but not actually
> >
> > plumbed into a xm command, or other tool.
> >
> >
> >
> >  -- Keir
> >
> >
> >
> >
> >
>



-- 
Yours Sincerely,
Ting Shen

[-- Attachment #1.2: Type: text/html, Size: 3970 bytes --]

[-- Attachment #2: Type: text/plain, Size: 138 bytes --]

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel

      reply	other threads:[~2009-05-13  5:40 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-12 14:47 need help about CPU offline/hotplug in Xen Unstable Ting Shen
2009-05-12 15:02 ` Keir Fraser
2009-05-13  2:01   ` Jiang, Yunhong
2009-05-13  4:29   ` ChristieShum
2009-05-13  4:55     ` Ke, Liping
2009-05-13  5:40       ` Ting Shen [this message]

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=765824370905122240w12ead828n94352c2e2cea17c0@mail.gmail.com \
    --to=christieshum@gmail.com \
    --cc=liping.ke@intel.com \
    --cc=xen-devel@lists.xensource.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.