Commit 3eb9a6b6 authored by Thomas Haller's avatar Thomas Haller Committed by Paolo Abeni
Browse files

mptcp: account memory allocation in mptcp_nl_cmd_add_addr() to user



Now that non-root users can configure MPTCP endpoints, account
the memory allocation to the user.

Signed-off-by: default avatarThomas Haller <thaller@redhat.com>
Reviewed-by: default avatarMat Martineau <mathew.j.martineau@linux.intel.com>
Signed-off-by: default avatarMatthieu Baerts <matthieu.baerts@tessares.net>
Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
parent d1569718
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1327,7 +1327,7 @@ static int mptcp_nl_cmd_add_addr(struct sk_buff *skb, struct genl_info *info)
		return -EINVAL;
	}

	entry = kmalloc(sizeof(*entry), GFP_KERNEL);
	entry = kmalloc(sizeof(*entry), GFP_KERNEL_ACCOUNT);
	if (!entry) {
		GENL_SET_ERR_MSG(info, "can't allocate addr");
		return -ENOMEM;