From patchwork Mon Mar 8 18:53:17 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alejandro Colomar X-Patchwork-Id: 1449341 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=8.43.85.97; helo=sourceware.org; envelope-from=libc-alpha-bounces@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.a=rsa-sha256 header.s=default header.b=pfqhzr3i; dkim-atps=neutral Received: from sourceware.org (unknown [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4DvSFJ75Phz9sW1 for ; Tue, 9 Mar 2021 05:54:44 +1100 (AEDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id DB7913954465; Mon, 8 Mar 2021 18:54:18 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org DB7913954465 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1615229658; bh=nFKK1l8gpea2/DnMclV57Wvza91ywL1DWxNoQGa9Z+s=; h=To:Subject:Date:In-Reply-To:References:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc: From; b=pfqhzr3iO4lekA829hLb9Rc+wR4kLjJROoeZeL/Hvh9rrnbINwIxH366mubyOzTM6 oTxi+Su481FHYYa2WeOrlKXFpeVHtuJmlKIlXE8FvEKdMjHeg/tZiqI8JlqMW8UULc 0YLm0MErzV5s1ARs4p3f0BG32BRIxK8rTU6wFzFQ= X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-wm1-x336.google.com (mail-wm1-x336.google.com [IPv6:2a00:1450:4864:20::336]) by sourceware.org (Postfix) with ESMTPS id 985583951402 for ; Mon, 8 Mar 2021 18:54:15 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 985583951402 Received: by mail-wm1-x336.google.com with SMTP id b2-20020a7bc2420000b029010be1081172so4445503wmj.1 for ; Mon, 08 Mar 2021 10:54:15 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=nFKK1l8gpea2/DnMclV57Wvza91ywL1DWxNoQGa9Z+s=; b=chVrIoMc2ZixtkEzbG/wfNhxJZ5odEDmGG7WJzwwUHgk8PbWbs2M8nGh6n8/BxW3T0 Ar3cyB6IC6nB5eS4KcwRVbOsy9U6jxTNdQm3XIDfPQTNvAcTpQ7Z166/zSuXABLqR7K9 uO5V0RtL96Q8YOrM/Wxm38uoKIz9XYPwdHYNLMHFXEjb4rDq+JLL0KaQQj8qW7IfXV6t 8L6J6yWbvlDtFVnP2PY9fUTbrZSHY37Okn5c5GgmrkS12JbcfN/4DuRdUT98r26MTNsL KJ5qDwQAKYBAqTS81JmMp8TOJRS4z6pnPb5GFdugirIxGa8MsrkBm3Jxgt7ol6t/ZXtz ALWw== X-Gm-Message-State: AOAM533mCscATE1X91CAzmuX0wvNj2KEj2GQdeobgBjWgsbp+2WiP0KT jXNuw8/hTX/lXS7K3tcUX1Y= X-Google-Smtp-Source: ABdhPJzthSthRA8EFlzy5rLpUsEapekOxeHxTv8me61jzHMOw7tSJaOgEBC7WarGGa9Nmx7+dkOJhw== X-Received: by 2002:a05:600c:2145:: with SMTP id v5mr193593wml.65.1615229654827; Mon, 08 Mar 2021 10:54:14 -0800 (PST) Received: from sqli.sqli.com ([195.53.121.100]) by smtp.googlemail.com with ESMTPSA id i11sm19889921wro.53.2021.03.08.10.54.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Mar 2021 10:54:14 -0800 (PST) To: mtk.manpages@gmail.com Subject: [PATCH 08/23] pthread_mutexattr_getpshared.3: SYNOPSIS: Use 'restrict' in prototypes Date: Mon, 8 Mar 2021 19:53:17 +0100 Message-Id: <20210308185331.242176-9-alx.manpages@gmail.com> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20210308185331.242176-1-alx.manpages@gmail.com> References: <20210308185331.242176-1-alx.manpages@gmail.com> MIME-Version: 1.0 X-Spam-Status: No, score=-11.8 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, GIT_PATCH_0, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=ham autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Alejandro Colomar via Libc-alpha From: Alejandro Colomar Reply-To: Alejandro Colomar Cc: Alejandro Colomar , linux-man@vger.kernel.org, libc-alpha@sourceware.org Errors-To: libc-alpha-bounces@sourceware.org Sender: "Libc-alpha" Both POSIX and glibc use 'restrict' in pthread_mutexattr_getpshared(). Let's use it here too. .../glibc$ grep_glibc_prototype pthread_mutexattr_getpshared sysdeps/htl/pthread.h:368: extern int pthread_mutexattr_getpshared(const pthread_mutexattr_t *__restrict __attr, int *__restrict __pshared) __THROW __nonnull ((1, 2)); sysdeps/nptl/pthread.h:830: extern int pthread_mutexattr_getpshared (const pthread_mutexattr_t * __restrict __attr, int *__restrict __pshared) __THROW __nonnull ((1, 2)); .../glibc$ Signed-off-by: Alejandro Colomar --- man3/pthread_mutexattr_getpshared.3 | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/man3/pthread_mutexattr_getpshared.3 b/man3/pthread_mutexattr_getpshared.3 index 2fd48012e..0ae3c05ea 100644 --- a/man3/pthread_mutexattr_getpshared.3 +++ b/man3/pthread_mutexattr_getpshared.3 @@ -30,10 +30,11 @@ process-shared mutex attribute .nf .B #include .PP -.BI "int pthread_mutexattr_getpshared(const pthread_mutexattr_t *" attr , -.BI " int *" pshared ); +.BI "int pthread_mutexattr_getpshared(" +.BI " const pthread_mutexattr_t *restrict " attr , +.BI " int *restrict " pshared ); .BI "int pthread_mutexattr_setpshared(pthread_mutexattr_t *" attr , -.BI " int " pshared ); +.BI " int " pshared ); .fi .PP Compile and link with \fI\-pthread\fP.