]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
writeback: remove unused nonblocking and congestion checks (gfs2)
authorWu Fengguang <fengguang.wu@intel.com>
Wed, 18 Nov 2009 10:09:41 +0000 (18:09 +0800)
committerSteven Whitehouse <swhiteho@redhat.com>
Thu, 3 Dec 2009 11:59:17 +0000 (11:59 +0000)
No one is calling wb_writeback and write_cache_pages with
wbc.nonblocking=1 any more. And lumpy pageout will want to do
nonblocking writeback without the congestion wait.

Signed-off-by: Wu Fengguang <fengguang.wu@intel.com>
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
fs/gfs2/aops.c

index dce062a0b02a4053adc391b64987cedc03ca1d50..7b8da941526749c9b4a566bf1d3fe7b76f417dd8 100644 (file)
@@ -269,7 +269,6 @@ static int gfs2_write_jdata_pagevec(struct address_space *mapping,
        pgoff_t end_index = i_size >> PAGE_CACHE_SHIFT;
        unsigned offset = i_size & (PAGE_CACHE_SIZE-1);
        unsigned nrblocks = nr_pages * (PAGE_CACHE_SIZE/inode->i_sb->s_blocksize);
-       struct backing_dev_info *bdi = mapping->backing_dev_info;
        int i;
        int ret;
 
@@ -313,11 +312,6 @@ static int gfs2_write_jdata_pagevec(struct address_space *mapping,
 
                if (ret || (--(wbc->nr_to_write) <= 0))
                        ret = 1;
-               if (wbc->nonblocking && bdi_write_congested(bdi)) {
-                       wbc->encountered_congestion = 1;
-                       ret = 1;
-               }
-
        }
        gfs2_trans_end(sdp);
        return ret;
@@ -338,7 +332,6 @@ static int gfs2_write_jdata_pagevec(struct address_space *mapping,
 static int gfs2_write_cache_jdata(struct address_space *mapping,
                                  struct writeback_control *wbc)
 {
-       struct backing_dev_info *bdi = mapping->backing_dev_info;
        int ret = 0;
        int done = 0;
        struct pagevec pvec;
@@ -348,11 +341,6 @@ static int gfs2_write_cache_jdata(struct address_space *mapping,
        int scanned = 0;
        int range_whole = 0;
 
-       if (wbc->nonblocking && bdi_write_congested(bdi)) {
-               wbc->encountered_congestion = 1;
-               return 0;
-       }
-
        pagevec_init(&pvec, 0);
        if (wbc->range_cyclic) {
                index = mapping->writeback_index; /* Start from prev offset */