can: flexcan: fix shutdown: first disable chip, then all interrupts
authorMarc Kleine-Budde <mkl@pengutronix.de>
Wed, 19 Feb 2014 11:00:51 +0000 (12:00 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 24 Mar 2014 04:44:17 +0000 (21:44 -0700)
commit76c32c08c7449cb471cb6d0e2f67d3c9b06f9cad
tree6e0a729e14edf322168163eb265a228685868fa4
parent5332f853b4a8d387e4d10c37f7ccce86f49dca38
can: flexcan: fix shutdown: first disable chip, then all interrupts

commit 5be93bdda64e85450598c6e97f79fb8f6acf30e0 upstream.

When shutting down the CAN interface (ifconfig canX down) during high CAN bus
loads, the CAN core might hang and freeze the whole CPU.

This patch fixes the shutdown sequence by first disabling the CAN core then
disabling all interrupts.

Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/can/flexcan.c