Re: [patch] vfs: no "(unreachable)" prefix for SYSVIPC maps in/proc/PID/maps

From: Hugh Dickins
Date: Tue Sep 08 2009 - 14:05:06 EST


On Mon, 7 Sep 2009, Miklos Szeredi wrote:
> Another fix for vfs-fix-d_path-for-unreachable-paths.patch in -mm.
>
> ----
> From: Miklos Szeredi <mszeredi@xxxxxxx>
>
> The patch
>
> "vfs: fix d_path() for unreachable paths"
>
> generally changed d_path() to report unreachable paths with a special
> prefix. This has an effect on /proc/${PID}/maps as well for memory
> maps set up with shmem_file_setup() or hugetlb_file_setup(). These
> functions set up unlinked files under a kernel-private vfsmount.
> Since this vfsmount is unreachable from userspace, these maps will be
> reported with the "(unreachable)" prefix.
>
> This is undesirable, because it changes the kernel ABI and might break
> applications for no good reason.
>
> Signed-off-by: Miklos Szeredi <mszeredi@xxxxxxx>
> ---
> fs/hugetlbfs/inode.c | 17 +++++++++++++++++
> mm/shmem.c | 17 +++++++++++++++++
> 2 files changed, 34 insertions(+)

You can add my
Acked-by: Hugh Dickins <hugh.dickins@xxxxxxxxxxxxx>
to this and to the preceding two patches.

And give yourself a gold star for putting your updates into the right
section of mm/shmem.c, to cover both CONFIG_SHMEM=y and not set.

My heart sinks a little with these patches, particularly this
last; but I bet your heart sank a little to have to do them, and
I reluctantly agree with you that they're all probably necessary.
They do as you've said - I checked again with the 10.3 gnome-vfs.

Thanks,
Hugh
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/