Skip to content

Commit

Permalink
can: flexcan: flexcan_chip_start(): adjust comment to match the code
Browse files Browse the repository at this point in the history
With the conversion of the flexcan driver to support both timestamp and
FIFO mode the setup of the MCR register ("enable fifo") has been moved.

This patch moves the comment too, in order to match the code again.

Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
  • Loading branch information
Marc Kleine-Budde committed Nov 28, 2018
1 parent 22233f7 commit c982a3c
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion drivers/net/can/flexcan.c
Original file line number Diff line number Diff line change
Expand Up @@ -935,7 +935,6 @@ static int flexcan_chip_start(struct net_device *dev)
/* MCR
*
* enable freeze
* enable fifo
* halt now
* only supervisor access
* enable warning int
Expand All @@ -950,6 +949,12 @@ static int flexcan_chip_start(struct net_device *dev)
FLEXCAN_MCR_WRN_EN | FLEXCAN_MCR_SRX_DIS | FLEXCAN_MCR_IRMQ |
FLEXCAN_MCR_IDAM_C | FLEXCAN_MCR_MAXMB(FLEXCAN_TX_MB);

/* MCR
*
* FIFO:
* - disable for timestamp mode
* - enable for FIFO mode
*/
if (priv->devtype_data->quirks & FLEXCAN_QUIRK_USE_OFF_TIMESTAMP)
reg_mcr &= ~FLEXCAN_MCR_FEN;
else
Expand Down

0 comments on commit c982a3c

Please sign in to comment.