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

Commit 8220ce6d authored by David S. Miller's avatar David S. Miller
Browse files

Merge tag 'linux-can-fixes-for-4.16-20180319' of...

Merge tag 'linux-can-fixes-for-4.16-20180319' of ssh://gitolite.kernel.org/pub/scm/linux/kernel/git/mkl/linux-can



Marc Kleine-Budde says:

====================
pull-request: can 2018-03-19

this is a pull reqeust of one patch for net/master.

The patch is by Andri Yngvason and fixes a potential use-after-free bug
in the cc770 driver introduced in the previous pull-request.
====================

Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parents 44caebd3 9ffd7503
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -706,13 +706,12 @@ static void cc770_tx_interrupt(struct net_device *dev, unsigned int o)
		return;
	}

	can_put_echo_skb(priv->tx_skb, dev, 0);
	can_get_echo_skb(dev, 0);

	cf = (struct can_frame *)priv->tx_skb->data;
	stats->tx_bytes += cf->can_dlc;
	stats->tx_packets++;

	can_put_echo_skb(priv->tx_skb, dev, 0);
	can_get_echo_skb(dev, 0);
	priv->tx_skb = NULL;

	netif_wake_queue(dev);