]> Git Repo - linux.git/blobdiff - fs/btrfs/compression.c
efi/x86: add headroom to decompressor BSS to account for setup block
[linux.git] / fs / btrfs / compression.c
index de95ad27722f70f13a2f1fbd5063902aad632187..9ab610cc91142092765fb8a1eca310e30d35ab7c 100644 (file)
@@ -1290,7 +1290,7 @@ int btrfs_decompress_buf2page(const char *buf, unsigned long buf_start,
        /* copy bytes from the working buffer into the pages */
        while (working_bytes > 0) {
                bytes = min_t(unsigned long, bvec.bv_len,
-                               PAGE_SIZE - buf_offset);
+                               PAGE_SIZE - (buf_offset % PAGE_SIZE));
                bytes = min(bytes, working_bytes);
 
                kaddr = kmap_atomic(bvec.bv_page);
This page took 0.033643 seconds and 4 git commands to generate.