]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - fs/mpage.c
[PATCH] spufs: fix sparse warnings
[linux-2.6-omap-h63xx.git] / fs / mpage.c
index b92c0e64aefa313d74456db2d4c718ad08182dc3..f1d2d02bd4c81ebeb0ccde0c2d66d6c4a980d3d3 100644 (file)
@@ -79,8 +79,11 @@ static int mpage_end_io_write(struct bio *bio, unsigned int bytes_done, int err)
                if (--bvec >= bio->bi_io_vec)
                        prefetchw(&bvec->bv_page->flags);
 
-               if (!uptodate)
+               if (!uptodate){
                        SetPageError(page);
+                       if (page->mapping)
+                               set_bit(AS_EIO, &page->mapping->flags);
+               }
                end_page_writeback(page);
        } while (bvec >= bio->bi_io_vec);
        bio_put(bio);
@@ -99,7 +102,7 @@ static struct bio *mpage_bio_submit(int rw, struct bio *bio)
 static struct bio *
 mpage_alloc(struct block_device *bdev,
                sector_t first_sector, int nr_vecs,
-               unsigned int __nocast gfp_flags)
+               gfp_t gfp_flags)
 {
        struct bio *bio;
 
@@ -718,7 +721,7 @@ retry:
                                                &last_block_in_bio, &ret, wbc,
                                                page->mapping->a_ops->writepage);
                        }
-                       if (unlikely(ret == WRITEPAGE_ACTIVATE))
+                       if (unlikely(ret == AOP_WRITEPAGE_ACTIVATE))
                                unlock_page(page);
                        if (ret || (--(wbc->nr_to_write) <= 0))
                                done = 1;