mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-05 02:21:52 +09:00
can: flexcan: Unlock the MB unconditionally
commit 5178b7cd8e upstream.
Unlock the MB irrespective of reception method being FIFO or timestamp
based. It is optional but recommended to unlock Mailbox as soon as
possible and make it available for reception.
Reported-by: Alexander Stein <alexander.stein@systec-electronic.com>
Signed-off-by: Pankaj Bansal <pankaj.bansal@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>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
09132a6b01
commit
8d2aed6439
@@ -720,9 +720,14 @@ static unsigned int flexcan_mailbox_read(struct can_rx_offload *offload,
|
||||
priv->write(BIT(n - 32), ®s->iflag2);
|
||||
} else {
|
||||
priv->write(FLEXCAN_IFLAG_RX_FIFO_AVAILABLE, ®s->iflag1);
|
||||
priv->read(®s->timer);
|
||||
}
|
||||
|
||||
/* Read the Free Running Timer. It is optional but recommended
|
||||
* to unlock Mailbox as soon as possible and make it available
|
||||
* for reception.
|
||||
*/
|
||||
priv->read(®s->timer);
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user