From: Guenter Roeck <linux@roeck-us.net>
To: Alexander Viro <viro@zeniv.linux.org.uk>
Cc: linux-fsdevel@vger.kernel.org, linux-aio@kvack.org,
linux-kernel@vger.kernel.org, kernel-testers@vger.kernel.org,
Guenter Roeck <linux@roeck-us.net>,
Benjamin LaHaise <bcrl@kvack.org>
Subject: [PATCH -next] aio: Fix compile error due to unexpected use of cmpxchg()
Date: Fri, 22 Jan 2016 10:14:39 -0800 [thread overview]
Message-ID: <1453486479-19347-1-git-send-email-linux@roeck-us.net> (raw)
cmpxchg() on some architectures (ia64) doesn't like functions as parameters.
This results in the following compile error on the affected architectures.
fs/aio.c: In function 'aio_thread_fn':
fs/aio.c:1499:1: error: cast specifies function type
Fixes: 6a81013efc40 ("aio: add support for IOCB_CMD_POLL via aio thread helper")
Cc: Benjamin LaHaise <bcrl@kvack.org>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
---
No idea if this is the correct or an acceptable fix.
If not, please consider this to be a bug report.
fs/aio.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fs/aio.c b/fs/aio.c
index 56bcdf4105f4..229a91e391df 100644
--- a/fs/aio.c
+++ b/fs/aio.c
@@ -1495,8 +1495,8 @@ static void aio_thread_fn(struct work_struct *work)
* cancellation if it has not already occurred.
*/
old_cancel = cmpxchg(&iocb->ki_cancel,
- aio_thread_queue_iocb_cancel_early,
- aio_thread_queue_iocb_cancel);
+ (kiocb_cancel_fn *)aio_thread_queue_iocb_cancel_early,
+ (kiocb_cancel_fn *)aio_thread_queue_iocb_cancel);
if (old_cancel != KIOCB_CANCELLED)
ret = iocb->ki_work_fn(iocb);
else
--
2.1.4
next reply other threads:[~2016-01-22 18:14 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-22 18:14 Guenter Roeck [this message]
2016-01-22 18:44 ` [PATCH -next] aio: Fix compile error due to unexpected use of cmpxchg() Benjamin LaHaise
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=1453486479-19347-1-git-send-email-linux@roeck-us.net \
--to=linux@roeck-us.net \
--cc=bcrl@kvack.org \
--cc=kernel-testers@vger.kernel.org \
--cc=linux-aio@kvack.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=viro@zeniv.linux.org.uk \
/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;
as well as URLs for NNTP newsgroup(s).