diff options
author | Hugh Dickins <hugh@veritas.com> | 2006-10-28 13:38:41 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-10-28 14:30:53 -0400 |
commit | b9d7e6ae82da124dc9c579fe1061264ef2a69407 (patch) | |
tree | 868894a168bd7873232cada240acf88a252014cb /fs/hugetlbfs/inode.c | |
parent | 7b92aadfdae85ef837db343be38d4172115be72b (diff) |
[PATCH] hugetlb: fix size=4G parsing
On 32-bit machines, mount -t hugetlbfs -o size=4G gave a 0GB filesystem,
size=5G gave a 1GB filesystem etc: there's no point in masking size with
HPAGE_MASK just before shifting its lower bits away, and since HPAGE_MASK is a
UL, that removed all the higher bits of the unsigned long long size.
Signed-off-by: Hugh Dickins <hugh@veritas.com>
Cc: Adam Litke <agl@us.ibm.com>
Cc: David Gibson <david@gibson.dropbear.id.au>
Cc: "Chen, Kenneth W" <kenneth.w.chen@intel.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/hugetlbfs/inode.c')
-rw-r--r-- | fs/hugetlbfs/inode.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/fs/hugetlbfs/inode.c b/fs/hugetlbfs/inode.c index 4ee3f006b861..0b23b963bb44 100644 --- a/fs/hugetlbfs/inode.c +++ b/fs/hugetlbfs/inode.c | |||
@@ -624,7 +624,6 @@ hugetlbfs_parse_options(char *options, struct hugetlbfs_config *pconfig) | |||
624 | do_div(size, 100); | 624 | do_div(size, 100); |
625 | rest++; | 625 | rest++; |
626 | } | 626 | } |
627 | size &= HPAGE_MASK; | ||
628 | pconfig->nr_blocks = (size >> HPAGE_SHIFT); | 627 | pconfig->nr_blocks = (size >> HPAGE_SHIFT); |
629 | value = rest; | 628 | value = rest; |
630 | } else if (!strcmp(opt,"nr_inodes")) { | 629 | } else if (!strcmp(opt,"nr_inodes")) { |