From patchwork Mon Nov 30 18:46:35 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "H.J. Lu" X-Patchwork-Id: 9848 Received: (qmail 99125 invoked by alias); 30 Nov 2015 18:46:41 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 99094 invoked by uid 89); 30 Nov 2015 18:46:40 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.7 required=5.0 tests=AWL, BAYES_00, FREEMAIL_FROM, SPF_SOFTFAIL autolearn=no version=3.3.2 X-HELO: mga03.intel.com X-ExtLoop1: 1 From: "H.J. Lu" To: libc-alpha@sourceware.org Subject: [PATCH] Use __syscall_ulong_t for __cpu_mask Date: Mon, 30 Nov 2015 10:46:35 -0800 Message-Id: <1448909195-12575-1-git-send-email-hjl.tools@gmail.com> Since x86-64 and x32 use the same set of sched_XXX system call interface: [hjl@gnu-6 linux-stable]$ grep sched_ arch/x86/entry/syscalls/syscall_64.tbl 24 common sched_yield sys_sched_yield 142 common sched_setparam sys_sched_setparam 143 common sched_getparam sys_sched_getparam 144 common sched_setscheduler sys_sched_setscheduler 145 common sched_getscheduler sys_sched_getscheduler 146 common sched_get_priority_max sys_sched_get_priority_max 147 common sched_get_priority_min sys_sched_get_priority_min 148 common sched_rr_get_interval sys_sched_rr_get_interval 203 common sched_setaffinity sys_sched_setaffinity 204 common sched_getaffinity sys_sched_getaffinity 314 common sched_setattr sys_sched_setattr 315 common sched_getattr sys_sched_getattr [hjl@gnu-6 linux-stable]$ __cpu_mask should be __syscall_ulong_t. [BZ #19313] * sysdeps/unix/sysv/linux/bits/sched.h (__cpu_mask): Replace unsigned long int with __syscall_ulong_t. --- sysdeps/unix/sysv/linux/bits/sched.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sysdeps/unix/sysv/linux/bits/sched.h b/sysdeps/unix/sysv/linux/bits/sched.h index ae089df..27d87c4 100644 --- a/sysdeps/unix/sysv/linux/bits/sched.h +++ b/sysdeps/unix/sysv/linux/bits/sched.h @@ -115,7 +115,7 @@ struct __sched_param # define __NCPUBITS (8 * sizeof (__cpu_mask)) /* Type for array elements in 'cpu_set_t'. */ -typedef unsigned long int __cpu_mask; +typedef __syscall_ulong_t __cpu_mask; /* Basic access functions. */ # define __CPUELT(cpu) ((cpu) / __NCPUBITS)