xen: credit2: allocate runqueue data structure dynamically
Instead of keeping an NR_CPUS big array of csched2_runqueue_data
elements, directly inside the csched2_private structure, allocate
it dynamically.
This has two positive effects:
- reduces the size of csched2_private sensibly, which is
especially good in case there are more instance of Credit2
(in different cpupools), and is also good from the point
of view of fitting the struct into CPU caches;
- we can use nr_cpu_ids as array size, which may be sensibly
smaller than NR_CPUS
Signed-off-by: Dario Faggioli <dario.faggioli@citrix.com>
Acked-by: George Dunlap <george.dunlap@citrix.com>