]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
imx8mq: fix SSCG_PLL_REFCLK_SEL_x
authorPeng Fan <peng.fan@nxp.com>
Wed, 16 Sep 2020 07:17:20 +0000 (15:17 +0800)
committerStefano Babic <sbabic@denx.de>
Thu, 17 Sep 2020 12:40:10 +0000 (14:40 +0200)
Fix SSCG_PLL_REFCLK_SEL_x, the offset starts from 0, not 16

Reported-by: Coverity 3448860
Signed-off-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Ye Li <ye.li@nxp.com>
arch/arm/include/asm/arch-imx8m/clock_imx8mq.h

index 7109d334fa8b963a1c3b6c8b534c26c5d47651d9..340a61e55bd19195b9454770222fd56e15500b51 100644 (file)
@@ -358,10 +358,10 @@ enum clk_src_index {
 #define SSCG_PLL_LOCK_SEL_MASK         BIT(3)
 #define SSCG_PLL_COUNTCLK_SEL_MASK     BIT(2)
 #define SSCG_PLL_REFCLK_SEL_MASK       0x3
-#define SSCG_PLL_REFCLK_SEL_OSC_25M    (0 << 16)
-#define SSCG_PLL_REFCLK_SEL_OSC_27M    BIT(16)
-#define SSCG_PLL_REFCLK_SEL_HDMI_PHY_27M (2 << 16)
-#define SSCG_PLL_REFCLK_SEL_CLK_PN     (3 << 16)
+#define SSCG_PLL_REFCLK_SEL_OSC_25M    (0)
+#define SSCG_PLL_REFCLK_SEL_OSC_27M    (1)
+#define SSCG_PLL_REFCLK_SEL_HDMI_PHY_27M (2)
+#define SSCG_PLL_REFCLK_SEL_CLK_PN     (3)
 
 #define SSCG_PLL_SSDS_MASK             BIT(8)
 #define SSCG_PLL_SSMD_MASK             (0x7 << 5)