]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
Btrfs: subpage-blocksize: Rate limit scrub error message
authorChandan Rajendra <chandan@linux.vnet.ibm.com>
Mon, 4 Jul 2016 04:34:39 +0000 (10:04 +0530)
committerDavid Sterba <dsterba@suse.com>
Tue, 26 Jul 2016 11:52:25 +0000 (13:52 +0200)
btrfs/073 invokes scrub ioctl in a tight loop. In subpage-blocksize
scenario this results in a lot of "scrub: size assumption sectorsize !=
PAGE_SIZE " messages being printed on the console. To reduce the number
of such messages this commit uses btrfs_err_rl() instead of
btrfs_err().

Signed-off-by: Chandan Rajendra <chandan@linux.vnet.ibm.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/scrub.c

index 70427ef66b044db3baadd071e9b58b3fa9ce4bfd..acfe72004646762db89985fec00cb867d2325764 100644 (file)
@@ -3856,7 +3856,7 @@ int btrfs_scrub_dev(struct btrfs_fs_info *fs_info, u64 devid, u64 start,
 
        if (fs_info->chunk_root->sectorsize != PAGE_SIZE) {
                /* not supported for data w/o checksums */
-               btrfs_err(fs_info,
+               btrfs_err_rl(fs_info,
                           "scrub: size assumption sectorsize != PAGE_SIZE "
                           "(%d != %lu) fails",
                       fs_info->chunk_root->sectorsize, PAGE_SIZE);