Re: [PATCH v3 3/6] staging:iio:ad2s90: Remove always overwritten assignment

2018-11-04 Thread Jonathan Cameron
On Sat,  3 Nov 2018 19:49:45 -0300
Matheus Tavares  wrote:

> This patch removes an initial assignment to the variable ret at probe,
> that was always overwritten.
> 
> Signed-off-by: Matheus Tavares 
Applied to the togreg branch of iio.git and pushed out as testing to
see if we are both wrong and there is something wrong with it that
build tests and static analysers can find!

Thanks,

Jonathan

> ---
>  drivers/staging/iio/resolver/ad2s90.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/staging/iio/resolver/ad2s90.c 
> b/drivers/staging/iio/resolver/ad2s90.c
> index 4908c8a95fad..54ad85bd9dc6 100644
> --- a/drivers/staging/iio/resolver/ad2s90.c
> +++ b/drivers/staging/iio/resolver/ad2s90.c
> @@ -62,7 +62,7 @@ static int ad2s90_probe(struct spi_device *spi)
>  {
>   struct iio_dev *indio_dev;
>   struct ad2s90_state *st;
> - int ret = 0;
> + int ret;
>  
>   indio_dev = devm_iio_device_alloc(>dev, sizeof(*st));
>   if (!indio_dev)



Re: [PATCH v3 3/6] staging:iio:ad2s90: Remove always overwritten assignment

2018-11-04 Thread Jonathan Cameron
On Sat,  3 Nov 2018 19:49:45 -0300
Matheus Tavares  wrote:

> This patch removes an initial assignment to the variable ret at probe,
> that was always overwritten.
> 
> Signed-off-by: Matheus Tavares 
Applied to the togreg branch of iio.git and pushed out as testing to
see if we are both wrong and there is something wrong with it that
build tests and static analysers can find!

Thanks,

Jonathan

> ---
>  drivers/staging/iio/resolver/ad2s90.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/staging/iio/resolver/ad2s90.c 
> b/drivers/staging/iio/resolver/ad2s90.c
> index 4908c8a95fad..54ad85bd9dc6 100644
> --- a/drivers/staging/iio/resolver/ad2s90.c
> +++ b/drivers/staging/iio/resolver/ad2s90.c
> @@ -62,7 +62,7 @@ static int ad2s90_probe(struct spi_device *spi)
>  {
>   struct iio_dev *indio_dev;
>   struct ad2s90_state *st;
> - int ret = 0;
> + int ret;
>  
>   indio_dev = devm_iio_device_alloc(>dev, sizeof(*st));
>   if (!indio_dev)



[PATCH v3 3/6] staging:iio:ad2s90: Remove always overwritten assignment

2018-11-03 Thread Matheus Tavares
This patch removes an initial assignment to the variable ret at probe,
that was always overwritten.

Signed-off-by: Matheus Tavares 
---
 drivers/staging/iio/resolver/ad2s90.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/iio/resolver/ad2s90.c 
b/drivers/staging/iio/resolver/ad2s90.c
index 4908c8a95fad..54ad85bd9dc6 100644
--- a/drivers/staging/iio/resolver/ad2s90.c
+++ b/drivers/staging/iio/resolver/ad2s90.c
@@ -62,7 +62,7 @@ static int ad2s90_probe(struct spi_device *spi)
 {
struct iio_dev *indio_dev;
struct ad2s90_state *st;
-   int ret = 0;
+   int ret;
 
indio_dev = devm_iio_device_alloc(>dev, sizeof(*st));
if (!indio_dev)
-- 
2.18.0



[PATCH v3 3/6] staging:iio:ad2s90: Remove always overwritten assignment

2018-11-03 Thread Matheus Tavares
This patch removes an initial assignment to the variable ret at probe,
that was always overwritten.

Signed-off-by: Matheus Tavares 
---
 drivers/staging/iio/resolver/ad2s90.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/iio/resolver/ad2s90.c 
b/drivers/staging/iio/resolver/ad2s90.c
index 4908c8a95fad..54ad85bd9dc6 100644
--- a/drivers/staging/iio/resolver/ad2s90.c
+++ b/drivers/staging/iio/resolver/ad2s90.c
@@ -62,7 +62,7 @@ static int ad2s90_probe(struct spi_device *spi)
 {
struct iio_dev *indio_dev;
struct ad2s90_state *st;
-   int ret = 0;
+   int ret;
 
indio_dev = devm_iio_device_alloc(>dev, sizeof(*st));
if (!indio_dev)
-- 
2.18.0