Skip to content

Commit 4ec2661

Browse files
mstumpf-vectedfabiobaltieri
authored andcommitted
drivers: cc: mcux: Fix incorrect clock source of FlexSPI2
The clock control mcux rev2 returns FlexSPI1 clock rate when FlexSPI2 clock rate is requested. Signed-off-by: Martin Stumpf <martin.stumpf@vected.de>
1 parent 8221a9a commit 4ec2661

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

drivers/clock_control/clock_control_mcux_ccm_rev2.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -198,10 +198,8 @@ static int mcux_ccm_get_subsys_rate(const struct device *dev,
198198

199199
#ifdef CONFIG_MEMC_MCUX_FLEXSPI
200200
case IMX_CCM_FLEXSPI_CLK:
201-
clock_root = kCLOCK_Root_Flexspi1;
202-
break;
203201
case IMX_CCM_FLEXSPI2_CLK:
204-
clock_root = kCLOCK_Root_Flexspi2;
202+
clock_root = kCLOCK_Root_Flexspi1 + instance;
205203
break;
206204
#endif
207205
#ifdef CONFIG_COUNTER_NXP_PIT

0 commit comments

Comments
 (0)