Commit 333f3460f855abd02c7e7eefcb692740ecd9c662
1 parent
1be244a840
Exists in
v3.2_SMARCT335xPSP_04.06.00.11
and in
3 other branches
MFD: ti_tscadc: ADC Clock check not required
ADC is ideally expected to work at a frequency of 3MHz. The present code had a check, which returned error if the frequency went below the threshold value. But since AM335x supports various working frequencies, this check is not required. Now the code just uses the internal ADC clock divider to set the ADC frequency w.r.t the sys clock. Signed-off-by: Patil, Rachna <rachna@ti.com>
Showing 2 changed files with 0 additions and 6 deletions Side-by-side Diff
drivers/mfd/ti_tscadc.c
... | ... | @@ -131,11 +131,6 @@ |
131 | 131 | clock_rate = clk_get_rate(clk); |
132 | 132 | clk_put(clk); |
133 | 133 | clk_value = clock_rate / ADC_CLK; |
134 | - if (clk_value < MAX_CLK_DIV) { | |
135 | - dev_err(&pdev->dev, "clock input less than min clock requirement\n"); | |
136 | - err = -EINVAL; | |
137 | - goto err_fail; | |
138 | - } | |
139 | 134 | /* TSCADC_CLKDIV needs to be configured to the value minus 1 */ |
140 | 135 | clk_value = clk_value - 1; |
141 | 136 | tscadc_writel(tscadc, TSCADC_REG_CLKDIV, clk_value); |