Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 5 Dec 2018 10:23:38 +0000 (UTC)
From:      Michal Meloun <mmel@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r341512 - head/libexec/rtld-elf/aarch64
Message-ID:  <201812051023.wB5ANc3O076756@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: mmel
Date: Wed Dec  5 10:23:38 2018
New Revision: 341512
URL: https://svnweb.freebsd.org/changeset/base/341512

Log:
  Implement arm64 version of __tls_get_addr().
  
  MFC after:	1 week

Modified:
  head/libexec/rtld-elf/aarch64/reloc.c

Modified: head/libexec/rtld-elf/aarch64/reloc.c
==============================================================================
--- head/libexec/rtld-elf/aarch64/reloc.c	Wed Dec  5 10:22:14 2018	(r341511)
+++ head/libexec/rtld-elf/aarch64/reloc.c	Wed Dec  5 10:23:38 2018	(r341512)
@@ -517,3 +517,15 @@ allocate_initial_tls(Obj_Entry *objs)
 
 	asm volatile("msr	tpidr_el0, %0" : : "r"(tp));
 }
+
+void *
+__tls_get_addr(tls_index* ti)
+{
+      char *p;
+      void *_tp;
+
+      __asm __volatile("mrs	%0, tpidr_el0"  : "=r" (_tp));
+      p = tls_get_addr_common((Elf_Addr **)(_tp), ti->ti_module, ti->ti_offset);
+
+      return (p);
+}



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201812051023.wB5ANc3O076756>