can: flexcan: disable completely the ECC mechanism
authorJoakim Zhang <qiangqing.zhang@nxp.com>
Thu, 15 Aug 2019 08:00:26 +0000 (08:00 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 12 Nov 2019 18:20:43 +0000 (19:20 +0100)
commit0327c7818da27b018464c0b9f541c5d276c57172
treec71fcee7f492f3fcf82126d3eabdedb8468dc21c
parent46265660e5baea9d2120c55a887f89835c43b717
can: flexcan: disable completely the ECC mechanism

commit 5e269324db5adb2f5f6ec9a93a9c7b0672932b47 upstream.

The ECC (memory error detection and correction) mechanism can be
activated or not, controlled by the ECCDIS bit in CAN_MECR. When
disabled, updates on indications and reporting registers are stopped.
So if want to disable ECC completely, had better assert ECCDIS bit, not
just mask the related interrupts.

Fixes: cdce844865be ("can: flexcan: add vf610 support for FlexCAN")
Signed-off-by: Joakim Zhang <qiangqing.zhang@nxp.com>
Cc: linux-stable <stable@vger.kernel.org>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/can/flexcan.c