| 88 | ****************************************************************************/ |
| 89 | |
| 90 | static inline void pthread_tcb_setup(FAR struct tcb_s *ptcb, |
| 91 | FAR struct tcb_s *parent, |
| 92 | pthread_trampoline_t trampoline, |
| 93 | pthread_addr_t arg) |
| 94 | { |
| 95 | FAR struct pthread_entry_s *entry; |
| 96 | #if CONFIG_TASK_NAME_SIZE > 0 |
| 97 | /* Copy the pthread name into the TCB */ |
| 98 | |
| 99 | strlcpy(ptcb->name, parent->name, CONFIG_TASK_NAME_SIZE); |
| 100 | #endif /* CONFIG_TASK_NAME_SIZE */ |
| 101 | |
| 102 | /* For pthreads, args are strictly pass-by-value; that actual |
| 103 | * type wrapped by pthread_addr_t is unknown. |
| 104 | */ |
| 105 | |
| 106 | entry = (FAR struct pthread_entry_s *)(ptcb + 1); |
| 107 | entry->trampoline = trampoline; |
| 108 | entry->arg = arg; |
| 109 | } |
| 110 | |
| 111 | /**************************************************************************** |
| 112 | * Name: pthread_start |
no test coverage detected