All of lore.kernel.org
 help / color / mirror / Atom feed
* [Xenomai-core] Synchronization of shared memory with mutexes
@ 2012-01-10 15:04 Jan-Erik Lange
  2012-01-10 15:22 ` Philippe Gerum
  0 siblings, 1 reply; 2+ messages in thread
From: Jan-Erik Lange @ 2012-01-10 15:04 UTC (permalink / raw)
  To: xenomai

[-- Attachment #1: Type: text/plain, Size: 1212 bytes --]



Hello,

I have a question about basics of the synchronization of shared memory with mutexes.
 
The situation: The Sender is a RT task (primary domain) and the recipient is a non-RT task (usually in the secondary domain). Namely, the receiver is used to interact with a Web server. He calls to syscalls and stuff and because of that he's usually in the secondary mode.
 
Suppose the sender has written something to the shared memory: He uses mutex for synchronization, so he calls the rt_mutex_release() function.
 
The receiver will now get time to work from the scheduler. He calls rt_mutex_acquire() function to lock the shared memory. Then a context switch occurs from the secondary mode in the primary mode. He has now the resource for himself.
 
Now the scheduler lets sender-task to work and it wants to write something. So it calls rt_mutex_acquire() function. And now comes my question: Provides rt_mutex_acquire() a mechanism to signal the cheduler to immediately continue with the recipient-task? If so, how does the rt_mutex_acquire() function tells the scheduler that?
 
I came out because I in the documention I read the term "Rescheduling: always".
 
Best regards
Jan 		 	   		  

[-- Attachment #2: Type: text/html, Size: 1525 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-01-10 15:22 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-01-10 15:04 [Xenomai-core] Synchronization of shared memory with mutexes Jan-Erik Lange
2012-01-10 15:22 ` Philippe Gerum

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.