Commit 8e13b1b4 authored by Fredric Cover's avatar Fredric Cover Committed by Steve French
Browse files

smb: client: change allocation requirements in smb2_compound_op



Currently, smb2_compound_op() allocates
struct smb2_compound_vars *vars using GFP_ATOMIC, although
smb2_compound_op() can sleep when it calls compound_send_recv()
before vars is freed.

Allocate vars using GFP_KERNEL.

Signed-off-by: default avatarFredric Cover <fredric.cover.lkernel@gmail.com>
Signed-off-by: default avatarSteve French <stfrench@microsoft.com>
parent 0cbc3002
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -230,7 +230,7 @@ static int smb2_compound_op(const unsigned int xid, struct cifs_tcon *tcon,
	num_rqst = 0;
	server = cifs_pick_channel(ses);

	vars = kzalloc_obj(*vars, GFP_ATOMIC);
	vars = kzalloc_obj(*vars, GFP_KERNEL);
	if (vars == NULL) {
		rc = -ENOMEM;
		goto out;