From 829b8498cc781f5ed8f7b9e16378f448b4d45213 Mon Sep 17 00:00:00 2001 From: Jan Beulich Date: Fri, 23 Aug 2013 15:01:53 +0200 Subject: un-alias cpumask_any() from cpumask_first() In order to achieve more symmetric distribution of certain things, cpumask_any() shouldn't always pick the first CPU (which frequently will end up being CPU0). To facilitate that, introduce a library-like function to obtain random numbers. The per-architecture function is supposed to return zero if no valid random number can be obtained (implying that if occasionally zero got produced as random number, it wouldn't be considered such). As fallback this uses the trivial algorithm from the C standard, extended to produce "unsigned int" results. Signed-off-by: Jan Beulich Acked-by: Keir Fraser Reviewed-by: George Dunlap --- xen/common/Makefile | 1 + 1 file changed, 1 insertion(+) (limited to 'xen/common/Makefile') diff --git a/xen/common/Makefile b/xen/common/Makefile index 0dc20506cc..5486140888 100644 --- a/xen/common/Makefile +++ b/xen/common/Makefile @@ -17,6 +17,7 @@ obj-y += multicall.o obj-y += notifier.o obj-y += page_alloc.o obj-y += preempt.o +obj-y += random.o obj-y += rangeset.o obj-y += sched_credit.o obj-y += sched_credit2.o -- cgit v1.2.3