Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 817bedcd authored by Zhengchao Shao's avatar Zhengchao Shao Committed by Greg Kroah-Hartman
Browse files

bonding: remove print in bond_verify_device_path

commit 486058f42a4728053ae69ebbf78e9731d8ce6f8b upstream.

As suggested by Paolo in link[1], if the memory allocation fails, the mm
layer will emit a lot warning comprising the backtrace, so remove the
print.

[1] https://lore.kernel.org/all/20231118081653.1481260-1-shaozhengchao@huawei.com/



Suggested-by: default avatarPaolo Abeni <pabeni@redhat.com>
Signed-off-by: default avatarZhengchao Shao <shaozhengchao@huawei.com>
Reviewed-by: default avatarHangbin Liu <liuhangbin@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent e9512069
Loading
Loading
Loading
Loading
+1 −4
Original line number Diff line number Diff line
@@ -2482,11 +2482,8 @@ struct bond_vlan_tag *bond_verify_device_path(struct net_device *start_dev,

	if (start_dev == end_dev) {
		tags = kcalloc(level + 1, sizeof(*tags), GFP_ATOMIC);
		if (!tags) {
			net_err_ratelimited("%s: %s: Failed to allocate tags\n",
					    __func__, start_dev->name);
		if (!tags)
			return ERR_PTR(-ENOMEM);
		}
		tags[level].vlan_proto = VLAN_N_VID;
		return tags;
	}