[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: D_LOOKUP in REAL_LOOKUP?
On Tue, Mar 31, 2009 at 11:31 AM, krushnaal pai <krisonearth@xxxxxxxxx> wrote:
> in kernel 2.6.11
> to retrieve a particular file the kernel calls d_lookup to check cache but
> if it is not found in dcache ,kernel calls real_lookup to search the hard
> disk.
> however inside real_lookup the kernel again calls d_lookup . can someone plz
> explain why?
Because while you were waiting/sleeping for semaphore to be acquired.
Someone else might have actually read the contents into dentry cache.
So, why do a lookup!
Just to speed things up, it is a clever trick.
Comments tell it.
Thanks,
--Pradeep
>
--
Pradeep
--
To unsubscribe from this list: send an email with
"unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx
Please read the FAQ at http://kernelnewbies.org/FAQ