Re: [PATCH -next] block: remove set but not used variable 'et'

2018-11-09 Thread Jens Axboe
On 11/9/18 7:41 PM, YueHaibing wrote:
> Fixes gcc '-Wunused-but-set-variable' warning:
> 
> block/blk-ioc.c: In function 'put_io_context_active':
> block/blk-ioc.c:174:24: warning:
>  variable 'et' set but not used [-Wunused-but-set-variable]
> 
> It not used any more after commit
> a1ce35fa4985 ("block: remove dead elevator code")

Thanks, applied.

-- 
Jens Axboe



[PATCH -next] block: remove set but not used variable 'et'

2018-11-09 Thread YueHaibing
Fixes gcc '-Wunused-but-set-variable' warning:

block/blk-ioc.c: In function 'put_io_context_active':
block/blk-ioc.c:174:24: warning:
 variable 'et' set but not used [-Wunused-but-set-variable]

It not used any more after commit
a1ce35fa4985 ("block: remove dead elevator code")

Signed-off-by: YueHaibing 
---
 block/blk-ioc.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/block/blk-ioc.c b/block/blk-ioc.c
index 007aac6..56755ad 100644
--- a/block/blk-ioc.c
+++ b/block/blk-ioc.c
@@ -171,7 +171,6 @@ void put_io_context(struct io_context *ioc)
  */
 void put_io_context_active(struct io_context *ioc)
 {
-   struct elevator_type *et;
unsigned long flags;
struct io_cq *icq;
 
@@ -190,7 +189,6 @@ void put_io_context_active(struct io_context *ioc)
if (icq->flags & ICQ_EXITED)
continue;
 
-   et = icq->q->elevator->type;
ioc_exit_icq(icq);
}
spin_unlock_irqrestore(>lock, flags);