From patchwork Mon Jan 29 23:58:43 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Samuel Thibault X-Patchwork-Id: 867362 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-89812-incoming=patchwork.ozlabs.org@sourceware.org; receiver=) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; secure) header.d=sourceware.org header.i=@sourceware.org header.b="oYq6ID1H"; 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 3zVmgz54fjz9s7F for ; Tue, 30 Jan 2018 10:59:11 +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:in-reply-to :references; q=dns; s=default; b=obb/c0WH2my+HBAboTC4pc4MwWq6Lhv oBp0xzaloxmas/WkOWa4GEG6I8C/0vR3v6V6GiYDp/sg0fqaLm7MvxwTFAvNuRz2 vcGp80m0kHTonpuHjLexW5E0bIAUPKUNovP7Wg/agyIqvystqXkdR+8PPJZHQB2t CCPKRvAKyOEU= 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:in-reply-to :references; s=default; bh=dTmTYNKbsHyLgRhPIDhFmxYJor0=; b=oYq6I D1Hw4trQsm0QxV0qEhFCPtHZBxDqxH0QOPFkrH4hZjEjOIsquWa1nvpWZlkJdQb3 P115yQWq2eSUwhjrmchY1nquFYwtIOUw2Nf20k5wGeXREHEttUVr+umqelaVkZmq lgPCEWpmzydGuCBqAHOKcKRUMSb6n1HlKpFBqc= Received: (qmail 21693 invoked by alias); 29 Jan 2018 23:58:50 -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 21595 invoked by uid 89); 29 Jan 2018 23:58:49 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-26.1 required=5.0 tests=BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, SPF_HELO_PASS, SPF_NEUTRAL autolearn=ham version=3.3.2 spammy=dtv, Abuse, our X-HELO: hera.aquilenet.fr From: Samuel Thibault To: libc-alpha@sourceware.org Cc: Samuel Thibault Subject: [hurd,commited 2/2] hurd: Add tlsdesc.sym Date: Tue, 30 Jan 2018 00:58:43 +0100 Message-Id: <20180129235843.7552-3-samuel.thibault@ens-lyon.org> In-Reply-To: <20180129235843.7552-1-samuel.thibault@ens-lyon.org> References: <20180129235843.7552-1-samuel.thibault@ens-lyon.org> * sysdeps/mach/hurd/i386/tlsdesc.sym: New file. --- ChangeLog | 1 + sysdeps/mach/hurd/i386/tlsdesc.sym | 19 +++++++++++++++++++ 2 files changed, 20 insertions(+) create mode 100644 sysdeps/mach/hurd/i386/tlsdesc.sym diff --git a/ChangeLog b/ChangeLog index a49103451c..80ad4c6b10 100644 --- a/ChangeLog +++ b/ChangeLog @@ -29,6 +29,7 @@ * bits/fcntl.h: Fix comment for FREAD and FWRITE. * sysdeps/mach/hurd/bits/fcntl.h: Likewise. * sysdeps/mach/hurd/hp-timing.h: New file. + * sysdeps/mach/hurd/i386/tlsdesc.sym: New file. 2018-01-29 Darius Rad diff --git a/sysdeps/mach/hurd/i386/tlsdesc.sym b/sysdeps/mach/hurd/i386/tlsdesc.sym new file mode 100644 index 0000000000..a358f7e325 --- /dev/null +++ b/sysdeps/mach/hurd/i386/tlsdesc.sym @@ -0,0 +1,19 @@ +#include +#include +#include +#include +#include + +-- + +-- We have to override sysdeps/i386/tlsdesc.sym to adapt to our libpthread. + +-- Abuse tls.h macros to derive offsets relative to the thread register. + +DTV_OFFSET offsetof(tcbhead_t, dtv) + +TLSDESC_ARG offsetof(struct tlsdesc, arg) + +TLSDESC_GEN_COUNT offsetof(struct tlsdesc_dynamic_arg, gen_count) +TLSDESC_MODID offsetof(struct tlsdesc_dynamic_arg, tlsinfo.ti_module) +TLSDESC_MODOFF offsetof(struct tlsdesc_dynamic_arg, tlsinfo.ti_offset)