]> granicus.if.org Git - zfs/commitdiff
Bug fix in qat_compress.c for vmalloc addr check
authorwli5 <weigang.li@intel.com>
Mon, 5 Feb 2018 18:26:27 +0000 (02:26 +0800)
committerTony Hutter <hutter2@llnl.gov>
Wed, 14 Mar 2018 23:10:36 +0000 (16:10 -0700)
Remove the unused vmalloc address check, and function mem_to_page
will handle the non-vmalloc address when map it to a physical
address.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Weigang Li <weigang.li@intel.com>
Closes #7125

module/zfs/qat_compress.c

index 4d17d7ac9a18361613da2339812d96803fdc17ec..62655f56db67c95698f2567df032754a2be2bd99 100644 (file)
@@ -364,10 +364,6 @@ qat_compress(qat_compress_dir_t dir, char *src, int src_len,
        Cpa32U dst_buffer_list_mem_size = sizeof (CpaBufferList) +
            (num_dst_buf * sizeof (CpaFlatBuffer));
 
-       if (!is_vmalloc_addr(src) || !is_vmalloc_addr(src + src_len - 1) ||
-           !is_vmalloc_addr(dst) || !is_vmalloc_addr(dst + dst_len - 1))
-               return (-1);
-
        if (PHYS_CONTIG_ALLOC(&in_pages,
            num_src_buf * sizeof (struct page *)) != CPA_STATUS_SUCCESS)
                goto fail;