From patchwork Sun Feb 9 20:20:10 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Florian Weimer X-Patchwork-Id: 37812 X-Patchwork-Delegate: carlos@redhat.com Received: (qmail 19710 invoked by alias); 9 Feb 2020 20:20:19 -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 19639 invoked by uid 89); 9 Feb 2020 20:20:18 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-18.8 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 spammy= X-HELO: us-smtp-delivery-1.mimecast.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581279615; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=yQ0aepBTtPGrjdFzoa5Yyq90rphAC8tBIeOWMxY4cQo=; b=eF3ss6DITSp/83GPuJiyFK3k0znXPnGjZz2hk6uc9dt536UAuV3E0sVB11Ffg/PIcYwQda VMSXp7bQFBTtAO6MQX6bl+wwXsB7ohhTCKLoSBNcJt4LGsusa8KEWOGwBDyqZb6YzjquQn HN3huXeiQvLYEXn/gUOZ6+eSGSAoies= From: Florian Weimer To: libc-alpha@sourceware.org Subject: [PATCH 08/26] Linux: sched_getaffinity syscall number is always available In-Reply-To: References: X-From-Line: 2b192006102b7d73fe50bb47dfffb35929eee64b Mon Sep 17 00:00:00 2001 Message-Id: <2b192006102b7d73fe50bb47dfffb35929eee64b.1581279333.git.fweimer@redhat.com> Date: Sun, 09 Feb 2020 21:20:10 +0100 User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Due to the built-in tables, __NR_sched_getaffinity is always defined. Reviewed-by: Adhemerval Zanella --- sysdeps/unix/sysv/linux/sched_getaffinity.c | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/sysdeps/unix/sysv/linux/sched_getaffinity.c b/sysdeps/unix/sysv/linux/sched_getaffinity.c index 6d79a41c34..325bfb29c1 100644 --- a/sysdeps/unix/sysv/linux/sched_getaffinity.c +++ b/sysdeps/unix/sysv/linux/sched_getaffinity.c @@ -24,11 +24,10 @@ #include -#ifdef __NR_sched_getaffinity -# if SHLIB_COMPAT (libc, GLIBC_2_3_3, GLIBC_2_3_4) +#if SHLIB_COMPAT (libc, GLIBC_2_3_3, GLIBC_2_3_4) extern int __sched_getaffinity_new (pid_t, size_t, cpu_set_t *); libc_hidden_proto (__sched_getaffinity_new) -# endif +#endif int __sched_getaffinity_new (pid_t pid, size_t cpusetsize, cpu_set_t *cpuset) @@ -48,7 +47,7 @@ versioned_symbol (libc, __sched_getaffinity_new, sched_getaffinity, GLIBC_2_3_4); -# if SHLIB_COMPAT (libc, GLIBC_2_3_3, GLIBC_2_3_4) +#if SHLIB_COMPAT (libc, GLIBC_2_3_3, GLIBC_2_3_4) libc_hidden_def (__sched_getaffinity_new) int @@ -59,7 +58,4 @@ __sched_getaffinity_old (pid_t pid, cpu_set_t *cpuset) return __sched_getaffinity_new (pid, 128, cpuset); } compat_symbol (libc, __sched_getaffinity_old, sched_getaffinity, GLIBC_2_3_3); -# endif -#else -# include #endif