<ahref="chinline_8h.html">Go to the documentation of this file.</a><divclass="fragment"><preclass="fragment"><aname="l00001"></a>00001 <spanclass="comment">/*</span>
<aname="l00040"></a>00040 <spanclass="preprocessor"></span><spanclass="keyword">static</span><aclass="code"href="group__types.html#ga2eb6f9e0395b47b8d5e3eeae4fe0c116"title="Inline function modifier.">INLINE</a><spanclass="keywordtype">void</span><aclass="code"href="group__internals.html#ga02226b866ae704435baf2ffe259ba0b2"title="Inserts a thread into a priority ordered queue.">prio_insert</a>(<aclass="code"href="struct_thread.html"title="Structure representing a thread.">Thread</a> *tp, <aclass="code"href="struct_threads_queue.html"title="Generic threads bidirectional linked list header and element.">ThreadsQueue</a> *tqp) {
<aname="l00041"></a>00041
<aname="l00042"></a>00042 <aclass="code"href="struct_thread.html"title="Structure representing a thread.">Thread</a> *cp = (<aclass="code"href="struct_thread.html"title="Structure representing a thread.">Thread</a> *)tqp;
<aname="l00044"></a>00044 cp = cp-><aclass="code"href="struct_thread.html#a49d3270919a6e423a47de20bc57beaa1"title="Next in the list/queue.">p_next</a>;
<aname="l00046"></a>00046 tp-><aclass="code"href="struct_thread.html#a49d3270919a6e423a47de20bc57beaa1"title="Next in the list/queue.">p_next</a> = cp;
<aname="l00047"></a>00047 tp-><aclass="code"href="struct_thread.html#a7661cf39bbb29453ce0c48a94708fb69"title="Previous in the queue.">p_prev</a> = cp-><aclass="code"href="struct_thread.html#a7661cf39bbb29453ce0c48a94708fb69"title="Previous in the queue.">p_prev</a>;
<aname="l00048"></a>00048 tp-><aclass="code"href="struct_thread.html#a7661cf39bbb29453ce0c48a94708fb69"title="Previous in the queue.">p_prev</a>-><aclass="code"href="struct_thread.html#a49d3270919a6e423a47de20bc57beaa1"title="Next in the list/queue.">p_next</a> = cp-><aclass="code"href="struct_thread.html#a7661cf39bbb29453ce0c48a94708fb69"title="Previous in the queue.">p_prev</a> = tp;
<aname="l00049"></a>00049 }
<aname="l00050"></a>00050
<aname="l00051"></a>00051 <spanclass="keyword">static</span><aclass="code"href="group__types.html#ga2eb6f9e0395b47b8d5e3eeae4fe0c116"title="Inline function modifier.">INLINE</a><spanclass="keywordtype">void</span><aclass="code"href="group__internals.html#gaf7072f75fdab9dcc5f7b8dcad212965c"title="Inserts a Thread into a queue.">queue_insert</a>(<aclass="code"href="struct_thread.html"title="Structure representing a thread.">Thread</a> *tp, <aclass="code"href="struct_threads_queue.html"title="Generic threads bidirectional linked list header and element.">ThreadsQueue</a> *tqp) {
<aname="l00052"></a>00052
<aname="l00053"></a>00053 tp-><aclass="code"href="struct_thread.html#a49d3270919a6e423a47de20bc57beaa1"title="Next in the list/queue.">p_next</a> = (<aclass="code"href="struct_thread.html"title="Structure representing a thread.">Thread</a> *)tqp;
<aname="l00054"></a>00054 tp-><aclass="code"href="struct_thread.html#a7661cf39bbb29453ce0c48a94708fb69"title="Previous in the queue.">p_prev</a> = tqp-><aclass="code"href="struct_threads_queue.html#aefc0a5e3ba3ed03da122337bc13be8fa">p_prev</a>;
<aname="l00055"></a>00055 tp-><aclass="code"href="struct_thread.html#a7661cf39bbb29453ce0c48a94708fb69"title="Previous in the queue.">p_prev</a>-><aclass="code"href="struct_thread.html#a49d3270919a6e423a47de20bc57beaa1"title="Next in the list/queue.">p_next</a> = tqp-><aclass="code"href="struct_threads_queue.html#aefc0a5e3ba3ed03da122337bc13be8fa">p_prev</a> = tp;
<aname="l00056"></a>00056 }
<aname="l00057"></a>00057
<aname="l00058"></a>00058 <spanclass="keyword">static</span><aclass="code"href="group__types.html#ga2eb6f9e0395b47b8d5e3eeae4fe0c116"title="Inline function modifier.">INLINE</a><aclass="code"href="struct_thread.html"title="Structure representing a thread.">Thread</a> *<aclass="code"href="group__internals.html#ga042479f09357fc59befebf4dfe0e9f4a"title="Removes the first-out Thread from a queue and returns it.">fifo_remove</a>(<aclass="code"href="struct_threads_queue.html"title="Generic threads bidirectional linked list header and element.">ThreadsQueue</a> *tqp) {
<aname="l00059"></a>00059 <aclass="code"href="struct_thread.html"title="Structure representing a thread.">Thread</a> *tp = tqp-><aclass="code"href="struct_threads_queue.html#af4a099c245d7ceecdf2f9755d05d0ed0">p_next</a>;
<aname="l00060"></a>00060
<aname="l00061"></a>00061 (tqp-><aclass="code"href="struct_threads_queue.html#af4a099c245d7ceecdf2f9755d05d0ed0">p_next</a> = tp-><aclass="code"href="struct_thread.html#a49d3270919a6e423a47de20bc57beaa1"title="Next in the list/queue.">p_next</a>)->p_prev = (<aclass="code"href="struct_thread.html"title="Structure representing a thread.">Thread</a> *)tqp;
<aname="l00065"></a>00065 <spanclass="keyword">static</span><aclass="code"href="group__types.html#ga2eb6f9e0395b47b8d5e3eeae4fe0c116"title="Inline function modifier.">INLINE</a><aclass="code"href="struct_thread.html"title="Structure representing a thread.">Thread</a> *<aclass="code"href="group__internals.html#gacacfe77140cab62948e63d898bf4dfba"title="Removes the last-out Thread from a queue and returns it.">lifo_remove</a>(<aclass="code"href="struct_threads_queue.html"title="Generic threads bidirectional linked list header and element.">ThreadsQueue</a> *tqp) {
<aname="l00066"></a>00066 <aclass="code"href="struct_thread.html"title="Structure representing a thread.">Thread</a> *tp = tqp-><aclass="code"href="struct_threads_queue.html#aefc0a5e3ba3ed03da122337bc13be8fa">p_prev</a>;
<aname="l00067"></a>00067
<aname="l00068"></a>00068 (tqp-><aclass="code"href="struct_threads_queue.html#aefc0a5e3ba3ed03da122337bc13be8fa">p_prev</a> = tp-><aclass="code"href="struct_thread.html#a7661cf39bbb29453ce0c48a94708fb69"title="Previous in the queue.">p_prev</a>)->p_next = (<aclass="code"href="struct_thread.html"title="Structure representing a thread.">Thread</a> *)tqp;
<aname="l00072"></a>00072 <spanclass="keyword">static</span><aclass="code"href="group__types.html#ga2eb6f9e0395b47b8d5e3eeae4fe0c116"title="Inline function modifier.">INLINE</a><aclass="code"href="struct_thread.html"title="Structure representing a thread.">Thread</a> *<aclass="code"href="group__internals.html#gafff11bcd31d7dc3d1a0a6c66f3fc6ec9"title="Removes a Thread from a queue and returns it.">dequeue</a>(<aclass="code"href="struct_thread.html"title="Structure representing a thread.">Thread</a> *tp) {
<aname="l00073"></a>00073
<aname="l00074"></a>00074 tp-><aclass="code"href="struct_thread.html#a7661cf39bbb29453ce0c48a94708fb69"title="Previous in the queue.">p_prev</a>-><aclass="code"href="struct_thread.html#a49d3270919a6e423a47de20bc57beaa1"title="Next in the list/queue.">p_next</a> = tp-><aclass="code"href="struct_thread.html#a49d3270919a6e423a47de20bc57beaa1"title="Next in the list/queue.">p_next</a>;
<aname="l00075"></a>00075 tp-><aclass="code"href="struct_thread.html#a49d3270919a6e423a47de20bc57beaa1"title="Next in the list/queue.">p_next</a>-><aclass="code"href="struct_thread.html#a7661cf39bbb29453ce0c48a94708fb69"title="Previous in the queue.">p_prev</a> = tp-><aclass="code"href="struct_thread.html#a7661cf39bbb29453ce0c48a94708fb69"title="Previous in the queue.">p_prev</a>;
<aname="l00079"></a>00079 <spanclass="keyword">static</span><aclass="code"href="group__types.html#ga2eb6f9e0395b47b8d5e3eeae4fe0c116"title="Inline function modifier.">INLINE</a><spanclass="keywordtype">void</span><aclass="code"href="group__internals.html#ga5818ce2d363d36402baece614b06e41b"title="Pushes a Thread on top of a stack list.">list_insert</a>(<aclass="code"href="struct_thread.html"title="Structure representing a thread.">Thread</a> *tp, <aclass="code"href="struct_threads_list.html"title="Generic threads single link list, it works like a stack.">ThreadsList</a> *tlp) {
<aname="l00080"></a>00080
<aname="l00081"></a>00081 tp-><aclass="code"href="struct_thread.html#a49d3270919a6e423a47de20bc57beaa1"title="Next in the list/queue.">p_next</a> = tlp-><aclass="code"href="struct_threads_list.html#a9076f9b8ac5d59067adc11faa8998371">p_next</a>;
<aname="l00085"></a>00085 <spanclass="keyword">static</span><aclass="code"href="group__types.html#ga2eb6f9e0395b47b8d5e3eeae4fe0c116"title="Inline function modifier.">INLINE</a><aclass="code"href="struct_thread.html"title="Structure representing a thread.">Thread</a> *<aclass="code"href="group__internals.html#gad9aa523aebdaeefa3cc4a311bc210e8a"title="Pops a Thread from the top of a stack list and returns it.">list_remove</a>(<aclass="code"href="struct_threads_list.html"title="Generic threads single link list, it works like a stack.">ThreadsList</a> *tlp) {
<aname="l00086"></a>00086
<aname="l00087"></a>00087 <aclass="code"href="struct_thread.html"title="Structure representing a thread.">Thread</a> *tp = tlp-><aclass="code"href="struct_threads_list.html#a9076f9b8ac5d59067adc11faa8998371">p_next</a>;
<aname="l00088"></a>00088 tlp-><aclass="code"href="struct_threads_list.html#a9076f9b8ac5d59067adc11faa8998371">p_next</a> = tp-><aclass="code"href="struct_thread.html#a49d3270919a6e423a47de20bc57beaa1"title="Next in the list/queue.">p_next</a>;
Generated on Sun Nov 28 2010 14:09:48 for ChibiOS/RT by <ahref="http://www.doxygen.org/index.html"><imgsrc="doxygen.png"alt="doxygen"align="middle"border="0"></a> 1.7.1</small></address>