Changes in uspace/lib/c/arch/ia32/src/tls.c [6adb775f:31399f3] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/arch/ia32/src/tls.c
r6adb775f r31399f3 1 1 /* 2 2 * Copyright (c) 2006 Ondrej Palkovsky 3 * Copyright (c) 2016 Jiri Svoboda4 3 * All rights reserved. 5 4 * … … 40 39 #include <align.h> 41 40 42 #ifdef CONFIG_RTLD43 #include <rtld/rtld.h>44 #endif45 46 41 tcb_t *tls_alloc_arch(void **data, size_t size) 47 42 { … … 73 68 74 69 /* Calculate size of TLS block */ 75 tls_size = tls_get_size();70 tls_size = ALIGN_UP(&_tbss_end - &_tdata_start, &_tls_alignment); 76 71 77 72 /* The TLS block is just before TCB */ 78 73 tls = (uint8_t *)__tcb_get() - tls_size; 79 74 80 #ifdef CONFIG_RTLD81 if (runtime_env != NULL) {82 return rtld_tls_get_addr(runtime_env, tls, ti->ti_module,83 ti->ti_offset);84 }85 #endif86 75 return tls + ti->ti_offset; 87 76 }
Note:
See TracChangeset
for help on using the changeset viewer.