Commit 736d7f1
committed
drivers: adc: ad7768: Fix DCLK divider register encoding
Fix off-by-one error in AD7768_INTERFACE_CFG_DCLK_DIV_MODE macro.
The macro was incorrectly calculating register values, causing wrong
DCLK division settings to be written to hardware.
Corrected mapping:
- Divide by 8 → 0 (bits 00)
- Divide by 4 → 1 (bits 01)
- Divide by 2 → 2 (bits 10)
- Divide by 1 → 3 (bits 11)
Fixes: 5f17a1b ("drivers: adc: ad7768: Update driver")
Signed-off-by: Antoniu Miclaus <[email protected]>1 parent 6dc4674 commit 736d7f1
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
102 | 102 | | |
103 | 103 | | |
104 | 104 | | |
105 | | - | |
| 105 | + | |
106 | 106 | | |
107 | 107 | | |
108 | 108 | | |
| |||
0 commit comments