From: Olivier Sobrie Date: Fri, 18 Jan 2013 08:32:41 +0000 (+0100) Subject: can: pch_can: fix invalid error codes X-Git-Tag: firefly_0821_release~3680^2~1198^2~15 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=ee50e135aeb048b90fab662e661c58b67341830b;p=firefly-linux-kernel-4.4.55.git can: pch_can: fix invalid error codes Errors in CAN protocol (location) are reported in data[3] of the can frame instead of data[2]. Cc: linux-stable Signed-off-by: Olivier Sobrie Signed-off-by: Marc Kleine-Budde --- diff --git a/drivers/net/can/pch_can.c b/drivers/net/can/pch_can.c index 7d1748575b1f..5c314a961970 100644 --- a/drivers/net/can/pch_can.c +++ b/drivers/net/can/pch_can.c @@ -560,7 +560,7 @@ static void pch_can_error(struct net_device *ndev, u32 status) stats->rx_errors++; break; case PCH_CRC_ERR: - cf->data[2] |= CAN_ERR_PROT_LOC_CRC_SEQ | + cf->data[3] |= CAN_ERR_PROT_LOC_CRC_SEQ | CAN_ERR_PROT_LOC_CRC_DEL; priv->can.can_stats.bus_error++; stats->rx_errors++;