Lines Matching refs:mutex
6 …mutex) is a special binary semaphore used for exclusive access to shared resources. When a task ho…
8 A mutex has three attributes: protocol attribute, priority upper limit attribute, and type attribut…
12 Do not inherit or protect the priority of the task requesting the mutex.
16 …mutex. This is the default protocol attribute. When the mutex protocol attribute is set to this va…
20 …mutex. When the mutex protocol attribute is set to this value: If the priority of the task that re…
22 …The type attribute of a mutex specifies whether to check for deadlocks and whether to support recu…
26 …mutex, which does not check for deadlocks. If a task repeatedly attempts to hold a mutex, the thre…
30 …mutex, which is the default attribute. If the type attribute of a mutex is set to this value, a ta…
34 …mutex is set to this type, an error code will be returned if a task attempts to repeatedly hold th…
39 …esources are not shared, and can only be accessed exclusively by tasks. A mutex can be used to add…
41 … are accessed by a task, the mutex is locked. Other tasks will be blocked until the mutex is relea…
45 ;
131 /* Request a mutex. */
135 dprintf("task1 get mutex g_testMux.\n");
136 /* Release the mutex. */
141 dprintf("task1 timeout and try to get mutex, wait forever.\n");
142 /* Request a mutex. */
145 dprintf("task1 wait forever, get mutex g_testMux.\n");
146 /* Release the mutex. */
148 /* Delete the mutex. */
150 dprintf("task1 post and delete mutex g_testMux.\n");
159 dprintf("task2 try to get mutex, wait forever.\n");
160 /* Request a mutex. */
163 dprintf("task2 get mutex g_testMux and suspend 100 ticks.\n");
169 /* Release the mutex. */
180 /* Initialize the mutex. */
223 task2 try to get mutex, wait forever.
224 task2 get mutex g_testMux and suspend 100 ticks.
225 task1 try to get mutex, wait 10 ticks.
226 task1 timeout and try to get mutex, wait forever.
228 task1 wait forever, get mutex g_testMux.
229 task1 post and delete mutex g_testMux.