* [PATCH 2/4] pagemap: Return map count, not reference count, in /proc/kpagecount. (v2 of series)
@ 2008-06-05 18:39 Thomas Tuttle
0 siblings, 0 replies; only message in thread
From: Thomas Tuttle @ 2008-06-05 18:39 UTC (permalink / raw)
To: mpm, akpm, linux-kernel
Since pagemap is all about examining pages mapped into processes' memory
spaces, it makes sense for kpagecount to return the map counts, not the
reference counts.
Signed-off-by: Thomas Tuttle
---
fs/proc/proc_misc.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/fs/proc/proc_misc.c b/fs/proc/proc_misc.c
index 32dc14c..5a16090 100644
--- a/fs/proc/proc_misc.c
+++ b/fs/proc/proc_misc.c
@@ -726,7 +726,7 @@ static ssize_t kpagecount_read(struct file *file,
char __user *buf,
if (!ppage)
pcount = 0;
else
- pcount = atomic_read(&ppage->_count);
+ pcount = page_mapcount(ppage);
if (put_user(pcount, out++)) {
ret = -EFAULT;
--
1.5.3.6
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2008-06-05 18:39 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-06-05 18:39 [PATCH 2/4] pagemap: Return map count, not reference count, in /proc/kpagecount. (v2 of series) Thomas Tuttle
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®