]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - fs/fs-writeback.c
drm: imx-ldb: honor the 'native-mode' property when selecting the display_mode
[karo-tx-linux.git] / fs / fs-writeback.c
index 29e4599f6fc1c20b73acb2c580ce8383e169c5f2..206a68b1db1ab1b1f5a6ed6a611723f957e1e58b 100644 (file)
@@ -779,8 +779,8 @@ static void bdi_split_work_to_wbs(struct backing_dev_info *bdi,
                                  bool skip_if_busy)
 {
        struct bdi_writeback *last_wb = NULL;
-       struct bdi_writeback *wb = list_entry_rcu(&bdi->wb_list,
-                                               struct bdi_writeback, bdi_node);
+       struct bdi_writeback *wb = list_entry(&bdi->wb_list,
+                                             struct bdi_writeback, bdi_node);
 
        might_sleep();
 restart:
@@ -2149,7 +2149,12 @@ static void wait_sb_inodes(struct super_block *sb)
                iput(old_inode);
                old_inode = inode;
 
-               filemap_fdatawait(mapping);
+               /*
+                * We keep the error status of individual mapping so that
+                * applications can catch the writeback error using fsync(2).
+                * See filemap_fdatawait_keep_errors() for details.
+                */
+               filemap_fdatawait_keep_errors(mapping);
 
                cond_resched();