Changeset 31399f3 in mainline
- Timestamp:
- 2013-03-07T22:39:31Z (12 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 2277e03
- Parents:
- b42c8d8
- Location:
- uspace/lib/c
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/arch/abs32le/src/tls.c
rb42c8d8 r31399f3 34 34 #include <unistd.h> 35 35 36 tcb_t * __alloc_tls(void **data, size_t size)36 tcb_t * tls_alloc_arch(void **data, size_t size) 37 37 { 38 38 return tls_alloc_variant_2(data, size); 39 39 } 40 40 41 void __free_tls_arch(tcb_t *tcb, size_t size)41 void tls_free_arch(tcb_t *tcb, size_t size) 42 42 { 43 43 tls_free_variant_2(tcb, size); -
uspace/lib/c/arch/amd64/src/tls.c
rb42c8d8 r31399f3 38 38 #include <sys/types.h> 39 39 40 tcb_t * __alloc_tls(void **data, size_t size)40 tcb_t *tls_alloc_arch(void **data, size_t size) 41 41 { 42 42 return tls_alloc_variant_2(data, size); 43 43 } 44 44 45 void __free_tls_arch(tcb_t *tcb, size_t size)45 void tls_free_arch(tcb_t *tcb, size_t size) 46 46 { 47 47 tls_free_variant_2(tcb, size); -
uspace/lib/c/arch/arm32/src/tls.c
rb42c8d8 r31399f3 38 38 #include <sys/types.h> 39 39 40 tcb_t * __alloc_tls(void **data, size_t size)40 tcb_t *tls_alloc_arch(void **data, size_t size) 41 41 { 42 42 return tls_alloc_variant_1(data, size); 43 43 } 44 44 45 void __free_tls_arch(tcb_t *tcb, size_t size)45 void tls_free_arch(tcb_t *tcb, size_t size) 46 46 { 47 47 tls_free_variant_1(tcb, size); -
uspace/lib/c/arch/ia32/src/tls.c
rb42c8d8 r31399f3 39 39 #include <align.h> 40 40 41 tcb_t * __alloc_tls(void **data, size_t size)41 tcb_t *tls_alloc_arch(void **data, size_t size) 42 42 { 43 43 return tls_alloc_variant_2(data, size); 44 44 } 45 45 46 void __free_tls_arch(tcb_t *tcb, size_t size)46 void tls_free_arch(tcb_t *tcb, size_t size) 47 47 { 48 48 tls_free_variant_2(tcb, size); -
uspace/lib/c/arch/ia64/src/tls.c
rb42c8d8 r31399f3 38 38 #include <malloc.h> 39 39 40 tcb_t * __alloc_tls(void **data, size_t size)40 tcb_t *tls_alloc_arch(void **data, size_t size) 41 41 { 42 42 return tls_alloc_variant_1(data, size); 43 43 } 44 44 45 void __free_tls_arch(tcb_t *tcb, size_t size)45 void tls_free_arch(tcb_t *tcb, size_t size) 46 46 { 47 47 tls_free_variant_1(tcb, size); -
uspace/lib/c/arch/mips32/src/tls.c
rb42c8d8 r31399f3 37 37 #include <sys/types.h> 38 38 39 tcb_t * __alloc_tls(void **data, size_t size)39 tcb_t * tls_alloc_arch(void **data, size_t size) 40 40 { 41 41 return tls_alloc_variant_1(data, size); 42 42 } 43 43 44 void __free_tls_arch(tcb_t *tcb, size_t size)44 void tls_free_arch(tcb_t *tcb, size_t size) 45 45 { 46 46 tls_free_variant_1(tcb, size); -
uspace/lib/c/arch/mips64/src/tls.c
rb42c8d8 r31399f3 37 37 #include <sys/types.h> 38 38 39 tcb_t * __alloc_tls(void **data, size_t size)39 tcb_t *tls_alloc_arch(void **data, size_t size) 40 40 { 41 41 return tls_alloc_variant_1(data, size); 42 42 } 43 43 44 void __free_tls_arch(tcb_t *tcb, size_t size)44 void tls_free_arch(tcb_t *tcb, size_t size) 45 45 { 46 46 tls_free_variant_1(tcb, size); -
uspace/lib/c/arch/ppc32/src/tls.c
rb42c8d8 r31399f3 36 36 #include <sys/types.h> 37 37 38 tcb_t * __alloc_tls(void **data, size_t size)38 tcb_t *tls_alloc_arch(void **data, size_t size) 39 39 { 40 40 return tls_alloc_variant_1(data, size); 41 41 } 42 42 43 void __free_tls_arch(tcb_t *tcb, size_t size)43 void tls_free_arch(tcb_t *tcb, size_t size) 44 44 { 45 45 tls_free_variant_1(tcb, size); -
uspace/lib/c/arch/sparc64/src/tls.c
rb42c8d8 r31399f3 38 38 #include <sys/types.h> 39 39 40 tcb_t * __alloc_tls(void **data, size_t size)40 tcb_t *tls_alloc_arch(void **data, size_t size) 41 41 { 42 42 return tls_alloc_variant_2(data, size); 43 43 } 44 44 45 void __free_tls_arch(tcb_t *tcb, size_t size)45 void tls_free_arch(tcb_t *tcb, size_t size) 46 46 { 47 47 tls_free_variant_2(tcb, size); -
uspace/lib/c/generic/fibril.c
rb42c8d8 r31399f3 95 95 fibril_t *fibril_setup(void) 96 96 { 97 tcb_t *tcb = __make_tls();97 tcb_t *tcb = tls_make(); 98 98 if (!tcb) 99 99 return NULL; … … 101 101 fibril_t *fibril = malloc(sizeof(fibril_t)); 102 102 if (!fibril) { 103 __free_tls(tcb);103 tls_free(tcb); 104 104 return NULL; 105 105 } … … 122 122 void fibril_teardown(fibril_t *fibril) 123 123 { 124 __free_tls(fibril->tcb);124 tls_free(fibril->tcb); 125 125 free(fibril); 126 126 } -
uspace/lib/c/generic/tls.c
rb42c8d8 r31399f3 51 51 * @return Pointer to TCB. 52 52 */ 53 tcb_t * __make_tls(void)53 tcb_t *tls_make(void) 54 54 { 55 55 void *data; … … 57 57 size_t tls_size = &_tbss_end - &_tdata_start; 58 58 59 tcb = __alloc_tls(&data, tls_size);59 tcb = tls_alloc_arch(&data, tls_size); 60 60 if (!tcb) 61 61 return NULL; … … 74 74 } 75 75 76 void __free_tls(tcb_t *tcb)76 void tls_free(tcb_t *tcb) 77 77 { 78 78 size_t tls_size = &_tbss_end - &_tdata_start; 79 __free_tls_arch(tcb, tls_size);79 tls_free_arch(tcb, tls_size); 80 80 } 81 81 -
uspace/lib/c/include/tls.h
rb42c8d8 r31399f3 48 48 extern char _tbss_end; 49 49 50 extern tcb_t * __make_tls(void);51 extern tcb_t * __alloc_tls(void **, size_t);52 extern void __free_tls(tcb_t *);53 extern void __free_tls_arch(tcb_t *, size_t);50 extern tcb_t *tls_make(void); 51 extern tcb_t *tls_alloc_arch(void **, size_t); 52 extern void tls_free(tcb_t *); 53 extern void tls_free_arch(tcb_t *, size_t); 54 54 55 55 #ifdef CONFIG_TLS_VARIANT_1
Note:
See TracChangeset
for help on using the changeset viewer.