diff options
author | Ingo Molnar <mingo@elte.hu> | 2008-07-08 01:47:47 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-07-08 01:47:47 -0400 |
commit | 93022136fff9e6130aa128a5ed8a599e93ac813c (patch) | |
tree | 185390fb75a3d7423cc508610b76637c957205b9 /fs/proc/proc_misc.c | |
parent | c49c412a47b5102516d3313d4eba38cb1e968721 (diff) | |
parent | b7279469d66b55119784b8b9529c99c1955fe747 (diff) |
Merge commit 'v2.6.26-rc9' into x86/cpu
Diffstat (limited to 'fs/proc/proc_misc.c')
-rw-r--r-- | fs/proc/proc_misc.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/proc/proc_misc.c b/fs/proc/proc_misc.c index 32dc14cd8900..7e277f2ad466 100644 --- a/fs/proc/proc_misc.c +++ b/fs/proc/proc_misc.c | |||
@@ -716,7 +716,7 @@ static ssize_t kpagecount_read(struct file *file, char __user *buf, | |||
716 | pfn = src / KPMSIZE; | 716 | pfn = src / KPMSIZE; |
717 | count = min_t(size_t, count, (max_pfn * KPMSIZE) - src); | 717 | count = min_t(size_t, count, (max_pfn * KPMSIZE) - src); |
718 | if (src & KPMMASK || count & KPMMASK) | 718 | if (src & KPMMASK || count & KPMMASK) |
719 | return -EIO; | 719 | return -EINVAL; |
720 | 720 | ||
721 | while (count > 0) { | 721 | while (count > 0) { |
722 | ppage = NULL; | 722 | ppage = NULL; |
@@ -726,7 +726,7 @@ static ssize_t kpagecount_read(struct file *file, char __user *buf, | |||
726 | if (!ppage) | 726 | if (!ppage) |
727 | pcount = 0; | 727 | pcount = 0; |
728 | else | 728 | else |
729 | pcount = atomic_read(&ppage->_count); | 729 | pcount = page_mapcount(ppage); |
730 | 730 | ||
731 | if (put_user(pcount, out++)) { | 731 | if (put_user(pcount, out++)) { |
732 | ret = -EFAULT; | 732 | ret = -EFAULT; |
@@ -782,7 +782,7 @@ static ssize_t kpageflags_read(struct file *file, char __user *buf, | |||
782 | pfn = src / KPMSIZE; | 782 | pfn = src / KPMSIZE; |
783 | count = min_t(unsigned long, count, (max_pfn * KPMSIZE) - src); | 783 | count = min_t(unsigned long, count, (max_pfn * KPMSIZE) - src); |
784 | if (src & KPMMASK || count & KPMMASK) | 784 | if (src & KPMMASK || count & KPMMASK) |
785 | return -EIO; | 785 | return -EINVAL; |
786 | 786 | ||
787 | while (count > 0) { | 787 | while (count > 0) { |
788 | ppage = NULL; | 788 | ppage = NULL; |