All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] spi: omap-100k: remove set but not used variable
@ 2021-05-12  1:55 Tian Tao
  2021-05-12  3:07 ` tiantao (H)
  0 siblings, 1 reply; 2+ messages in thread
From: Tian Tao @ 2021-05-12  1:55 UTC (permalink / raw)
  To: broonie; +Cc: linux-spi, Tian Tao

The assignment to status on lines 296 and 315 is meaningless and will
rewriten, so just delete.

Signed-off-by: Tian Tao <tiantao6@hisilicon.com>
---
 drivers/spi/spi-omap-100k.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/spi/spi-omap-100k.c b/drivers/spi/spi-omap-100k.c
index 7062f29..dc9b86b 100644
--- a/drivers/spi/spi-omap-100k.c
+++ b/drivers/spi/spi-omap-100k.c
@@ -296,7 +296,6 @@ static int omap1_spi100k_transfer_one_message(struct spi_master *master,
 
 	list_for_each_entry(t, &m->transfers, transfer_list) {
 		if (t->tx_buf == NULL && t->rx_buf == NULL && t->len) {
-			status = -EINVAL;
 			break;
 		}
 		status = omap1_spi100k_setup_transfer(spi, t);
@@ -315,7 +314,6 @@ static int omap1_spi100k_transfer_one_message(struct spi_master *master,
 			m->actual_length += count;
 
 			if (count != t->len) {
-				status = -EIO;
 				break;
 			}
 		}
-- 
2.7.4


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

* Re: [PATCH] spi: omap-100k: remove set but not used variable
  2021-05-12  1:55 [PATCH] spi: omap-100k: remove set but not used variable Tian Tao
@ 2021-05-12  3:07 ` tiantao (H)
  0 siblings, 0 replies; 2+ messages in thread
From: tiantao (H) @ 2021-05-12  3:07 UTC (permalink / raw)
  To: tiantao (H), broonie@kernel.org; +Cc: linux-spi@vger.kernel.org


在 2021/5/12 9:55, tiantao (H) 写道:
> The assignment to status on lines 296 and 315 is meaningless and will
> rewriten, so just delete.
Sorry, please ignore this patch, jay fang has already fixed this problem.
>
> Signed-off-by: Tian Tao <tiantao6@hisilicon.com>
> ---
>   drivers/spi/spi-omap-100k.c | 2 --
>   1 file changed, 2 deletions(-)
>
> diff --git a/drivers/spi/spi-omap-100k.c b/drivers/spi/spi-omap-100k.c
> index 7062f29..dc9b86b 100644
> --- a/drivers/spi/spi-omap-100k.c
> +++ b/drivers/spi/spi-omap-100k.c
> @@ -296,7 +296,6 @@ static int omap1_spi100k_transfer_one_message(struct spi_master *master,
>   
>   	list_for_each_entry(t, &m->transfers, transfer_list) {
>   		if (t->tx_buf == NULL && t->rx_buf == NULL && t->len) {
> -			status = -EINVAL;
>   			break;
>   		}
>   		status = omap1_spi100k_setup_transfer(spi, t);
> @@ -315,7 +314,6 @@ static int omap1_spi100k_transfer_one_message(struct spi_master *master,
>   			m->actual_length += count;
>   
>   			if (count != t->len) {
> -				status = -EIO;
>   				break;
>   			}
>   		}


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

end of thread, other threads:[~2021-05-12  3:07 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-12  1:55 [PATCH] spi: omap-100k: remove set but not used variable Tian Tao
2021-05-12  3:07 ` tiantao (H)

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.