dm-crypt: use __bio_add_page to add single page to clone bio
[linux-block.git] / fs / cramfs / inode.c
index e3d168911dbe12ea242d5ee66c5ddc54a9aa3e55..27c6597aa1be5a0fc0bce9be27f4244ce74369ac 100644 (file)
@@ -183,7 +183,7 @@ static void *cramfs_blkdev_read(struct super_block *sb, unsigned int offset,
                                unsigned int len)
 {
        struct address_space *mapping = sb->s_bdev->bd_inode->i_mapping;
-       struct file_ra_state ra;
+       struct file_ra_state ra = {};
        struct page *pages[BLKS_PER_BUF];
        unsigned i, blocknr, buffer;
        unsigned long devsize;
@@ -473,7 +473,7 @@ static unsigned int cramfs_physmem_mmap_capabilities(struct file *file)
 static const struct file_operations cramfs_physmem_fops = {
        .llseek                 = generic_file_llseek,
        .read_iter              = generic_file_read_iter,
-       .splice_read            = generic_file_splice_read,
+       .splice_read            = filemap_splice_read,
        .mmap                   = cramfs_physmem_mmap,
 #ifndef CONFIG_MMU
        .get_unmapped_area      = cramfs_physmem_get_unmapped_area,