mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
Merge branch 'bugfix/fix_overflow_in_apll_calculation' into 'master'
fix(apll): fixed overflow in apll calculation See merge request espressif/esp-idf!26389
This commit is contained in:
commit
2da28270bf
@ -96,7 +96,7 @@ uint32_t clk_hal_xtal_get_freq_mhz(void)
|
||||
|
||||
uint32_t clk_hal_apll_get_freq_hz(void)
|
||||
{
|
||||
uint64_t xtal_freq_hz = clk_hal_xtal_get_freq_mhz() * MHZ ;
|
||||
uint64_t xtal_freq_hz = (uint64_t)clk_hal_xtal_get_freq_mhz() * 1000000ULL;
|
||||
uint32_t o_div = 0;
|
||||
uint32_t sdm0 = 0;
|
||||
uint32_t sdm1 = 0;
|
||||
|
@ -100,7 +100,7 @@ uint32_t clk_hal_xtal_get_freq_mhz(void)
|
||||
|
||||
uint32_t clk_hal_apll_get_freq_hz(void)
|
||||
{
|
||||
uint64_t xtal_freq_hz = clk_hal_xtal_get_freq_mhz() * MHZ ;
|
||||
uint64_t xtal_freq_hz = (uint64_t)clk_hal_xtal_get_freq_mhz() * 1000000ULL;
|
||||
uint32_t o_div = 0;
|
||||
uint32_t sdm0 = 0;
|
||||
uint32_t sdm1 = 0;
|
||||
|
Loading…
x
Reference in New Issue
Block a user