diff options
author | Billy Tsai <billy_tsai@aspeedtech.com> | 2021-09-22 11:15:16 +0300 |
---|---|---|
committer | Jonathan Cameron <Jonathan.Cameron@huawei.com> | 2021-10-19 10:27:32 +0300 |
commit | 90f9647753de30708da3891296812c4ec97cb404 (patch) | |
tree | bea3a0ced27b5d2539213a29da57d03004b90610 /drivers/iio/accel/kxsd9.h | |
parent | 1b5ceb55fec2aac929672eb8e24f98a12a10f695 (diff) | |
download | linux-90f9647753de30708da3891296812c4ec97cb404.tar.xz |
iio: adc: aspeed: Fix the calculate error of clock.
The ADC clock formula is
ast2400/2500:
ADC clock period = PCLK * 2 * (ADC0C[31:17] + 1) * (ADC0C[9:0] + 1)
ast2600:
ADC clock period = PCLK * 2 * (ADC0C[15:0] + 1)
They all have one fixed divided 2 and the legacy driver didn't handle it.
This patch register the fixed factory clock device as the parent of ADC
clock scaler to fix this issue.
Signed-off-by: Billy Tsai <billy_tsai@aspeedtech.com>
Link: https://lore.kernel.org/r/20210922081520.30580-8-billy_tsai@aspeedtech.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'drivers/iio/accel/kxsd9.h')
0 files changed, 0 insertions, 0 deletions