[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <5b088800-d552-68a1-bf66-6023ccad0ca8@quicinc.com>
Date: Wed, 27 Oct 2021 11:11:56 -0400
From: Qian Cai <quic_qiancai@...cinc.com>
To: Pavel Begunkov <asml.silence@...il.com>,
Jens Axboe <axboe@...nel.dk>
CC: <io-uring@...r.kernel.org>, <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] io_uring: fix a GCC warning in wq_list_for_each()
On 10/27/21 5:56 AM, Pavel Begunkov wrote:
> On 10/25/21 15:59, Qian Cai wrote:
>> fs/io_uring.c: In function '__io_submit_flush_completions':
>> fs/io_uring.c:2367:33: warning: variable 'prev' set but not used
>> [-Wunused-but-set-variable]
>> 2367 | struct io_wq_work_node *node, *prev;
>> | ^~~~
>>
>> Fixed it by open-coded the wq_list_for_each() without an unused previous
>> node pointer.
>
> That's intentional, the var is optimised out and it's better to
> not hand code it (if possible).
Yes, this is pretty minor. Not going to insist if people don't like for
some reasons.
Powered by blists - more mailing lists