All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: report a suspected bug in ubifs
       [not found]       ` <2014bcab0905040059r5ca9b8e1o5bf572ee354f7162@mail.gmail.com>
@ 2009-05-04  8:11         ` Adrian Hunter
  0 siblings, 0 replies; only message in thread
From: Adrian Hunter @ 2009-05-04  8:11 UTC (permalink / raw)
  To: 홍신 shin hong; +Cc: linux-mtd Mailing List

홍신 shin hong wrote:
> Thank you for the reply.
> 
> all accesses to 'wbuf->used' is synchronized by 'io_mutex'
> and its updates(writing accesses) are synchronized by 'wbuf_lock'
> like readers/writer lock ?

Yes, it is like a readers/writers lock.

To read from the wbuf, all that is needed is the spin lock.

To append to the wbuf, without otherwise changing it, all that is needed
is the mutex (and then the spin lock to record that the append happened).

To change the wbuf, the mutex *and* the spin lock are needed.

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2009-05-04  8:11 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <2014bcab0904300810qc66605bk9121b1ab66c53ece@mail.gmail.com>
     [not found] ` <49F9C340.3090304@nokia.com>
     [not found]   ` <2014bcab0904301752x3662f91em3932c7b9730d8558@mail.gmail.com>
     [not found]     ` <49FE9D59.30003@nokia.com>
     [not found]       ` <2014bcab0905040059r5ca9b8e1o5bf572ee354f7162@mail.gmail.com>
2009-05-04  8:11         ` report a suspected bug in ubifs Adrian Hunter

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.