1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
Commit Graph

57 Commits

Author SHA1 Message Date
Joakim Gebart
13832d8e62 everything: Remove filename from @file Doxygen command 2015-05-22 07:34:41 +02:00
Lucas Jenss
426170b064 Improve naming of thread stacksize/priority constants
As discussed in #2725, this commit renames a number of stacksize constants to
better convey their intended usage. In addition, constants for thread priority
are given a `THREAD_` prefix. Changes are:

* KERNEL_CONF_STACKSIZE_PRINTF renamed to THREAD_EXTRA_STACKSIZE_PRINTF
* KERNEL_CONF_STACKSIZE_DEFAULT renamed to THREAD_STACKSIZE_DEFAULT
* KERNEL_CONF_STACKSIZE_IDLE renamed to THREAD_STACKSIZE_IDLE
* KERNEL_CONF_STACKSIZE_MAIN renamed to THREAD_STACKSIZE_MAIN
* Move thread stacksizes from kernel.h to thread.h, since the prefix changed
* PRIORITY_MIN renamed to THREAD_PRIORITY_MIN
* PRIORITY_IDLE renamed to THREAD_PRIORITY_IDLE
* PRIORITY_MAIN renamed to THREAD_PRIORITY_MAIN
* Move thread priorities from kernel.h to thread.h since the prefix has changed
* MINIMUM_STACK_SIZE renamed to THREAD_STACKSIZE_MINIMUM for consistency
2015-05-21 00:14:23 +02:00
Joseph Noir
e3a5bb25af Add fix for clockid_t on OS X 2015-04-16 11:43:51 +02:00
Martin Landsmann
6e90ad6d73 sys/posix/pthread: added dynamic pthread thread local storage 2015-01-27 23:04:12 +01:00
Ludwig Ortmann
0027f90be4 Merge pull request #2118 from OlegHahm/simplify_cpu_folder_structure
cpu: simplify folder structure
2014-12-08 13:10:13 +01:00
Oleg Hahm
26ab4829d7 doc: fix posix wrapper documentation 2014-12-06 02:05:51 +01:00
Oleg Hahm
0ccf1043de doc: fixed broken doxygen references 2014-12-04 17:16:57 +01:00
Oleg Hahm
0c967c4d3f cpu: msp430: renamed msp430x16x to msp430fxyz 2014-12-02 17:46:57 +01:00
Oleg Hahm
037571445c Merge pull request #1974 from OlegHahm/cleanup_licenses
licenses: fix miss-spelled & missing boiler plates
2014-11-10 19:53:40 +01:00
Oleg Hahm
39abba1bc2 licenses: fix miss-spelled & missing boiler plates 2014-11-10 18:59:55 +01:00
BytesGalore
de3c3cebd0 c++: sys: add extern C to header files 2014-11-08 20:09:55 +01:00
Ludwig Ortmann
b7992922ce fix license headers in non-.c files 2014-08-23 16:16:26 +02:00
René Kijewski
2cb4166c3e all over the place: use sched_active_pid
In many places we needlessly use `sched_active_thread->pid` whilst we
already have `sched_active_pid` with the same value, and one less
indirection.

`thread_getpid()` is made `static inline` so that there is no penalty in
using this function over accessing `sched_active_pid` directly.
2014-08-17 21:04:25 +02:00
René Kijewski
f3fcc1d5dd pthread: pthread_barrier should call yield 2014-08-11 16:22:38 +02:00
Oleg Hahm
1de5c2b4a0 fixed remaining variables to kernel_pid_t 2014-08-07 17:29:53 +02:00
Oleg Hahm
74fbff1df2 net: changed name of internal variable
To avoid naming conflicts + made variable static and volatile as it
should be.
2014-08-07 16:31:27 +02:00
Oleg Hahm
0ad7b170ed make kernel_pid_t comparisons consistent 2014-08-07 16:31:27 +02:00
Oleg Hahm
aa2ecf6216 initialize kernel_pid_t correctly 2014-08-07 16:31:27 +02:00
Oleg Hahm
c2b0423918 core: renamed KERNEL_PID_NULL to KERNEL_PID_UNDEF
As @authmillenon pointed out the "null" in the old name is somewhat
misleading, since the actual value is -1.
2014-08-07 16:31:27 +02:00
Ludwig Ortmann
c2b2e4554b core/queue: queue -> priority_queue
Rename queue to priority queue, because that's what it is.
2014-08-05 17:57:45 +02:00
Oleg Hahm
983d056c75 core: harmonizes the data type for the process ID
Instead of using differing integer types use kernel_pid_t for process
identifier. This type is introduced in a new header file to avoid
circular dependencies.
2014-08-01 12:02:54 +02:00
Ludwig Ortmann
3ca4f18479 doc: use lgplv2.1-short license header instead of lgpl-short-riot 2014-07-31 22:57:20 +02:00
René Kijewski
4032a22719 queue: add queue_t root type 2014-07-30 21:10:22 +02:00
René Kijewski
ba1a15535b core: remove extra thread_create_arg() function 2014-07-09 10:28:23 +02:00
René Kijewski
840c0f0a57 make: detect their module name automatically
For many modules the `Makefile` contains a line like
```
MODULE:=$(shell basename $(CURDIR))
```
This conclusively shows that we do not have to set the module name
manually.

