Changeset 38d8849 in mainline for uspace/lib/c
- Timestamp:
- 2018-07-16T15:58:51Z (7 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- db51219f
- Parents:
- c124c985
- git-author:
- Jiří Zárevúcky <jiri.zarevucky@…> (2018-07-14 16:53:46)
- git-committer:
- Jiří Zárevúcky <jiri.zarevucky@…> (2018-07-16 15:58:51)
- Location:
- uspace/lib/c
- Files:
-
- 1 deleted
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/arch/arm32/include/libarch/fibril.h
rc124c985 r38d8849 39 39 #include <types/common.h> 40 40 #include <align.h> 41 #include <thread.h>42 41 #include <libarch/fibril_context.h> 43 42 -
uspace/lib/c/generic/fibril.c
rc124c985 r38d8849 36 36 #include <adt/list.h> 37 37 #include <fibril.h> 38 #include <thread.h>39 38 #include <stack.h> 40 39 #include <tls.h> … … 49 48 #include <async.h> 50 49 50 #include "private/thread.h" 51 51 #include "private/fibril.h" 52 52 -
uspace/lib/c/generic/private/thread.h
rc124c985 r38d8849 36 36 #define LIBC_PRIVATE_THREAD_H_ 37 37 38 #include <time.h> 38 39 #include <abi/proc/uarg.h> 40 #include <libarch/thread.h> 41 #include <abi/proc/thread.h> 39 42 40 43 extern void __thread_entry(void); 41 44 extern void __thread_main(uspace_arg_t *); 45 46 extern errno_t thread_create(void (*)(void *), void *, const char *, thread_id_t *); 47 extern void thread_exit(int) __attribute__((noreturn)); 48 extern void thread_detach(thread_id_t); 49 extern thread_id_t thread_get_id(void); 50 extern int thread_usleep(useconds_t); 51 extern unsigned int thread_sleep(unsigned int); 42 52 43 53 #endif -
uspace/lib/c/generic/rcu.c
rc124c985 r38d8849 80 80 #include <assert.h> 81 81 #include <time.h> 82 #include <thread.h>83 82 84 83 #include "private/fibril.h" -
uspace/lib/c/generic/stats.c
rc124c985 r38d8849 184 184 } 185 185 186 /** Get single thread statistics187 *188 * @param thread_id Thread ID we are interested in.189 *190 * @return Pointer to the stats_thread_t structure.191 * If non-NULL then it should be eventually freed192 * by free().193 *194 */195 stats_thread_t *stats_get_thread(thread_id_t thread_id)196 {197 char name[SYSINFO_STATS_MAX_PATH];198 snprintf(name, SYSINFO_STATS_MAX_PATH, "system.threads.%" PRIu64, thread_id);199 200 size_t size = 0;201 stats_thread_t *stats_thread =202 (stats_thread_t *) sysinfo_get_data(name, &size);203 204 if (size != sizeof(stats_thread_t)) {205 if (stats_thread != NULL)206 free(stats_thread);207 return NULL;208 }209 210 return stats_thread;211 }212 213 186 /** Get exception statistics. 214 187 * -
uspace/lib/c/generic/thread.c
rc124c985 r38d8849 33 33 */ 34 34 35 #include <thread.h>36 35 #include <libc.h> 37 36 #include <stdbool.h> … … 159 158 } 160 159 161 /** Join thread.162 *163 * Currently not implemented.164 *165 * @param thread TID.166 *167 * @return Thread exit status.168 */169 errno_t thread_join(thread_id_t thread)170 {171 return 0;172 }173 174 160 /** Get current thread ID. 175 161 * -
uspace/lib/c/include/stats.h
rc124c985 r38d8849 37 37 38 38 #include <task.h> 39 #include <thread.h>40 39 #include <stdint.h> 41 40 #include <stdbool.h> … … 53 52 54 53 extern stats_thread_t *stats_get_threads(size_t *); 55 extern stats_thread_t *stats_get_thread(thread_id_t);56 54 57 55 extern stats_exc_t *stats_get_exceptions(size_t *);
Note:
See TracChangeset
for help on using the changeset viewer.