From patchwork Mon Nov 23 21:59:12 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alejandro Colomar X-Patchwork-Id: 1405166 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; dmarc=pass (p=none dis=none) header.from=sourceware.org 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=piD08CH/; dkim-atps=neutral Received: from sourceware.org (server2.sourceware.org [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 4Cg1K0414jz9s1l for ; Tue, 24 Nov 2020 08:59:32 +1100 (AEDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 853A4385802E; Mon, 23 Nov 2020 21:59:30 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 853A4385802E DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1606168770; bh=Y5Z9D18Lkdw2Ol19/dXuIh0/n8vjMe9yN4YqNultdEQ=; h=To:Subject:Date:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:Cc:From; b=piD08CH/CW1rWAH8RALxiySXnZfokuUTy04GqZRqvnSEJUNlUQjblGFoyXXT97hf+ PPEbUnl8ke64MU8a+Yp2s+mqdKSb9Bsia6Yru/KgwHufW54iAqFO2CxJNGHjdwnMUt epG3SLZ29SDObQqhUMFkRXBMjzFhikX2j4WscUHk= X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-wr1-x441.google.com (mail-wr1-x441.google.com [IPv6:2a00:1450:4864:20::441]) by sourceware.org (Postfix) with ESMTPS id 008CA3858009 for ; Mon, 23 Nov 2020 21:59:27 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 008CA3858009 Received: by mail-wr1-x441.google.com with SMTP id 23so20277650wrc.8 for ; Mon, 23 Nov 2020 13:59:27 -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:mime-version :content-transfer-encoding; bh=Y5Z9D18Lkdw2Ol19/dXuIh0/n8vjMe9yN4YqNultdEQ=; b=kQnaAU0EkiKVY5PrDV+y33h+auiz+Je54SYMVmh3K9dUOkHsJ9GYEVVXff87cWGRKy Toz+uuzEaAJNvYbfN9vNoa5XovHvzKlsiW9DpCPlvpS15sPtnoX4G0wGigEEvw9KUl5A PIuR0kiT3JF0ojxuXKqvDw+lGTDwuKBPrgk3hhcM1YOyWgfEukiu/XrpQeag+QND7jp2 NRia0LSjABdbtI9YPu09diRX7B6Iy4cyfzuGEBz5vneHbq8Ceux+YcIWY++euG7dkXMC 5rKOhnkFxy9OEV7lmJ3vwoqGb3it1B4SHNQLEsrfkweL1ixptaXk3ZtmAOUlIWqOAkaL zuTQ== X-Gm-Message-State: AOAM530DkNfXL27r9plHOL/HJ0aAntZk+mqXqTzMuiuRXTVSHmmpgqW0 yECSgYWu7p778Cl+ZOJNy81kWWkeCrjnSA== X-Google-Smtp-Source: ABdhPJz5kSg0NawLjjRQLOzhn1nPFaKA+a5mpQG2/y1Ykqq+XblUAk/MfyDwKHd1a8UFsf+oqovVtw== X-Received: by 2002:a5d:570d:: with SMTP id a13mr1743749wrv.193.1606168767112; Mon, 23 Nov 2020 13:59:27 -0800 (PST) Received: from localhost.localdomain ([170.253.51.130]) by smtp.gmail.com with ESMTPSA id t20sm1391451wmi.3.2020.11.23.13.59.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 23 Nov 2020 13:59:26 -0800 (PST) To: mtk.manpages@gmail.com Subject: [PATCH] set_tid_address.2: SYNOPSIS: Fix set_tid_address() return type Date: Mon, 23 Nov 2020 22:59:12 +0100 Message-Id: <20201123215911.7576-1-alx.manpages@gmail.com> X-Mailer: git-send-email 2.29.2 MIME-Version: 1.0 X-Spam-Status: No, score=-13.4 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, linux-kernel@vger.kernel.org Errors-To: libc-alpha-bounces@sourceware.org Sender: "Libc-alpha" The Linux kernel uses 'pid_t' instead of 'long' for the return type. As glibc provides no wrapper, use the same types the kernel uses. $ sed -n 34,36p man-pages/man2/set_tid_address.2 .PP .IR Note : There is no glibc wrapper for this system call; see NOTES. $ grep -rn 'SYSCALL_DEFINE.*set_tid_address' linux/ linux/kernel/fork.c:1632: SYSCALL_DEFINE1(set_tid_address, int __user *, tidptr) $ sed -n 1632,1638p linux/kernel/fork.c SYSCALL_DEFINE1(set_tid_address, int __user *, tidptr) { current->clear_child_tid = tidptr; return task_pid_vnr(current); } $ grep -rn 'task_pid_vnr(struct' linux/ linux/include/linux/sched.h:1374: static inline pid_t task_pid_vnr(struct task_struct *tsk) Signed-off-by: Alejandro Colomar --- man2/set_tid_address.2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/man2/set_tid_address.2 b/man2/set_tid_address.2 index 380efcdd8..b18b8efef 100644 --- a/man2/set_tid_address.2 +++ b/man2/set_tid_address.2 @@ -29,7 +29,7 @@ set_tid_address \- set pointer to thread ID .nf .B #include .PP -.BI "long set_tid_address(int *" tidptr ); +.BI "pid_t set_tid_address(int *" tidptr ); .fi .PP .IR Note :