Re: Reader/writer semaphores

2008-04-07 Thread sahlot arvind
Dear Bhanu, Let me put it into simple words. If you want to protect a write operation such as a++ where a is global variable of your program/module (i.e. it is manipulated by your code only) then please use write semaphore. You will play safe. Otherwise if a is a variable inside kernel and

Re: Reader/writer semaphores

2008-04-04 Thread bhanu nani
On 4/1/08, Fabio De Francesco [EMAIL PROTECTED] wrote: On Tuesday 01 April 2008 23:57:47 bhanu nani wrote: Hi guys, I was studying on reader-writer semaphores in LLD3. Refered to some samaphore books. but some clarity is missing. Reader/Writer Semaphores

Re: Reader/writer semaphores

2008-04-04 Thread bhanu nani
bhanu nani wrote: Hi guys, I was studying on reader-writer semaphores in LLD3. Refered to some samaphore books. but some clarity is missing. Reader/Writer Semaphores: The critical section between down_read, up_read semaphores provides read-only

Re: Reader/writer semaphores

2008-04-03 Thread sahlot arvind
use. - Bhanu On 4/1/08, Fabio De Francesco [EMAIL PROTECTED] wrote: On Tuesday 01 April 2008 23:57:47 bhanu nani wrote: Hi guys, I was studying on reader-writer semaphores in LLD3. Refered to some samaphore books. but some clarity is missing. Reader/Writer Semaphores

Re: Reader/writer semaphores

2008-04-03 Thread Erik Mouw
On Wed, Apr 02, 2008 at 11:22:17AM -0700, bhanu nani wrote: My understanding: Semaphore are the tools to protect a region of code by bloking access to other threads access while the first thead is accessing it. You shouldn't protect a region of code. Semaphores (and other locking primitives)

Re: Reader/writer semaphores

2008-04-03 Thread bhanu nani
to protect them? or some location updates to my own structure which I have to make for future use. - Bhanu On 4/1/08, Fabio De Francesco [EMAIL PROTECTED] wrote: On Tuesday 01 April 2008 23:57:47 bhanu nani wrote: Hi guys, I was studying on reader-writer semaphores

Re: Reader/writer semaphores

2008-04-02 Thread bhanu nani
semaphores in LLD3. Refered to some samaphore books. but some clarity is missing. Reader/Writer Semaphores: The critical section between down_read, up_read semaphores provides read-only access to the protected resources. I assume that any data in between thi calls is considered protected

Reader/writer semaphores

2008-04-01 Thread bhanu nani
Hi guys, I was studying on reader-writer semaphores in LLD3. Refered to some samaphore books. but some clarity is missing. Reader/Writer Semaphores: The critical section between down_read, up_read semaphores provides read-only access to the protected resources. I assume that any data in between

Re: Reader/writer semaphores

2008-04-01 Thread Fabio De Francesco
On Tuesday 01 April 2008 23:57:47 bhanu nani wrote: Hi guys, I was studying on reader-writer semaphores in LLD3. Refered to some samaphore books. but some clarity is missing. Reader/Writer Semaphores: The critical section between down_read, up_read semaphores provides read-only access