Skip to content

Commit 49012d1

Browse files
Boris Brezillonbebarino
authored andcommitted
clk: bcm2835: Fix ana->maskX definitions
ana->maskX values are already '~'-ed in bcm2835_pll_set_rate(). Remove the '~' in the definition to fix ANA setup. Note that this commit fixes a long standing bug preventing one from using an HDMI display if it's plugged after the FW has booted Linux. This is because PLLH is used by the HDMI encoder to generate the pixel clock. Fixes: 41691b8 ("clk: bcm2835: Add support for programming the audio domain clocks") Cc: <[email protected]> Signed-off-by: Boris Brezillon <[email protected]> Reviewed-by: Eric Anholt <[email protected]> Signed-off-by: Stephen Boyd <[email protected]>
1 parent 8a53fc5 commit 49012d1

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

drivers/clk/bcm/clk-bcm2835.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -449,17 +449,17 @@ struct bcm2835_pll_ana_bits {
449449
static const struct bcm2835_pll_ana_bits bcm2835_ana_default = {
450450
.mask0 = 0,
451451
.set0 = 0,
452-
.mask1 = (u32)~(A2W_PLL_KI_MASK | A2W_PLL_KP_MASK),
452+
.mask1 = A2W_PLL_KI_MASK | A2W_PLL_KP_MASK,
453453
.set1 = (2 << A2W_PLL_KI_SHIFT) | (8 << A2W_PLL_KP_SHIFT),
454-
.mask3 = (u32)~A2W_PLL_KA_MASK,
454+
.mask3 = A2W_PLL_KA_MASK,
455455
.set3 = (2 << A2W_PLL_KA_SHIFT),
456456
.fb_prediv_mask = BIT(14),
457457
};
458458

459459
static const struct bcm2835_pll_ana_bits bcm2835_ana_pllh = {
460-
.mask0 = (u32)~(A2W_PLLH_KA_MASK | A2W_PLLH_KI_LOW_MASK),
460+
.mask0 = A2W_PLLH_KA_MASK | A2W_PLLH_KI_LOW_MASK,
461461
.set0 = (2 << A2W_PLLH_KA_SHIFT) | (2 << A2W_PLLH_KI_LOW_SHIFT),
462-
.mask1 = (u32)~(A2W_PLLH_KI_HIGH_MASK | A2W_PLLH_KP_MASK),
462+
.mask1 = A2W_PLLH_KI_HIGH_MASK | A2W_PLLH_KP_MASK,
463463
.set1 = (6 << A2W_PLLH_KP_SHIFT),
464464
.mask3 = 0,
465465
.set3 = 0,

0 commit comments

Comments
 (0)