diff options
author | Paul Cercueil <[email protected]> | 2023-03-30 12:21:00 +0200 |
---|---|---|
committer | Jonathan Cameron <[email protected]> | 2023-05-13 17:54:57 +0100 |
commit | e55245d115bb9054cb72cdd5dda5660f4484873a (patch) | |
tree | fdfc022d0faa5e5618e59808eeaf33eeba2d6bae /lib/mpi/mpiutil.c | |
parent | 79b8ded9d9c595db9bd5b2f62f5f738b36de1e22 (diff) |
iio: adc: ad7192: Change "shorted" channels to differential
The AD7192 provides a specific channel configuration where both negative
and positive inputs are connected to AIN2. This was represented in the
ad7192 driver as a IIO channel with .channel = 2 and .extended_name set
to "shorted".
The problem with this approach, is that the driver provided two IIO
channels with the identifier .channel = 2; one "shorted" and the other
not. This goes against the IIO ABI, as a channel identifier should be
unique.
Address this issue by changing "shorted" channels to being differential
instead, with channel 2 vs. itself, as we're actually measuring AIN2 vs.
itself.
Note that the fix tag is for the commit that moved the driver out of
staging. The bug existed before that, but backporting would become very
complex further down and unlikely to happen.
Fixes: b581f748cce0 ("staging: iio: adc: ad7192: move out of staging")
Signed-off-by: Paul Cercueil <[email protected]>
Co-developed-by: Alisa Roman <[email protected]>
Signed-off-by: Alisa Roman <[email protected]>
Reviewed-by: Nuno Sa <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Cc: <[email protected]>
Signed-off-by: Jonathan Cameron <[email protected]>
Diffstat (limited to 'lib/mpi/mpiutil.c')
0 files changed, 0 insertions, 0 deletions