Commit 008cfbaa authored by Wei Yongjun's avatar Wei Yongjun Committed by David S. Miller

net: dsa: sja1105: Fix missing unlock on error in sk_buff()

Add the missing unlock before return from function sk_buff()
in the error handling case.

Fixes: f3097be2 ("net: dsa: sja1105: Add a state machine for RX timestamping")
Signed-off-by: default avatarWei Yongjun <weiyongjun1@huawei.com>
Reviewed-by: default avatarVladimir Oltean <olteanv@gmail.com>
Reviewed-by: default avatarVivien Didelot <vivien.didelot@gmail.com>
Reviewed-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 8ec1e900
...@@ -216,6 +216,7 @@ static struct sk_buff ...@@ -216,6 +216,7 @@ static struct sk_buff
if (!skb) { if (!skb) {
dev_err_ratelimited(dp->ds->dev, dev_err_ratelimited(dp->ds->dev,
"Failed to copy stampable skb\n"); "Failed to copy stampable skb\n");
spin_unlock(&sp->data->meta_lock);
return NULL; return NULL;
} }
sja1105_transfer_meta(skb, meta); sja1105_transfer_meta(skb, meta);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment