mirror of
https://github.com/enjoy-digital/litex.git
synced 2025-01-04 09:52:26 -05:00
software/liblitespi/spiflash: fix reported flash clk
This commit is contained in:
parent
51c3cb3552
commit
e0416639f7
1 changed files with 2 additions and 2 deletions
|
@ -46,13 +46,13 @@ int spiflash_freq_init(void)
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
lowest_div++;
|
lowest_div++;
|
||||||
printf("SPI Flash clk configured to %d MHz\n", (SPIFLASH_PHY_FREQUENCY/(2*(1 + lowest_div)))/1000000);
|
printf("SPI Flash clk configured to %d MHz\n", CONFIG_CLOCK_FREQUENCY/(2*(1+lowest_div)*1000000));
|
||||||
|
|
||||||
spiflash_phy_clk_divisor_write(lowest_div);
|
spiflash_phy_clk_divisor_write(lowest_div);
|
||||||
|
|
||||||
#else
|
#else
|
||||||
|
|
||||||
printf("SPI Flash clk configured to %ld MHz\n", (unsigned long)(SPIFLASH_PHY_FREQUENCY/1e6));
|
printf("SPI Flash clk configured to %ld MHz\n", SPIFLASH_PHY_FREQUENCY/1000000);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue