提交 e2057c5a 编写于 作者: M Mark Fasheh

ocfs2: cond_resched() in ocfs2_zero_extend()

The loop within ocfs2_zero_extend() can execute for a long time, causing
spurious soft lockup warnings.
Signed-off-by: NMark Fasheh <mark.fasheh@oracle.com>
上级 0effef77
......@@ -30,6 +30,7 @@
#include <linux/highmem.h>
#include <linux/pagemap.h>
#include <linux/uio.h>
#include <linux/sched.h>
#define MLOG_MASK_PREFIX ML_INODE
#include <cluster/masklog.h>
......@@ -691,6 +692,12 @@ static int ocfs2_zero_extend(struct inode *inode,
}
start_off += sb->s_blocksize;
/*
* Very large extends have the potential to lock up
* the cpu for extended periods of time.
*/
cond_resched();
}
out:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册