From: Heiko Carstens <heiko.carstens@de.ibm.com>
To: Peter Zijlstra <a.p.zijlstra@chello.nl>, Ingo Molnar <mingo@elte.hu>
Cc: linux-next@vger.kernel.org
Subject: [PATCH -next] sched/wait: fix __wait_event_interruptible_lock_irq_timeout()
Date: Thu, 31 Oct 2013 12:48:14 +0100 [thread overview]
Message-ID: <20131031114814.GB5551@osiris> (raw)
__wait_event_interruptible_lock_irq_timeout() needs the timeout parameter
passed instead of "ret".
This magically compiled since the only user has a local ret variable.
Luckily we got a build warning:
CC drivers/s390/scsi/zfcp_qdio.o
drivers/s390/scsi/zfcp_qdio.c: In function 'zfcp_qdio_sbal_get':
include/linux/wait.h:780:15: warning: 'ret' may be used uninitialized
__ret = schedule_timeout(__ret); \
^
drivers/s390/scsi/zfcp_qdio.c:245:7: note: 'ret' was declared here
long ret;
^
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
---
include/linux/wait.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/linux/wait.h b/include/linux/wait.h
index fcc968087f05..d3d033ec5313 100644
--- a/include/linux/wait.h
+++ b/include/linux/wait.h
@@ -775,7 +775,7 @@ do { \
#define __wait_event_interruptible_lock_irq_timeout(wq, condition, \
lock, timeout) \
___wait_event(wq, ___wait_cond_timeout(condition), \
- TASK_INTERRUPTIBLE, 0, ret, \
+ TASK_INTERRUPTIBLE, 0, timeout, \
spin_unlock_irq(&lock); \
__ret = schedule_timeout(__ret); \
spin_lock_irq(&lock));
--
1.8.3.4
next reply other threads:[~2013-10-31 11:49 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-31 11:48 Heiko Carstens [this message]
2013-10-31 14:41 ` [PATCH -next] sched/wait: fix __wait_event_interruptible_lock_irq_timeout() Peter Zijlstra
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=20131031114814.GB5551@osiris \
--to=heiko.carstens@de.ibm.com \
--cc=a.p.zijlstra@chello.nl \
--cc=linux-next@vger.kernel.org \
--cc=mingo@elte.hu \
/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