Pavel Emelyanov d70ef97baf fs/pipe.c: add ->statfs callback for pipefs
Currently a statfs on a pipe's /proc/<pid>/fd/ link returns -ENOSYS.  Wire
pipfs up so that the statfs succeeds.

This is required by checkpoint-restart in the userspace to make it
possible to distinguish pipes from fifos.

When we dump information about task's open files we use the /proc/pid/fd
directoy's symlinks and the fact that opening any of them gives us exactly
the same dentry->inode pair as the original process has.  Now if a task
we're dumping has opened pipe and fifo we need to detect this and act
accordingly.  Knowing that an fd with type S_ISFIFO resides on a pipefs is
the most precise way.

Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
Reviewed-by: Tejun Heo <tj@kernel.org>
Acked-by: Serge Hallyn <serge.hallyn@canonical.com>
Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org>
Cc: Al Viro <viro@ZenIV.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2011-10-31 17:30:51 -07:00
..
2011-03-31 11:26:23 -03:00
2011-09-27 18:08:04 +02:00
2011-08-22 17:41:48 -07:00
2011-10-24 17:22:29 -07:00
2011-09-12 11:47:10 -07:00
2011-07-27 22:21:58 -04:00
2011-07-22 19:42:12 -04:00
2011-03-31 11:26:23 -03:00
2011-07-26 16:49:47 -07:00
2011-07-26 16:49:47 -07:00
2011-07-26 13:05:28 -04:00
2011-01-07 17:50:26 +11:00
2011-03-10 08:52:07 +01:00
2011-04-14 16:06:56 -07:00
2011-09-27 18:08:04 +02:00
2011-10-31 17:30:44 -07:00
2011-10-31 17:30:44 -07:00
2011-10-31 17:30:45 -07:00
2011-07-26 16:49:47 -07:00
2011-03-21 00:16:08 -04:00
2011-05-26 10:01:43 -06:00
2011-10-28 14:59:00 +02:00
2011-10-28 14:59:00 +02:00
2011-01-07 17:50:33 +11:00
2011-10-31 17:30:44 -07:00
2011-07-25 20:57:11 -07:00
2011-08-03 14:25:24 -10:00
2011-09-27 08:12:33 -07:00
2011-03-14 09:15:28 -04:00
2011-07-18 12:29:43 -04:00