diff options
author | Maxim Patlasov <mpatlasov@parallels.com> | 2012-10-26 11:49:13 -0400 |
---|---|---|
committer | Miklos Szeredi <mszeredi@suse.cz> | 2013-01-24 10:21:26 -0500 |
commit | 54b966702dafe396b6f4e609f222b8e0fdb4d7a4 (patch) | |
tree | 93f3188bd4c4cf1efc789db244819c8103342436 /fs/fuse | |
parent | d07f09f509fb21482096e1975f160b694c0edf84 (diff) |
fuse: rework fuse_do_ioctl()
fuse_do_ioctl() already calculates the number of pages it's going to use. It is
stored in 'num_pages' variable. So the patch simply uses it for allocating
fuse_req.
Signed-off-by: Maxim Patlasov <mpatlasov@parallels.com>
Signed-off-by: Miklos Szeredi <mszeredi@suse.cz>
Diffstat (limited to 'fs/fuse')
-rw-r--r-- | fs/fuse/file.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/fuse/file.c b/fs/fuse/file.c index b9972502f43a..fdb5b33198aa 100644 --- a/fs/fuse/file.c +++ b/fs/fuse/file.c | |||
@@ -1894,7 +1894,7 @@ long fuse_do_ioctl(struct file *file, unsigned int cmd, unsigned long arg, | |||
1894 | num_pages++; | 1894 | num_pages++; |
1895 | } | 1895 | } |
1896 | 1896 | ||
1897 | req = fuse_get_req(fc, FUSE_MAX_PAGES_PER_REQ); | 1897 | req = fuse_get_req(fc, num_pages); |
1898 | if (IS_ERR(req)) { | 1898 | if (IS_ERR(req)) { |
1899 | err = PTR_ERR(req); | 1899 | err = PTR_ERR(req); |
1900 | req = NULL; | 1900 | req = NULL; |