]> git.baikalelectronics.ru Git - kernel.git/commit
can: peak_pci: prevent use after free at netdev removal
authorStephane Grosjean <s.grosjean@peak-system.com>
Tue, 20 May 2014 09:38:56 +0000 (11:38 +0200)
committerMarc Kleine-Budde <mkl@pengutronix.de>
Wed, 21 May 2014 06:17:03 +0000 (08:17 +0200)
commit452c7e0512bb91317e1b2c7f7012fe318c1e496d
treebe02fbf4f83f6a1a9c89239951c6da0ba6720355
parentfd859e9c2dd36676a8b0a6bec372381ce002ecf3
can: peak_pci: prevent use after free at netdev removal

As remarked by Christopher R. Baker in his post at

http://marc.info/?l=linux-can&m=139707295706465&w=2

there's a possibility for an use after free condition at device removal.

This simplified patch introduces an additional variable to prevent the issue.
Thanks for catching this.

Cc: linux-stable <stable@vger.kernel.org>
Reported-by: Christopher R. Baker <cbaker@rec.ri.cmu.edu>
Signed-off-by: Stephane Grosjean <s.grosjean@peak-system.com>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
drivers/net/can/sja1000/peak_pci.c