public inbox for [email protected]
 help / color / mirror / Atom feed
From: Xiaoguang Wang <[email protected]>
To: [email protected]
Cc: [email protected], [email protected]
Subject: [PATCH 5.11 1/2] io_uring: initialize 'timeout' properly in io_sq_thread()
Date: Thu, 12 Nov 2020 14:55:59 +0800	[thread overview]
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>

Some static checker reports below warning:
    fs/io_uring.c:6939 io_sq_thread()
    error: uninitialized symbol 'timeout'.

Fix it.

Signed-off-by: Xiaoguang Wang <[email protected]>
---
 fs/io_uring.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

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


  reply	other threads:[~2020-11-12  6:56 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 ` Xiaoguang Wang [this message]
2020-11-12 11:15   ` [PATCH 5.11 1/2] io_uring: initialize 'timeout' properly in io_sq_thread() Stefano Garzarella
2020-11-12 12:32     ` Xiaoguang Wang
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=20201112065600.8710-2-xiaoguang.wang@linux.alibaba.com \
    [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