dl-tls.h 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. /* Copyright (C) 2005-2017 Free Software Foundation, Inc.
  2. The GNU C Library is free software; you can redistribute it and/or
  3. modify it under the terms of the GNU Lesser General Public License as
  4. published by the Free Software Foundation; either version 2.1 of the
  5. License, or (at your option) any later version.
  6. The GNU C Library is distributed in the hope that it will be useful,
  7. but WITHOUT ANY WARRANTY; without even the implied warranty of
  8. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  9. Lesser General Public License for more details.
  10. You should have received a copy of the GNU Lesser General Public
  11. License along with the GNU C Library; if not, see
  12. <http://www.gnu.org/licenses/>. */
  13. #ifndef _AARCH64_DL_TLS_H
  14. #define _AARCH64_DL_TLS_H 1
  15. /* Type used to represent a TLS descriptor in the GOT. */
  16. struct tlsdesc
  17. {
  18. ptrdiff_t (*entry) (struct tlsdesc *);
  19. void *arg;
  20. };
  21. typedef struct dl_tls_index
  22. {
  23. unsigned long int ti_module;
  24. unsigned long int ti_offset;
  25. } tls_index;
  26. /* Type used as the argument in a TLS descriptor for a symbol that
  27. needs dynamic TLS offsets. */
  28. struct tlsdesc_dynamic_arg
  29. {
  30. tls_index tlsinfo;
  31. size_t gen_count;
  32. };
  33. extern ptrdiff_t attribute_hidden
  34. _dl_tlsdesc_return (struct tlsdesc *);
  35. # ifdef SHARED
  36. extern void *_dl_make_tlsdesc_dynamic (struct link_map *, size_t);
  37. extern ptrdiff_t attribute_hidden
  38. _dl_tlsdesc_dynamic (struct tlsdesc *);
  39. # endif
  40. extern void *__tls_get_addr (tls_index *ti);
  41. #define TLS_DTV_UNALLOCATED ((void *) -1l)
  42. #endif