Commit ab43108d authored by Colin Ian King's avatar Colin Ian King Committed by Linus Walleij

drm/mcde: fix masking and bitwise-or on variable val

The masking of val with ~MCDE_CRX1_CLKSEL_MASK is currently being
ignored because there seems to be a missing bitwise-or of val in the
following statement.  Fix this by replacing the assignment of val
with a bitwise-or.

Fixes: d795fd32 ("drm/mcde: Support DPI output")
Signed-off-by: default avatarColin Ian King <colin.king@canonical.com>
Addresses-Coverity: ("Unused valued")
Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20201124121528.395681-1-colin.king@canonical.com
parent bf897583
...@@ -738,7 +738,7 @@ static void mcde_configure_fifo(struct mcde *mcde, enum mcde_fifo fifo, ...@@ -738,7 +738,7 @@ static void mcde_configure_fifo(struct mcde *mcde, enum mcde_fifo fifo,
} else { } else {
/* Use the MCDE clock for DSI */ /* Use the MCDE clock for DSI */
val &= ~MCDE_CRX1_CLKSEL_MASK; val &= ~MCDE_CRX1_CLKSEL_MASK;
val = MCDE_CRX1_CLKSEL_MCDECLK << MCDE_CRX1_CLKSEL_SHIFT; val |= MCDE_CRX1_CLKSEL_MCDECLK << MCDE_CRX1_CLKSEL_SHIFT;
} }
writel(val, mcde->regs + cr1); writel(val, mcde->regs + cr1);
spin_unlock(&mcde->fifo_crx1_lock); spin_unlock(&mcde->fifo_crx1_lock);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment