Commit 20867abc authored by William Lee Irwin III's avatar William Lee Irwin III Committed by Linus Torvalds

[PATCH] hugetlb: initialize sb->s_maxbytes

hugetblfs appears not to support the creation of files larger than 2GB. 
hugetlbfs_vmtruncate() checks against the s_maxbytes member of the super
block and returns EFBIG if the requested file size is too large.
Signed-off-by: default avatarGuy Cardwell <gcardwel@motorola.com>
Signed-off-by: default avatarWilliam Irwin <wli@holomorphy.com>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent b959d48e
...@@ -651,6 +651,7 @@ hugetlbfs_fill_super(struct super_block *sb, void *data, int silent) ...@@ -651,6 +651,7 @@ hugetlbfs_fill_super(struct super_block *sb, void *data, int silent)
sbinfo->free_blocks = config.nr_blocks; sbinfo->free_blocks = config.nr_blocks;
sbinfo->max_inodes = config.nr_inodes; sbinfo->max_inodes = config.nr_inodes;
sbinfo->free_inodes = config.nr_inodes; sbinfo->free_inodes = config.nr_inodes;
sb->s_maxbytes = MAX_LFS_FILESIZE;
sb->s_blocksize = HPAGE_SIZE; sb->s_blocksize = HPAGE_SIZE;
sb->s_blocksize_bits = HPAGE_SHIFT; sb->s_blocksize_bits = HPAGE_SHIFT;
sb->s_magic = HUGETLBFS_MAGIC; sb->s_magic = HUGETLBFS_MAGIC;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment