Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

selftests: mqueue: drop duplicate min definition

Drop duplicate macro min() definition in mq_perf_tests.c, use MIN() in
sys/param.h instead.

Signed-off-by: Geliang Tang <geliang.tang@suse.com>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>

authored by

Geliang Tang and committed by
Shuah Khan
abd26d34 d490527d

+2 -2
+2 -2
tools/testing/selftests/mqueue/mq_perf_tests.c
··· 35 35 #include <sys/time.h> 36 36 #include <sys/resource.h> 37 37 #include <sys/stat.h> 38 + #include <sys/param.h> 38 39 #include <mqueue.h> 39 40 #include <popt.h> 40 41 #include <error.h> ··· 74 73 char *MAX_MSGS = "/proc/sys/fs/mqueue/msg_max"; 75 74 char *MAX_MSGSIZE = "/proc/sys/fs/mqueue/msgsize_max"; 76 75 77 - #define min(a, b) ((a) < (b) ? (a) : (b)) 78 76 #define MAX_CPUS 64 79 77 char *cpu_option_string; 80 78 int cpus_to_pin[MAX_CPUS]; ··· 560 560 "require root in order to modify\nsystem settings. " 561 561 "Exiting.\n"); 562 562 563 - cpus_online = min(MAX_CPUS, sysconf(_SC_NPROCESSORS_ONLN)); 563 + cpus_online = MIN(MAX_CPUS, sysconf(_SC_NPROCESSORS_ONLN)); 564 564 cpu_set = CPU_ALLOC(cpus_online); 565 565 if (cpu_set == NULL) { 566 566 perror("CPU_ALLOC()");