From: Cyrill Gorcunov <gorcunov@openvz.org>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: Al Viro <viro@zeniv.linux.org.uk>,
Alexey Dobriyan <adobriyan@gmail.com>,
Pavel Emelyanov <xemul@parallels.com>,
James Bottomley <jbottomley@parallels.com>,
Matthew Helsley <matt.helsley@gmail.com>,
aneesh.kumar@linux.vnet.ibm.com, bfields@fieldses.org,
oleg@redhat.com, rientjes@google.com,
tvrtko.ursulin@onelan.co.uk, linux-kernel@vger.kernel.org,
Cyrill Gorcunov <gorcunov@openvz.org>,
Andrey Vagin <avagin@openvz.org>,
Al Viro <viro@zeniv.linux.org.uk>
Subject: [patch -mm 3/4] fs, notify: Dont forget to provide fhandle for inode fanotify
Date: Fri, 23 Nov 2012 01:15:25 +0400 [thread overview]
Message-ID: <20121122212235.606689990@openvz.org> (raw)
In-Reply-To: 20121122211522.075455799@openvz.org
[-- Attachment #1: seq-fsnotify-update --]
[-- Type: text/plain, Size: 2050 bytes --]
For inode based fanotify I missed to add fhandle output. This patch
brings it in.
| pos: 0
| flags: 02
| fanotify ino:2 sdev:800013 mask:1 ignored_mask:40000000 fhandle-bytes:8 fhandle-type:1 f_handle:0200000000000000
Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org>
CC: Pavel Emelyanov <xemul@parallels.com>
CC: Oleg Nesterov <oleg@redhat.com>
CC: Andrey Vagin <avagin@openvz.org>
CC: Al Viro <viro@ZenIV.linux.org.uk>
CC: Alexey Dobriyan <adobriyan@gmail.com>
CC: Andrew Morton <akpm@linux-foundation.org>
CC: James Bottomley <jbottomley@parallels.com>
CC: "Aneesh Kumar K.V" <aneesh.kumar@linux.vnet.ibm.com>
CC: Alexey Dobriyan <adobriyan@gmail.com>
CC: Matthew Helsley <matt.helsley@gmail.com>
CC: "J. Bruce Fields" <bfields@fieldses.org>
CC: "Aneesh Kumar K.V" <aneesh.kumar@linux.vnet.ibm.com>
CC: Tvrtko Ursulin <tvrtko.ursulin@onelan.co.uk>
---
fs/notify/fdinfo.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
Index: linux-2.6.git/fs/notify/fdinfo.c
===================================================================
--- linux-2.6.git.orig/fs/notify/fdinfo.c
+++ linux-2.6.git/fs/notify/fdinfo.c
@@ -36,8 +36,6 @@ static int show_fdinfo(struct seq_file *
return ret;
}
-#ifdef CONFIG_INOTIFY_USER
-
#if defined(CONFIG_EXPORTFS)
static int show_mark_fhandle(struct seq_file *m, struct inode *inode)
{
@@ -74,6 +72,8 @@ static int show_mark_fhandle(struct seq_
}
#endif
+#ifdef CONFIG_INOTIFY_USER
+
static int inotify_fdinfo(struct seq_file *m, struct fsnotify_mark *mark)
{
struct inotify_inode_mark *inode_mark;
@@ -121,9 +121,11 @@ static int fanotify_fdinfo(struct seq_fi
if (!inode)
goto out;
ret = seq_printf(m, "fanotify ino:%lx sdev:%x "
- "mask:%x ignored_mask:%x\n",
+ "mask:%x ignored_mask:%x ",
inode->i_ino, inode->i_sb->s_dev,
mark->mask, mark->ignored_mask);
+ ret |= show_mark_fhandle(m, inode);
+ ret |= seq_putc(m, '\n');
iput(inode);
} else if (mark->flags & FSNOTIFY_MARK_FLAG_VFSMOUNT) {
struct mount *mnt = real_mount(mark->m.mnt);
next prev parent reply other threads:[~2012-11-22 21:22 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-22 21:15 [patch -mm 0/4] Fixes for fdinfo output and docs Cyrill Gorcunov
2012-11-22 21:15 ` [patch -mm 1/4] fs, notify: Add missing space after prefix Cyrill Gorcunov
2012-11-22 21:15 ` [patch -mm 2/4] fs, epoll: Drop enabled field from fdinfo output Cyrill Gorcunov
2012-11-22 21:15 ` Cyrill Gorcunov [this message]
2012-11-22 21:15 ` [patch -mm 4/4] docs: Add documentation about /proc/<pid>/fdinfo/<fd> output Cyrill Gorcunov
2012-11-27 22:47 ` Andrew Morton
2012-11-28 6:40 ` Cyrill Gorcunov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20121122212235.606689990@openvz.org \
--to=gorcunov@openvz.org \
--cc=adobriyan@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=aneesh.kumar@linux.vnet.ibm.com \
--cc=avagin@openvz.org \
--cc=bfields@fieldses.org \
--cc=jbottomley@parallels.com \
--cc=linux-kernel@vger.kernel.org \
--cc=matt.helsley@gmail.com \
--cc=oleg@redhat.com \
--cc=rientjes@google.com \
--cc=tvrtko.ursulin@onelan.co.uk \
--cc=viro@zeniv.linux.org.uk \
--cc=xemul@parallels.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.