From: Xiaoguang Wang <[email protected]>
To: Stefano Garzarella <[email protected]>
Cc: [email protected], [email protected], [email protected]
Subject: Re: [PATCH 5.11 1/2] io_uring: initialize 'timeout' properly in io_sq_thread()
Date: Thu, 12 Nov 2020 20:32:28 +0800 [thread overview]
Message-ID: <[email protected]> (raw)
In-Reply-To: <20201112111519.ydrzwsvsbipotogr@steredhat>
hi,
> On Thu, Nov 12, 2020 at 02:55:59PM +0800, Xiaoguang Wang wrote:
>> Some static checker reports below warning:
>> fs/io_uring.c:6939 io_sq_thread()
>> error: uninitialized symbol 'timeout'.
>>
>> Fix it.
>
> We can also add the reporter:
>
> Reported-by: Dan Carpenter <[email protected]>
Sorry, forgot to add it :)
>
>>
>> Signed-off-by: Xiaoguang Wang <[email protected]>
>> ---
>> fs/io_uring.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> LGTM:
>
> Reviewed-by: Stefano Garzarella <[email protected]>
Thanks.
Regards,
Xiaoguang Wang
>
>>
>> diff --git a/fs/io_uring.c b/fs/io_uring.c
>> index c1dcb22e2b76..c9b743be5328 100644
>> --- a/fs/io_uring.c
>> +++ b/fs/io_uring.c
>> @@ -6921,7 +6921,7 @@ static int io_sq_thread(void *data)
>> const struct cred *old_cred = NULL;
>> struct io_sq_data *sqd = data;
>> struct io_ring_ctx *ctx;
>> - unsigned long timeout;
>> + unsigned long timeout = 0;
>> DEFINE_WAIT(wait);
>>
>> task_lock(current);
>> --
>> 2.17.2
>>
next prev parent reply other threads:[~2020-11-12 12:33 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-12 6:55 [PATCH 5.11 0/2] two minor cleanup and improvement for sqpoll Xiaoguang Wang
2020-11-12 6:55 ` [PATCH 5.11 1/2] io_uring: initialize 'timeout' properly in io_sq_thread() Xiaoguang Wang
2020-11-12 11:15 ` Stefano Garzarella
2020-11-12 12:32 ` Xiaoguang Wang [this message]
2020-11-12 6:56 ` [PATCH 5.11 2/2] io_uring: don't acquire uring_lock twice Xiaoguang Wang
2020-11-12 16:03 ` [PATCH 5.11 0/2] two minor cleanup and improvement for sqpoll Jens Axboe
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=58c69d4a-64e5-b4f3-54e7-fae59a550cdb@linux.alibaba.com \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
[email protected] \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox