drivers: i2c: use CPU clock frequency in configuration on CC13XX/CC26XX
The I2C peripheral should be configured using the CPU clock frequency and not the system clock frequency. This used to be fine because they were the same before #19232, but now that the system clock is RTC-based (which has a different frequency), we can no longer make that assumption. Fixes #20480 Signed-off-by: Vincent Wan <vincent.wan@linaro.org>
This commit is contained in:
parent
d1d603afc3
commit
0297756342
1 changed files with 1 additions and 1 deletions
|
@ -248,7 +248,7 @@ static int i2c_cc13xx_cc26xx_configure(struct device *dev, u32_t dev_config)
|
|||
|
||||
/* Enables and configures I2C master */
|
||||
I2CMasterInitExpClk(get_dev_config(dev)->base,
|
||||
sys_clock_hw_cycles_per_sec(), fast);
|
||||
DT_CPU_CLOCK_FREQUENCY, fast);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue