Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

clk: at91: utmi: use pmc_read when the at91_pmc is available

at91_pmc_read is a workaround to allow external drivers to acces some
registers of the PMC. There is no need for it in clk-utmi.c as we aready
have a pointer to the struct at91_pmc.

Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
Acked-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>

authored by

Alexandre Belloni and committed by
Stephen Boyd
de661d00 8ee9c7de

+2 -2
+2 -2
drivers/clk/at91/clk-utmi.c
··· 47 47 { 48 48 struct clk_utmi *utmi = to_clk_utmi(hw); 49 49 struct at91_pmc *pmc = utmi->pmc; 50 - u32 tmp = at91_pmc_read(AT91_CKGR_UCKR) | AT91_PMC_UPLLEN | 50 + u32 tmp = pmc_read(pmc, AT91_CKGR_UCKR) | AT91_PMC_UPLLEN | 51 51 AT91_PMC_UPLLCOUNT | AT91_PMC_BIASEN; 52 52 53 53 pmc_write(pmc, AT91_CKGR_UCKR, tmp); ··· 73 73 { 74 74 struct clk_utmi *utmi = to_clk_utmi(hw); 75 75 struct at91_pmc *pmc = utmi->pmc; 76 - u32 tmp = at91_pmc_read(AT91_CKGR_UCKR) & ~AT91_PMC_UPLLEN; 76 + u32 tmp = pmc_read(pmc, AT91_CKGR_UCKR) & ~AT91_PMC_UPLLEN; 77 77 78 78 pmc_write(pmc, AT91_CKGR_UCKR, tmp); 79 79 }