From patchwork Sun Feb 9 16:37:08 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Samuel Thibault X-Patchwork-Id: 1235467 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=sourceware.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=libc-alpha-return-109291-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=ens-lyon.org Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.a=rsa-sha1 header.s=default header.b=mhFMvn1W; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 48FvpB0x0Vz9sP7 for ; Mon, 10 Feb 2020 03:37:21 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:date:message-id :mime-version:content-transfer-encoding; q=dns; s=default; b=uFU jey8tds34nrDXzFLE2Sw3fnVSoV+AXbJEeOZLda1ELhAM07sAJJAxh6zangA4V8p QE4TbxrN465W26S2PWKylMURkM8Gkx9bpZxIZ/0FzF3DQdGxpHXXmvZTpVMyPwnY s9hlW7g88frNx7FIRMjL6druargdQ2mp4iae9KBw= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:date:message-id :mime-version:content-transfer-encoding; s=default; bh=q8KkmLX1W R2GcnVp7oPaNR5OWrw=; b=mhFMvn1WTOM24e+qgjIe/bfyx6DcDY1IH5w+Y1gt+ jvojyIGpCojNyRgzSzTgnjCTv5ttFV6LK25tKkrjmxoxkNoCCrNqtf7unCx0fv+U cZ30YQxuzfHBx5gLm38c2S9Xc4LqoDUTPL9LmwWanMJpLysvfb2YKG4kGKrKfyhv IU= Received: (qmail 96395 invoked by alias); 9 Feb 2020 16:37:15 -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 96387 invoked by uid 89); 9 Feb 2020 16:37:15 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-22.0 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_NONE, SPF_HELO_PASS, SPF_NEUTRAL autolearn=ham version=3.3.1 spammy=HContent-Transfer-Encoding:8bit X-HELO: hera.aquilenet.fr From: Samuel Thibault To: libc-alpha@sourceware.org Cc: Samuel Thibault , commit-hurd@gnu.org Subject: [hurd, commited] htl: Do not put spin_lock inlines in public headers Date: Sun, 9 Feb 2020 17:37:08 +0100 Message-Id: <20200209163708.276453-1-samuel.thibault@ens-lyon.org> MIME-Version: 1.0 They were not getting used anyway. Also do not make libsupport use them, it would make tests using it have to be made to link against libmachuser for gsync_wait. --- sysdeps/htl/include/pthread.h | 36 +++++++++++++++++++++++++++++++++++ sysdeps/htl/pthread.h | 36 ----------------------------------- 2 files changed, 36 insertions(+), 36 deletions(-) create mode 100644 sysdeps/htl/include/pthread.h diff --git a/sysdeps/htl/include/pthread.h b/sysdeps/htl/include/pthread.h new file mode 100644 index 0000000000..173b1eb08d --- /dev/null +++ b/sysdeps/htl/include/pthread.h @@ -0,0 +1,36 @@ +#ifndef _PTHREAD_H +#include_next +#if defined __USE_EXTERN_INLINES && defined _LIBC && !IS_IN (libsupport) +# include + +__extern_inline int +pthread_spin_destroy (pthread_spinlock_t *__lock) +{ + return __pthread_spin_destroy (__lock); +} + +__extern_inline int +pthread_spin_init (pthread_spinlock_t *__lock, int __pshared) +{ + return __pthread_spin_init (__lock, __pshared); +} + +__extern_inline int +pthread_spin_lock (pthread_spinlock_t *__lock) +{ + return __pthread_spin_lock (__lock); +} + +__extern_inline int +pthread_spin_trylock (pthread_spinlock_t *__lock) +{ + return __pthread_spin_trylock (__lock); +} + +__extern_inline int +pthread_spin_unlock (pthread_spinlock_t *__lock) +{ + return __pthread_spin_unlock (__lock); +} +#endif +#endif diff --git a/sysdeps/htl/pthread.h b/sysdeps/htl/pthread.h index 38c61e8da3..17f82e7180 100644 --- a/sysdeps/htl/pthread.h +++ b/sysdeps/htl/pthread.h @@ -549,42 +549,6 @@ extern int pthread_spin_trylock (pthread_spinlock_t *__lock) extern int pthread_spin_unlock (pthread_spinlock_t *__lock) __nonnull ((1)); -# if defined __USE_EXTERN_INLINES && defined _LIBC - -# include - -__extern_inline int -pthread_spin_destroy (pthread_spinlock_t *__lock) -{ - return __pthread_spin_destroy (__lock); -} - -__extern_inline int -pthread_spin_init (pthread_spinlock_t *__lock, int __pshared) -{ - return __pthread_spin_init (__lock, __pshared); -} - -__extern_inline int -pthread_spin_lock (pthread_spinlock_t *__lock) -{ - return __pthread_spin_lock (__lock); -} - -__extern_inline int -pthread_spin_trylock (pthread_spinlock_t *__lock) -{ - return __pthread_spin_trylock (__lock); -} - -__extern_inline int -pthread_spin_unlock (pthread_spinlock_t *__lock) -{ - return __pthread_spin_unlock (__lock); -} - -# endif /* Use extern inlines. */ - #endif /* XPG6. */