Messages in this thread | | | Date | Wed, 22 Aug 2012 06:38:47 +0100 | From | Al Viro <> | Subject | Re: [PATCH] task_work: add a scheduling point in task_work_run() |
| |
On Wed, Aug 22, 2012 at 01:27:21PM +0800, Michael Wang wrote:
> And can we make sure that it is safe to sleep(schedule) at this point? > It may need some totally testing to cover all the situation...
task_work callback can bloody well block, so yes, it is safe. Hell, we are doing final close from that; that can lead to any amount of IO, up to and including on-disk file freeing and, in case of vfsmount kept alive by an opened file after we'd done umount -l, actual final unmount of a filesystem. That can more than just block, that can block for a long time if that's a network filesystem...
| |