diff options
author | Steve French <sfrench@us.ibm.com> | 2006-02-01 15:16:53 -0500 |
---|---|---|
committer | Steve French <sfrench@us.ibm.com> | 2006-02-01 15:16:53 -0500 |
commit | e6da74e1f20ea7822e52a9e4fbd3d25bd907e471 (patch) | |
tree | d9b3bc7e654fb788d1cf3a1759b1b3c74cc56a04 /fs/hugetlbfs/inode.c | |
parent | 1877c9ea66a29563987f22d0a86c66f438a87ce2 (diff) | |
parent | 3c3b809e256c417847f1a96b2f9d9f66c7fcb02c (diff) |
Merge with /pub/scm/linux/kernel/git/torvalds/linux-2.6.git
Signed-off-by: Steve French <sfrench@us.ibm.com>
Diffstat (limited to 'fs/hugetlbfs/inode.c')
-rw-r--r-- | fs/hugetlbfs/inode.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/hugetlbfs/inode.c b/fs/hugetlbfs/inode.c index f568102da1e8..b35195289945 100644 --- a/fs/hugetlbfs/inode.c +++ b/fs/hugetlbfs/inode.c | |||
@@ -72,8 +72,8 @@ huge_pages_needed(struct address_space *mapping, struct vm_area_struct *vma) | |||
72 | unsigned long start = vma->vm_start; | 72 | unsigned long start = vma->vm_start; |
73 | unsigned long end = vma->vm_end; | 73 | unsigned long end = vma->vm_end; |
74 | unsigned long hugepages = (end - start) >> HPAGE_SHIFT; | 74 | unsigned long hugepages = (end - start) >> HPAGE_SHIFT; |
75 | pgoff_t next = vma->vm_pgoff; | 75 | pgoff_t next = vma->vm_pgoff >> (HPAGE_SHIFT - PAGE_SHIFT); |
76 | pgoff_t endpg = next + ((end - start) >> PAGE_SHIFT); | 76 | pgoff_t endpg = next + hugepages; |
77 | 77 | ||
78 | pagevec_init(&pvec, 0); | 78 | pagevec_init(&pvec, 0); |
79 | while (next < endpg) { | 79 | while (next < endpg) { |