Re: Setting physical CPU for a task

Lluís Vilanova <[email protected]>
Newsgroups gmane.comp.micro-kernel.l4.devel
Message-ID <[email protected]>
Adam Lackorzynski writes:
[...]
>> Still, L4::Scheduler::info says there's as many CPUs as the maximum number
>> configured into Fiasco (not the number offered by QEMU). I'm just not sure if
>> this should be considered a bug or a feature.

> Fiasco does not know what the maximum number of CPUs on that particular
> machine will ever be, so it just says what it can support. Also, one has
> to wait a bit until all CPUs are up because Fiasco does not wait to
> start sigma0+moe until all CPUs are up (e.g. see migrate example).

Sorry, I just realized that what I misunderstood is the output of the migrate
example, not the description of L4::Scheduler::info:

  [...]
  static l4_umword_t         cpu_map, cpu_nrs;
  [...]
  static int check_cpus(void)
  {
    l4_sched_cpu_set_t cs = l4_sched_cpu_set(0, 0);

    if (l4_error(L4Re::Env::env()->scheduler()->info(&cpu_nrs, &cs)) < 0)
      return 1;

    cpu_map = cs.map;

    printf("Found %ld CPUs.\n", cpu_nrs);
  [...]

Maybe changing it to "Supports up to %ld CPUs" would be clearer, or instead (or
in addition) calculating the number of detected/online CPUs.


Thanks,
  Lluis

-- 
 "And it's much the same thing with knowledge, for whenever you learn
 something new, the whole world becomes that much richer."
 -- The Princess of Pure Reason, as told by Norton Juster in The Phantom
 Tollbooth
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.