浏览代码

btrfs: raid56: catch errors from full_stripe_write

Add fall-back code to catch failure of full_stripe_write. Proper error
handling from inside run_plug would need more code restructuring as it's
called at arbitrary points by io scheduler.

Signed-off-by: David Sterba <dsterba@suse.com>
David Sterba 7 年之前
父节点
当前提交
c7b562c548
共有 1 个文件被更改,包括 4 次插入1 次删除
  1. 4 1
      fs/btrfs/raid56.c

+ 4 - 1
fs/btrfs/raid56.c

@@ -1686,8 +1686,11 @@ static void run_plug(struct btrfs_plug_cb *plug)
 		list_del_init(&cur->plug_list);
 		list_del_init(&cur->plug_list);
 
 
 		if (rbio_is_full(cur)) {
 		if (rbio_is_full(cur)) {
+			int ret;
+
 			/* we have a full stripe, send it down */
 			/* we have a full stripe, send it down */
-			full_stripe_write(cur);
+			ret = full_stripe_write(cur);
+			BUG_ON(ret);
 			continue;
 			continue;
 		}
 		}
 		if (last) {
 		if (last) {