comparison packages/kernel/current/include/mlqueue.hxx @ 2:443894e2e912 ecos-v1_2_1-release

Block commit of eCos version 1.2.1
author jlarmour
date Tue, 11 May 1999 12:24:34 +0000
parents 3111d98ba7b3
children c38311975d4f
comparison
equal deleted inserted replaced
1:72f549f0d891 2:443894e2e912
1 #ifndef CYGONCE_KERNEL_MLQUEUE_HXX 1 #ifndef CYGONCE_KERNEL_MLQUEUE_HXX
2 #define CYGONCE_KERNEL_MLQUEUE_HXX 2 #define CYGONCE_KERNEL_MLQUEUE_HXX
3 3
4 //========================================================================== 4 //==========================================================================
5 // 5 //
6 // mlqueue.hxx 6 // mlqueue.hxx
7 // 7 //
8 // Multi-Level Queue scheduler class declarations 8 // Multi-Level Queue scheduler class declarations
9 // 9 //
10 //========================================================================== 10 //==========================================================================
11 //####COPYRIGHTBEGIN#### 11 //####COPYRIGHTBEGIN####
12 // 12 //
13 // ------------------------------------------- 13 // -------------------------------------------
23 // 23 //
24 // The Original Code is eCos - Embedded Cygnus Operating System, released 24 // The Original Code is eCos - Embedded Cygnus Operating System, released
25 // September 30, 1998. 25 // September 30, 1998.
26 // 26 //
27 // The Initial Developer of the Original Code is Cygnus. Portions created 27 // The Initial Developer of the Original Code is Cygnus. Portions created
28 // by Cygnus are Copyright (C) 1998 Cygnus Solutions. All Rights Reserved. 28 // by Cygnus are Copyright (C) 1998,1999 Cygnus Solutions. All Rights Reserved.
29 // ------------------------------------------- 29 // -------------------------------------------
30 // 30 //
31 //####COPYRIGHTEND#### 31 //####COPYRIGHTEND####
32 //========================================================================== 32 //==========================================================================
33 //#####DESCRIPTIONBEGIN#### 33 //#####DESCRIPTIONBEGIN####
34 // 34 //
35 // Author(s): nickg 35 // Author(s): nickg
36 // Contributors: nickg 36 // Contributors: nickg
37 // Date: 1997-09-10 37 // Date: 1997-09-10
38 // Purpose: Define multilevel queue scheduler implementation 38 // Purpose: Define multilevel queue scheduler implementation
39 // Description: The classes defined here are used as base classes 39 // Description: The classes defined here are used as base classes
40 // by the common classes that define schedulers and thread 40 // by the common classes that define schedulers and thread
41 // things. The MLQ scheduler in various configurations 41 // things. The MLQ scheduler in various configurations
42 // provides standard FIFO, round-robin and single priority 42 // provides standard FIFO, round-robin and single priority
43 // schedulers. 43 // schedulers.
44 // Usage: Included according to configuration by 44 // Usage: Included according to configuration by
120 120
121 // test if queue is empty 121 // test if queue is empty
122 cyg_bool empty(); 122 cyg_bool empty();
123 123
124 void rotate(); // Rotate the queue 124 void rotate(); // Rotate the queue
125
126 void to_head(Cyg_Thread *thread);
127
125 }; 128 };
126 129
127 inline cyg_bool Cyg_ThreadQueue_Implementation::empty() 130 inline cyg_bool Cyg_ThreadQueue_Implementation::empty()
128 { 131 {
129 return queue == NULL; 132 return queue == NULL;
234 237
235 void yield(); // Yield CPU to next thread 238 void yield(); // Yield CPU to next thread
236 239
237 static void rotate_queue( cyg_priority pri ); 240 static void rotate_queue( cyg_priority pri );
238 // Rotate that run queue 241 // Rotate that run queue
242
243 void to_queue_head( void ); // Move this thread to the head
244 // of its queue (not necessarily
245 // a scheduler queue)
239 }; 246 };
240 247
241 // ------------------------------------------------------------------------- 248 // -------------------------------------------------------------------------
242 #endif // ifndef CYGONCE_KERNEL_MLQUEUE_HXX 249 #endif // ifndef CYGONCE_KERNEL_MLQUEUE_HXX
243 // EOF mlqueue.hxx 250 // EOF mlqueue.hxx