Here's a direct quote from Essential Linux Device Drivers , which may be what you are looking for. It seems that the part related to RCU at the end may be what you are interested in.
Read / write locks
concurrency - -.
, , ,
. .
- :
rwlock_t myrwlock = RW_LOCK_UNLOCKED;
read_lock(&myrwlock);
read_unlock(&myrwlock);
, , .
:
rwlock_t myrwlock = RW_LOCK_UNLOCKED;
write_lock(&myrwlock);
write_unlock(&myrwlock);
IPX, net/ipx/ipx_route.c, - .
- ipx_routes_lock IPX .
. ,
. ,
, .
, irq, read_lock_irqsave(),
read_lock_irqrestore(), write_lock_irqsave() write_lock_irqrestore().
-.
seqlocks , 2.6, -,
. , , .
jiffies_64, . ,
. - , ,
:
u64 get_jiffies_64(void)
{
unsigned long seq;
u64 ret;
do {
seq = read_seqbegin(&xtime_lock);
ret = jiffies_64;
} while (read_seqretry(&xtime_lock, seq));
return ret;
}
, write_seqlock() write_sequnlock().
2.6 , Read-Copy Update (RCU), ,
, . ,
. .
, .
. , RCU ,
, , . RCU
include/linux/rcupdate.h.
Documentation/RCU/*.
RCU fs/dcache.c. Linux
( dentry), ( inode)
( ). , , ,
. , dcache,
. dcache , dcache,
dcache RCU.