All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/2] change io_cancel return code for no cancel case
@ 2005-09-07 20:39 Benjamin LaHaise
  2005-09-07 20:41 ` [AIO] kiocb locking to serialise retry and cancel Benjamin LaHaise
  0 siblings, 1 reply; 2+ messages in thread
From: Benjamin LaHaise @ 2005-09-07 20:39 UTC (permalink / raw)
  To: torvalds; +Cc: linux-kernel

From: Wendy Cheng <wcheng@redhat.com>

Note that other than few exceptions, most of the current filesystem and/or
drivers do not have aio cancel specifically defined (kiob->ki_cancel field
is mostly NULL).  However, sys_io_cancel system call universally sets
return code to -EAGAIN.  This gives applications a wrong impression that
this call is implemented but just never works.  We have customer inquires
about this issue.

Changed by Benjamin LaHaise to EINVAL instead of ENOSYS

Signed-off-by: S. Wendy Cheng <wcheng@redhat.com>
Acked-by: Benjamin LaHaise <bcrl@kvack.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>

 aio.c |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)

diff -purN --exclude=description 00_linus-git/fs/aio.c 01_aio_enosys/fs/aio.c
--- 00_linus-git/fs/aio.c	2005-09-07 10:59:31.000000000 -0400
+++ 01_aio_enosys/fs/aio.c	2005-09-07 11:03:55.000000000 -0400
@@ -1673,7 +1673,7 @@ asmlinkage long sys_io_cancel(aio_contex
 				ret = -EFAULT;
 		}
 	} else
-		printk(KERN_DEBUG "iocb has no cancel operation\n");
+		ret = -EINVAL;
 
 	put_ioctx(ctx);
 

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2005-09-07 20:45 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-09-07 20:39 [PATCH 1/2] change io_cancel return code for no cancel case Benjamin LaHaise
2005-09-07 20:41 ` [AIO] kiocb locking to serialise retry and cancel Benjamin LaHaise

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.