qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] About cpu_set, CPU hotplug and related subjects
@ 2010-04-19 19:34 Lucas Meneghel Rodrigues
  2010-04-22  1:12 ` [Qemu-devel] " Kevin O'Connor
  0 siblings, 1 reply; 7+ messages in thread
From: Lucas Meneghel Rodrigues @ 2010-04-19 19:34 UTC (permalink / raw)
  To: KVM mailing list; +Cc: qemu mailing list

Hi folks, 

I've implemented a functional test for the cpu_set feature some time
ago. I was going through the patch queue and realized the patch needed
some respin, so I did it. I decided to try and see what is the state of
the feature, considering last time I tried it was not working
(segfaulting).

Now, with the latest qemu-kvm things are on a much better shape, cpu_set
is not giving me segfaults, and qemu monitor reports the new cpus added.

10:21:20 INFO | Adding 1 CPUs to guest
10:21:20 DEBUG| Sending monitor command: cpu_set 0 online
10:21:20 DEBUG| Sending monitor command: cpu_set 1 online
10:21:20 DEBUG| Sending monitor command: info cpus
10:21:20 DEBUG| Output of info cpus:
* CPU #0: pc=0xffffffff8102e23d thread_id=11035 
  CPU #1: pc=0x0000000000000000 thread_id=11065 

The address of the CPU #1 seems a little strange. The guest OS is
completely unaware of any changes to the number of CPUs though.

After doing some reading it seems to me that the reason why that is not
happening is because SeaBIOS still doesn't have code to support CPU hot
plugging as BochsBIOS did. I also looked after some documentation about
how that feature is supposed to work, and didn't find it. So, assuming
my understanding about the current status is correct:

1) Is anybody planning on adding the necessary support to SeaBIOS
anytime soon?
2) How the whole functionality is supposed to work? My mental model goes
like this:

* cpu_set [total number of CPUs you want the system to have] online
* Guest should notice new CPUS added to the system and they appear
under /sys/devices/system/cpu/cpu*, initially offlined
* The online status of each CPU is
in /sys/devices/system/cpu/cpu*/online, and onlining it is just a matter
of writing 1 to this file
* It is not possible to downgrade the number of CPUs of the system
during the lifetime of the VM process

Thanks for your attention,

Lucas

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2010-05-11  1:09 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-04-19 19:34 [Qemu-devel] About cpu_set, CPU hotplug and related subjects Lucas Meneghel Rodrigues
2010-04-22  1:12 ` [Qemu-devel] " Kevin O'Connor
2010-04-28  9:31   ` [Qemu-devel] Re: [SeaBIOS] " Jes Sorensen
2010-04-28 10:30     ` Gleb Natapov
2010-04-28 10:41       ` Jes Sorensen
2010-04-28 10:45         ` Gleb Natapov
2010-05-11  1:09           ` Carl-Daniel Hailfinger

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).