Skip to content
Snippets Groups Projects
Commit 30f65c85 authored by Wenyou Yang's avatar Wenyou Yang Committed by Andreas Bießmann
Browse files

board: atmel: siemens: clean up PLLB code


Due to introducing the new PLLB clock handle functions,
use these functions to clean up the PLLB enable code.

Signed-off-by: default avatarWenyou Yang <wenyou.yang@atmel.com>
Reviewed-by: default avatarAndreas Bießmann <andreas.devel@googlemail.com>
Tested-by: default avatarHeiko Schocher <hs@denx.de>
parent 9cf7385c
No related branches found
No related tags found
No related merge requests found
...@@ -115,12 +115,8 @@ static void smartweb_macb_hw_init(void) ...@@ -115,12 +115,8 @@ static void smartweb_macb_hw_init(void)
void at91_udp_hw_init(void) void at91_udp_hw_init(void)
{ {
at91_pmc_t *pmc = (at91_pmc_t *)ATMEL_BASE_PMC;
/* Enable PLLB */ /* Enable PLLB */
writel(get_pllb_init(), &pmc->pllbr); at91_pllb_clk_enable(get_pllb_init());
while ((readl(&pmc->sr) & AT91_PMC_LOCKB) != AT91_PMC_LOCKB)
;
/* Enable UDPCK clock, MCK is enabled in at91_clock_init() */ /* Enable UDPCK clock, MCK is enabled in at91_clock_init() */
at91_periph_clk_enable(ATMEL_ID_UDP); at91_periph_clk_enable(ATMEL_ID_UDP);
......
...@@ -289,12 +289,8 @@ void spi_cs_deactivate(struct spi_slave *slave) ...@@ -289,12 +289,8 @@ void spi_cs_deactivate(struct spi_slave *slave)
void at91_udp_hw_init(void) void at91_udp_hw_init(void)
{ {
at91_pmc_t *pmc = (at91_pmc_t *)ATMEL_BASE_PMC;
/* Enable PLLB */ /* Enable PLLB */
writel(get_pllb_init(), &pmc->pllbr); at91_pllb_clk_enable(get_pllb_init());
while ((readl(&pmc->sr) & AT91_PMC_LOCKB) != AT91_PMC_LOCKB)
;
/* Enable UDPCK clock, MCK is enabled in at91_clock_init() */ /* Enable UDPCK clock, MCK is enabled in at91_clock_init() */
at91_periph_clk_enable(ATMEL_ID_UDP); at91_periph_clk_enable(ATMEL_ID_UDP);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment