Re: [PATCH resend] vfs: Add ->statfs callback for pipefs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 24 Aug 2011 12:09:24 +0400 Cyrill Gorcunov <gorcunov@xxxxxxxxx> wrote:

> From: Pavel Emelyanov <xemul@xxxxxxxxxxxxx>
> 
> This is done to make it possible to distinguish pipes
> from fifos when opening one via /proc/<pid>/fd/ link.
> 
> Signed-off-by: Pavel Emelyanov <xemul@xxxxxxxxxxxxx>
> Reviewed-by: Tejun Heo <tj@xxxxxxxxxx>
> Acked-by: Serge Hallyn <serge.hallyn@xxxxxxxxxxxxx>
> Signed-off-by: Cyrill Gorcunov <gorcunov@xxxxxxxxxx>
> ---
>  fs/pipe.c |    1 +
>  1 file changed, 1 insertion(+)
> 
> Any objections to this one? It was a part of a patchset
> but can be treated independently so I'm re-sending it alone.
> 
> Index: linux-2.6.git/fs/pipe.c
> ===================================================================
> --- linux-2.6.git.orig/fs/pipe.c
> +++ linux-2.6.git/fs/pipe.c
> @@ -1254,6 +1254,7 @@ out:
>  
>  static const struct super_operations pipefs_ops = {
>  	.destroy_inode = free_inode_nonrcu,
> +	.statfs = simple_statfs,
>  };
>  
>  /*

OK, I give up - how does it work?

<goes off and reads the kernel>

So it appears that the statfs call would previously return -ENOSYS, but
with this change the statfs will succeed and userspace can then inspect
f_type.  Yes?  I will fix your changelog by adding a description along these
lines.

And I'll ask you to fix it further by telling us why we want to do
this?  The kernel has had this issue for a long time - why does it now
matter?
_______________________________________________
Containers mailing list
Containers@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linux-foundation.org/mailman/listinfo/containers


[Index of Archives]     [Cgroups]     [Netdev]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux