From patchwork Mon May 27 10:59:11 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Florian Weimer X-Patchwork-Id: 1105746 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=sourceware.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=libc-alpha-return-102273-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="kA7TqD4M"; 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 45CDWD5VhCz9s6w for ; Mon, 27 May 2019 20:59:20 +1000 (AEST) 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:subject:date:message-id:mime-version :content-type; q=dns; s=default; b=FRfDKYq6Kxx8nn5OG4ZUt7pN2GOTD 4lf4G8ip5fA2Fmwosua/V4KzLGuZPuU7ep90dVb/5QjnYTQzVx0OjOracRRrC4/9 P1Paa0KxXCodIbYys+ocUjWnTbwAUQYxkpOsBs+Gv1yrA332qNAM7987hFsNI3Nr /corV78YmSj8k0= 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:subject:date:message-id:mime-version :content-type; s=default; bh=W+zK76eWBoBOc0zyUcdJ0nWmtIw=; b=kA7 TqD4Md81eYiM3Nq5KdG2d7Y2Z0lUGLjLv/utb0/ZkpN3JiTxQioyU29Xk9IX3hTL gFd9eCL2kwjsS8HqS0gzJguuy7lfbdlCq1hWFQtLvtTMtbJZrvrhNTYq7Ox+auKd wkTK2qpxW6jqwiGsM5QHFRUTGvwxUVVLlomQ3xHo= Received: (qmail 18596 invoked by alias); 27 May 2019 10:59: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 18588 invoked by uid 89); 27 May 2019 10:59:15 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-18.9 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, SPF_HELO_PASS autolearn=ham version=3.3.1 spammy=H*r:sk:libc-al, HX-Languages-Length:953, H*F:D*redhat.com X-HELO: mx1.redhat.com From: Florian Weimer To: libc-alpha@sourceware.org Subject: [PATCH] nptl: Add comment to __pthread_get_minstack about external users Date: Mon, 27 May 2019 12:59:11 +0200 Message-ID: <87sgt0jh8g.fsf@oldenburg2.str.redhat.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) MIME-Version: 1.0 2019-05-27 Florian Weimer * nptl/nptl-init.c: Add comment. Reviewed-by: Carlos O'Donell diff --git a/nptl/nptl-init.c b/nptl/nptl-init.c index 2926558b91..73935f8be4 100644 --- a/nptl/nptl-init.c +++ b/nptl/nptl-init.c @@ -407,6 +407,14 @@ strong_alias (__pthread_initialize_minimal_internal, __pthread_initialize_minimal) +/* This function is internal (it has a GLIBC_PRIVATE) version, but it + is widely used (either via weak symbol, or dlsym) to obtain the + __static_tls_size value. This value is then used to adjust the + value of the stack size attribute, so that applications receive the + full requested stack size, not diminished by the TCB and static TLS + allocation on the stack. Once the TCB is separately allocated, + this function should be removed or renamed (if it is still + necessary at that point). */ size_t __pthread_get_minstack (const pthread_attr_t *attr) {