Re: [PATCH 4/8] proc: export more page flags in /proc/kpageflags

From: Andrew Morton
Date: Sun May 10 2009 - 01:34:18 EST


On Sat, 9 May 2009 12:44:09 +0200 Ingo Molnar <mingo@xxxxxxx> wrote:

> And because it was so crappy to be in /proc we are now also
> treating it as a hard ABI, not as a debugfs interface - for that
> single app that is using it.

We'd probably make better progress here were someone to explain what
pagemap actually is.


pagemap is a userspace interface via which application developers
(including embedded) can analyse, understand and optimise their use of
memory.

It is not debugging feature at all, let alone a kernel debugging
feature. For this reason it is not appropriate that its interfaces be
presented in debugfs.

Furthermore the main control file for pagemap is in
/proc/<pid>/pagemap. pagemap _cannot_ be put in debugfs because
debugfs doesn't maintain the per-process subdirectories in which to
place it. /proc/<pid>/ is exactly the place where the pagemap file
should appear.

Yes, we could place pagemap's two auxiliary files into debugfs but it
would be rather stupid to split the feature's control files across two
pseudo filesystems, one of which may not even exist. Plus pagemap is
not a kernel debugging feature.
--
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/