aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/net/batman-adv/network-coding.c
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2021-11-12 09:22:28 +1000
committerDave Airlie <airlied@redhat.com>2021-11-12 09:23:16 +1000
commit447212bb4f8ebd7d95dd6e160cd82c69c9a23c4c (patch)
tree7f60893fe3757c5ac2077809e0f8764bd3944748 /net/batman-adv/network-coding.c
parentMerge tag 'amd-drm-fixes-5.16-2021-11-10' of https://gitlab.freedesktop.org/agd5f/linux into drm-next (diff)
parentLinux 5.15 (diff)
downloadwireguard-linux-447212bb4f8ebd7d95dd6e160cd82c69c9a23c4c.tar.xz
wireguard-linux-447212bb4f8ebd7d95dd6e160cd82c69c9a23c4c.zip
BackMerge tag 'v5.15' into drm-next
I got a drm-fixes which had some 5.15 stuff in it, so to avoid the mess just backmerge here. Linux 5.15 Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'net/batman-adv/network-coding.c')
-rw-r--r--net/batman-adv/network-coding.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/net/batman-adv/network-coding.c b/net/batman-adv/network-coding.c
index 9f06132e007d..0a7f1d36a6a8 100644
--- a/net/batman-adv/network-coding.c
+++ b/net/batman-adv/network-coding.c
@@ -152,8 +152,10 @@ int batadv_nc_mesh_init(struct batadv_priv *bat_priv)
&batadv_nc_coding_hash_lock_class_key);
bat_priv->nc.decoding_hash = batadv_hash_new(128);
- if (!bat_priv->nc.decoding_hash)
+ if (!bat_priv->nc.decoding_hash) {
+ batadv_hash_destroy(bat_priv->nc.coding_hash);
goto err;
+ }
batadv_hash_set_lock_class(bat_priv->nc.decoding_hash,
&batadv_nc_decoding_hash_lock_class_key);