All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] staging: iio: resolver: ads1210: fix config mode
@ 2023-03-27 14:54 Nuno Sá
  2023-04-01 14:24 ` Jonathan Cameron
  0 siblings, 1 reply; 3+ messages in thread
From: Nuno Sá @ 2023-03-27 14:54 UTC (permalink / raw)
  To: linux-staging, linux-iio
  Cc: Michael Hennerich, Greg Kroah-Hartman, Lars-Peter Clausen,
	Jonathan Cameron

As stated in the device datasheet [1], bits a0 and a1 have to be set to
1 for the configuration mode.

[1]: https://www.analog.com/media/en/technical-documentation/data-sheets/ad2s1210.pdf

Fixes: b19e9ad5e2cb9 ("staging:iio:resolver:ad2s1210 general driver cleanup")
Signed-off-by: Nuno Sá <nuno.sa@analog.com>
---
 drivers/staging/iio/resolver/ad2s1210.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/iio/resolver/ad2s1210.c b/drivers/staging/iio/resolver/ad2s1210.c
index e4cf42438487..636c45b12843 100644
--- a/drivers/staging/iio/resolver/ad2s1210.c
+++ b/drivers/staging/iio/resolver/ad2s1210.c
@@ -101,7 +101,7 @@ struct ad2s1210_state {
 static const int ad2s1210_mode_vals[4][2] = {
 	[MOD_POS] = { 0, 0 },
 	[MOD_VEL] = { 0, 1 },
-	[MOD_CONFIG] = { 1, 0 },
+	[MOD_CONFIG] = { 1, 1 },
 };
 
 static inline void ad2s1210_set_mode(enum ad2s1210_mode mode,
-- 
2.40.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] staging: iio: resolver: ads1210: fix config mode
  2023-03-27 14:54 [PATCH] staging: iio: resolver: ads1210: fix config mode Nuno Sá
@ 2023-04-01 14:24 ` Jonathan Cameron
  2023-04-03  6:54   ` Nuno Sá
  0 siblings, 1 reply; 3+ messages in thread
From: Jonathan Cameron @ 2023-04-01 14:24 UTC (permalink / raw)
  To: Nuno Sá
  Cc: linux-staging, linux-iio, Michael Hennerich, Greg Kroah-Hartman,
	Lars-Peter Clausen

On Mon, 27 Mar 2023 16:54:14 +0200
Nuno Sá <nuno.sa@analog.com> wrote:

> As stated in the device datasheet [1], bits a0 and a1 have to be set to
> 1 for the configuration mode.
> 
> [1]: https://www.analog.com/media/en/technical-documentation/data-sheets/ad2s1210.pdf
> 
> Fixes: b19e9ad5e2cb9 ("staging:iio:resolver:ad2s1210 general driver cleanup")
> Signed-off-by: Nuno Sá <nuno.sa@analog.com>

Oops. Younger more foolish me bug (back in 2011 so I'll cut myself some slack)

Applied to the togreg branch of iio.git (not rushing something in that is in staging
and has been broken a while without anyone commenting!)

I don't suppose this means you are going to get this ready to move out of staging?
*looks hopeful*

Thanks,

Jonathan
 
> ---
>  drivers/staging/iio/resolver/ad2s1210.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/staging/iio/resolver/ad2s1210.c b/drivers/staging/iio/resolver/ad2s1210.c
> index e4cf42438487..636c45b12843 100644
> --- a/drivers/staging/iio/resolver/ad2s1210.c
> +++ b/drivers/staging/iio/resolver/ad2s1210.c
> @@ -101,7 +101,7 @@ struct ad2s1210_state {
>  static const int ad2s1210_mode_vals[4][2] = {
>  	[MOD_POS] = { 0, 0 },
>  	[MOD_VEL] = { 0, 1 },
> -	[MOD_CONFIG] = { 1, 0 },
> +	[MOD_CONFIG] = { 1, 1 },
>  };
>  
>  static inline void ad2s1210_set_mode(enum ad2s1210_mode mode,


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] staging: iio: resolver: ads1210: fix config mode
  2023-04-01 14:24 ` Jonathan Cameron
@ 2023-04-03  6:54   ` Nuno Sá
  0 siblings, 0 replies; 3+ messages in thread
From: Nuno Sá @ 2023-04-03  6:54 UTC (permalink / raw)
  To: Jonathan Cameron, Nuno Sá
  Cc: linux-staging, linux-iio, Michael Hennerich, Greg Kroah-Hartman,
	Lars-Peter Clausen

On Sat, 2023-04-01 at 15:24 +0100, Jonathan Cameron wrote:
> On Mon, 27 Mar 2023 16:54:14 +0200
> Nuno Sá <nuno.sa@analog.com> wrote:
> 
> > As stated in the device datasheet [1], bits a0 and a1 have to be
> > set to
> > 1 for the configuration mode.
> > 
> > [1]:
> > https://www.analog.com/media/en/technical-documentation/data-sheets/ad2s1210.pdf
> > 
> > Fixes: b19e9ad5e2cb9 ("staging:iio:resolver:ad2s1210 general driver
> > cleanup")
> > Signed-off-by: Nuno Sá <nuno.sa@analog.com>
> 
> Oops. Younger more foolish me bug (back in 2011 so I'll cut myself
> some slack)
> 
> Applied to the togreg branch of iio.git (not rushing something in
> that is in staging
> and has been broken a while without anyone commenting!)
> 
> I don't suppose this means you are going to get this ready to move
> out of staging?
> *looks hopeful*
> 

Eeheh, Unfortunately not on the top of my list right now... But, if I
happen to find some hardware hanging around, I might eventually get
into it.

Funny enough, this was actually reported to us in one of our support
channels which means there are people actually using the driver even
being it on staging.

- Nuno Sá



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2023-04-03  6:52 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-27 14:54 [PATCH] staging: iio: resolver: ads1210: fix config mode Nuno Sá
2023-04-01 14:24 ` Jonathan Cameron
2023-04-03  6:54   ` Nuno Sá

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.