]> git.baikalelectronics.ru Git - kernel.git/commit
cifs: move file_lock off stack in cifs_push_posix_locks
authorJeff Layton <jlayton@redhat.com>
Mon, 23 Jul 2012 17:28:37 +0000 (13:28 -0400)
committerSteve French <smfrench@gmail.com>
Mon, 23 Jul 2012 21:36:29 +0000 (16:36 -0500)
commit5e9893c9cba4ffd3676786939260c2766f25f8e4
tree338135e4be3a6f12a7c1350655cfc48b1db52457
parent65a4ce37906d7ca50127640eb0ba3b0a63611b0f
cifs: move file_lock off stack in cifs_push_posix_locks

struct file_lock is pretty large, so we really don't want that on the
stack in a potentially long call chain. Reorganize the arguments to
CIFSSMBPosixLock to eliminate the need for that.

Eliminate the get_flag and simply use a non-NULL pLockInfo to indicate
that this is a "get" operation. In order to do that, need to add a new
loff_t argument for the start_offset.

Reported-by: Al Viro <viro@ZenIV.linux.org.uk>
Signed-off-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Steve French <smfrench@gmail.com>
fs/cifs/cifsproto.h
fs/cifs/cifssmb.c
fs/cifs/file.c