This PR removes the need to set the module name manually, if it is the
same as the basename. E.g. for `…/sys/vtimer/Makefile` the variable
make `MODULE` will still be `vtimer`, because it is the basename of the
Makefile.
2014-06-17 15:49:32 +02:00
René Kijewski
05a4bf7f04 Merge pull request #1057 from Kijewski/sched_switch-current_prio
core: imply current_prio in `sched_switch()`
2014-06-03 15:59:23 +02:00
Martin Lenders
2362623490 Fix trailing whitespaces
Fixes #1138
2014-05-26 14:54:23 +02:00
René Kijewski
a6fd5bff92 core: imply current_prio in sched_switch()
There is no need to supply the current priority to `sched_switch()`,
when this function can easily tell the value of
`active_thread->priority` itself.
2014-05-24 16:48:35 +02:00
Christian Mehlis
0aa87a8ee7 Merge pull request #1208 from Kijewski/issue-1199
documentation: fix doxygen for `pthread_*.h`
2014-05-20 14:19:52 +02:00
René Kijewski
e135bdc266 documentation: fix doxygen for pthread_*.h
The pthread header files aren't in the doxygen page anymore after #1137,
because I `@file`'d the `.c` files, not the `.h` files.

This change moves doxygen boilerplate.

Closes #1199.
2014-05-18 17:33:49 +02:00
Oleg Hahm
ef5ec344fd core: prefix API functions correctly
Also changed names for bitarithm functions and rename thread_pid to sched_active_pid.
2014-05-18 08:53:20 +02:00
Ludwig Ortmann
2314915ff2 license: fix license header grammar
insert missing "is"
2014-05-14 09:49:09 +02:00
Martin Landsmann
61b0331980 added pthread_cond.h to pthread.h
adjusted `test_pthread_condition_variable\main.c` includes reflecting the above change
2014-05-07 07:54:54 +02:00
BytesGalore
f4a994ac89 Merge pull request #1076 from BytesGalore/remove_return_from_noreturn_function
sys:posix:pthread removed explicit `return;` from `pthread_exit()`
2014-04-30 07:50:32 +02:00
Martin
fc532ad891 added else branch in pthread_exit() to avoid calling explicit return;
however, this won't help to completely eliminate the warning on returning from a `noreturn` function
2014-04-30 07:22:48 +02:00
Martin
619039e0e2 add pthread condition variable implementation 2014-04-29 18:39:03 +02:00
BytesGalore
9d4d98c9ea Merge pull request #1025 from BytesGalore/add_out_of_bounds_check
sys:posix:pthread added check to avoid array out of bound access
2014-04-25 18:00:07 +02:00
Martin
345e76a0d7 added check to avoid array out of boud access 2014-04-25 17:57:41 +02:00
René Kijewski
9a5a8a2452 Add pthread_rwlock test 2014-04-18 16:26:12 +02:00
René Kijewski
10d36df795 pthread: implement reader/writer lock 2014-04-18 16:20:47 +02:00
René Kijewski
3101083f13 pthread: fix spinlock 2014-04-18 03:19:31 +02:00
René Kijewski
3e6bebadd3 Add missing doxygen for pthread funs and structs 2014-04-18 03:19:31 +02:00
Martin
e159d0b38a changed return value to 0 on lookup fail in pthread_self() 2014-04-17 14:31:36 +02:00
Martin
f3566f0b8a changed pthread_self() to return thread IDs > 0 2014-04-16 17:31:47 +02:00
Oleg Hahm
8a86f493b4 Merge pull request #821 from Kijewski/pthrad_cleanup
posix: Add pthread_cleanup handlers
2014-04-09 00:19:17 +02:00
René Kijewski
eaca16d07a Add pthread_barrier_t documentation 2014-04-06 19:25:15 +02:00
René Kijewski
9202a482d5 Add pthread_barrier_* functions
Compare [`pthread_barrier_init`][1].

  [1]: http://pubs.opengroup.org/onlinepubs/9699919799/functions/pthread_barrier_init.html
2014-04-06 19:25:15 +02:00
René Kijewski
b44b88a6ed pthread_cleanup: better documentation 2014-04-04 18:03:29 +02:00
René Kijewski
b54962689a posix: Add pthread_cleanup handlers
With `pthread_cleanup_(push|pop)` you can define a function that should
be ran if the thread is exited while it is inside this scope. A thread
can be ended here through an explicit call to `pthread_exit()`, or if
cancellation was requested and a cancellation point was hit.

`pthread_cleanup_*` is mostly only useful together with cancellation
points, and cancellation points are only useful with a cleanup
functionality. Cancellation points are at least partially implemented by
means of `pthread_testcancel()`.

C.f. ["Cancellation Points"][1].

  [1]: http://pubs.opengroup.org/onlinepubs/9699919799/functions/V2_chap02.html#tag_15_09_05_02
2014-04-04 18:03:29 +02:00
René Kijewski
de29e4184c Add include paths automatocally for USEMODULES
Application developers use `$(USEMODULES)` in their Makefiles to have
the relevant functionally automagically added to their apps. This even
does basic dependency tracking by means of `Makefile.dep`.

But an important thing is missing: the automatic adding of include
paths. This is inconvenient, error prone, and will hinder the RIOT core
developers in future to change folder structures.
2014-03-29 16:27:55 +01:00