All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH -next] memstick: tifm: remove set but not used variable 'data'
@ 2019-04-25  1:53 YueHaibing
  2019-04-29 10:44 ` Ulf Hansson
  0 siblings, 1 reply; 2+ messages in thread
From: YueHaibing @ 2019-04-25  1:53 UTC (permalink / raw)
  To: kernel-janitors

Fixes gcc '-Wunused-but-set-variable' warning:

drivers/memstick/host/tifm_ms.c: In function 'tifm_ms_issue_cmd':
drivers/memstick/host/tifm_ms.c:259:17: warning:
 variable 'data' set but not used [-Wunused-but-set-variable]

It's not used any more since commit 92b22d935fed ("tifm: fix the
MemoryStick host fifo handling code")

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
---
 drivers/memstick/host/tifm_ms.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/drivers/memstick/host/tifm_ms.c b/drivers/memstick/host/tifm_ms.c
index 1bbb2ead9556..6b13ac56eb27 100644
--- a/drivers/memstick/host/tifm_ms.c
+++ b/drivers/memstick/host/tifm_ms.c
@@ -256,7 +256,6 @@ static unsigned int tifm_ms_transfer_data(struct tifm_ms *host)
 static int tifm_ms_issue_cmd(struct tifm_ms *host)
 {
 	struct tifm_dev *sock = host->dev;
-	unsigned char *data;
 	unsigned int data_len, cmd, sys_param;
 
 	host->cmd_flags = 0;
@@ -265,8 +264,6 @@ static int tifm_ms_issue_cmd(struct tifm_ms *host)
 	host->io_word = 0;
 	host->cmd_flags = 0;
 
-	data = host->req->data;
-
 	host->use_dma = !no_dma;
 
 	if (host->req->long_data) {

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

* Re: [PATCH -next] memstick: tifm: remove set but not used variable 'data'
  2019-04-25  1:53 [PATCH -next] memstick: tifm: remove set but not used variable 'data' YueHaibing
@ 2019-04-29 10:44 ` Ulf Hansson
  0 siblings, 0 replies; 2+ messages in thread
From: Ulf Hansson @ 2019-04-29 10:44 UTC (permalink / raw)
  To: kernel-janitors

On Thu, 25 Apr 2019 at 03:53, YueHaibing <yuehaibing@huawei.com> wrote:
>
> Fixes gcc '-Wunused-but-set-variable' warning:
>
> drivers/memstick/host/tifm_ms.c: In function 'tifm_ms_issue_cmd':
> drivers/memstick/host/tifm_ms.c:259:17: warning:
>  variable 'data' set but not used [-Wunused-but-set-variable]
>
> It's not used any more since commit 92b22d935fed ("tifm: fix the
> MemoryStick host fifo handling code")
>
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>

Applied for next, thanks!

Kind regards
Uffe


> ---
>  drivers/memstick/host/tifm_ms.c | 3 ---
>  1 file changed, 3 deletions(-)
>
> diff --git a/drivers/memstick/host/tifm_ms.c b/drivers/memstick/host/tifm_ms.c
> index 1bbb2ead9556..6b13ac56eb27 100644
> --- a/drivers/memstick/host/tifm_ms.c
> +++ b/drivers/memstick/host/tifm_ms.c
> @@ -256,7 +256,6 @@ static unsigned int tifm_ms_transfer_data(struct tifm_ms *host)
>  static int tifm_ms_issue_cmd(struct tifm_ms *host)
>  {
>         struct tifm_dev *sock = host->dev;
> -       unsigned char *data;
>         unsigned int data_len, cmd, sys_param;
>
>         host->cmd_flags = 0;
> @@ -265,8 +264,6 @@ static int tifm_ms_issue_cmd(struct tifm_ms *host)
>         host->io_word = 0;
>         host->cmd_flags = 0;
>
> -       data = host->req->data;
> -
>         host->use_dma = !no_dma;
>
>         if (host->req->long_data) {
>
>
>

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

end of thread, other threads:[~2019-04-29 10:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-04-25  1:53 [PATCH -next] memstick: tifm: remove set but not used variable 'data' YueHaibing
2019-04-29 10:44 ` Ulf Hansson

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.