* [PATCH] fs: new helper: file_inode(file)
@ 2013-12-11 6:07 Libo Chen
0 siblings, 0 replies; only message in thread
From: Libo Chen @ 2013-12-11 6:07 UTC (permalink / raw)
To: matthew, viro; +Cc: linux-fsdevel, LKML, Li Zefan, bfields
Signed-off-by: Libo Chen <clbchenlibo.chen@huawei.com>
---
include/linux/fs.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/linux/fs.h b/include/linux/fs.h
index 121f11f..a146e2a 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -2780,7 +2780,7 @@ static inline bool dir_emit(struct dir_context *ctx,
static inline bool dir_emit_dot(struct file *file, struct dir_context *ctx)
{
return ctx->actor(ctx, ".", 1, ctx->pos,
- file->f_path.dentry->d_inode->i_ino, DT_DIR) == 0;
+ file_inode(file)->i_ino, DT_DIR) == 0;
}
static inline bool dir_emit_dotdot(struct file *file, struct dir_context *ctx)
{
--
1.8.2.2
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2013-12-11 6:08 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-12-11 6:07 [PATCH] fs: new helper: file_inode(file) Libo Chen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).