[<prev] [next>] [day] [month] [year] [list]
Message-ID: <f2b55d220703141228q11c93c2i9b0b86d8953ab8b8@mail.gmail.com>
Date: Wed, 14 Mar 2007 12:28:01 -0700
From: "Michael K. Edwards" <medwards.linux@...il.com>
To: "Linux Kernel Mailing List" <linux-kernel@...r.kernel.org>
Subject: f_mapping->host vs. f_path.dentry->d_inode
It appears that there are (at least) two ways to get the inode (if
any) associated with an open file: f_mapping->host (pagecache?) and
f_path.dentry->d_inode (dentry cache?). generic_file_llseek uses
f_mapping->host; everything else in read_write.c uses
f_path.dentry->d_inode. do_sendfile checks for a null inode on its
input fd but not on its output fd; nothing else in read_write.c checks
for null inode.
Under what circumstances can f_mapping->host and f_path.dentry->d_inode differ?
Under what circumstances can either or both of these pointers be null?
Under what circumstances is it preferable to retrieve the inode from
f_mapping vs. f_path.dentry, either because they differ or because one
or the other is more likely to be warm in cache?
Cheers,
- Michael
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists