Skip to content

Commit 246e1ec

Browse files
boards: nxp: mcx: update FlexCAN clock configuration
Update FlexCAN clock configuration across NXP MCXN family boards to use PLL0 as clock source with a divider of 3 instead of FRO_HF with divider of 1. The new configuration provides FlexCAN peripherals by using the PLL0 output (150MHz) divided by 3 to achieve 50MHz, replace previous 48MHz FRO_HF. Signed-off-by: William Tang <[email protected]>
1 parent 0521c57 commit 246e1ec

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

boards/nxp/frdm_mcxn236/board.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -211,8 +211,8 @@ void board_early_init_hook(void)
211211
#endif
212212

213213
#if DT_NODE_HAS_STATUS_OKAY(DT_NODELABEL(flexcan1))
214-
CLOCK_SetClkDiv(kCLOCK_DivFlexcan1Clk, 1U);
215-
CLOCK_AttachClk(kFRO_HF_to_FLEXCAN1);
214+
CLOCK_SetClkDiv(kCLOCK_DivFlexcan1Clk, 3U);
215+
CLOCK_AttachClk(kPLL0_to_FLEXCAN1);
216216
#endif
217217

218218
#if DT_NODE_HAS_STATUS_OKAY(DT_NODELABEL(vref))

boards/nxp/frdm_mcxn947/board.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -291,8 +291,8 @@ void board_early_init_hook(void)
291291
#endif
292292

293293
#if DT_NODE_HAS_STATUS_OKAY(DT_NODELABEL(flexcan0))
294-
CLOCK_SetClkDiv(kCLOCK_DivFlexcan0Clk, 1U);
295-
CLOCK_AttachClk(kFRO_HF_to_FLEXCAN0);
294+
CLOCK_SetClkDiv(kCLOCK_DivFlexcan0Clk, 3U);
295+
CLOCK_AttachClk(kPLL0_to_FLEXCAN0);
296296
#endif
297297

298298
#if DT_NODE_HAS_STATUS_OKAY(DT_NODELABEL(usdhc0))

boards/nxp/mcx_nx4x_evk/board.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -286,8 +286,8 @@ void board_early_init_hook(void)
286286
#endif
287287

288288
#if DT_NODE_HAS_STATUS_OKAY(DT_NODELABEL(flexcan0))
289-
CLOCK_SetClkDiv(kCLOCK_DivFlexcan0Clk, 1U);
290-
CLOCK_AttachClk(kFRO_HF_to_FLEXCAN0);
289+
CLOCK_SetClkDiv(kCLOCK_DivFlexcan0Clk, 3U);
290+
CLOCK_AttachClk(kPLL0_to_FLEXCAN0);
291291
#endif
292292

293293
#if DT_NODE_HAS_STATUS_OKAY(DT_NODELABEL(usdhc0))

0 commit comments

Comments
 (0)