diff options
author | David Howells <dhowells@redhat.com> | 2018-09-11 22:20:53 +0100 |
---|---|---|
committer | David Howells <dhowells@redhat.com> | 2018-09-11 22:20:53 +0100 |
commit | 307c6e5241b4b44076c016bc64d1748b93d1792b (patch) | |
tree | 6b60bd39e494ea09efdc54e57c4cad7dc80760ce /fs/openpromfs | |
parent | 11da3a7f84f19c26da6f86af878298694ede0804 (diff) | |
download | linux-next-307c6e5241b4b44076c016bc64d1748b93d1792b.tar.gz |
vfs: Require specification of size of mount data for internal mounts
Require specification of the size of the mount data passed to the VFS
mounting functions by internal mounts. The problem is that the legacy
handling for the upcoming mount-context patches has to copy an entire page
as that's how big the buffer is defined as being, but some of the internal
calls pass in a short bit of stack space, with the result that the stack
guard page may get hit.
Signed-off-by: David Howells <dhowells@redhat.com>
Diffstat (limited to 'fs/openpromfs')
-rw-r--r-- | fs/openpromfs/inode.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/fs/openpromfs/inode.c b/fs/openpromfs/inode.c index 607092f367ad..e11c042b4766 100644 --- a/fs/openpromfs/inode.c +++ b/fs/openpromfs/inode.c @@ -365,7 +365,8 @@ static struct inode *openprom_iget(struct super_block *sb, ino_t ino) return inode; } -static int openprom_remount(struct super_block *sb, int *flags, char *data) +static int openprom_remount(struct super_block *sb, int *flags, + char *data, size_t data_size) { sync_filesystem(sb); *flags |= SB_NOATIME; @@ -379,7 +380,8 @@ static const struct super_operations openprom_sops = { .remount_fs = openprom_remount, }; -static int openprom_fill_super(struct super_block *s, void *data, int silent) +static int openprom_fill_super(struct super_block *s, + void *data, size_t data_size, int silent) { struct inode *root_inode; struct op_inode_info *oi; @@ -414,9 +416,10 @@ out_no_root: } static struct dentry *openprom_mount(struct file_system_type *fs_type, - int flags, const char *dev_name, void *data) + int flags, const char *dev_name, void *data, size_t data_size) { - return mount_single(fs_type, flags, data, openprom_fill_super); + return mount_single(fs_type, flags, data, data_size, + openprom_fill_super); } static struct file_system_type openprom_fs_type = { |