RCU is not safe enough to protect __d_lookup ?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




Hi, all:


I am studying the dcache in VFS recently . I've found that hlist of dcache is already protected by RCU in

 __d_lookup.Is it necessary  for the function -- d_lookup using sequence lock to protect the hlist again?


struct dentry * d_lookup(struct dentry * parent, struct qstr * name)

{

struct dentry * dentry = NULL;

unsigned long seq;


        do {

                seq = read_seqbegin(&rename_lock);

                dentry = __d_lookup(parent, name);

                if (dentry)

break;

} while (read_seqretry(&rename_lock, seq));

return dentry;

}


Thanks in advance

--------------------------------

Rock Lee


_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@xxxxxxxxxxxxxxxxx
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux