From: Chandan Rajendra Date: Mon, 4 Jul 2016 04:34:39 +0000 (+0530) Subject: Btrfs: subpage-blocksize: Rate limit scrub error message X-Git-Tag: v4.8-rc1~38^2~1^2~23 X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=commitdiff_plain;h=751bebbe0ad261b3ac5d9e75eaec4d5fe9e23160;p=linux.git Btrfs: subpage-blocksize: Rate limit scrub error message 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 Signed-off-by: David Sterba --- diff --git a/fs/btrfs/scrub.c b/fs/btrfs/scrub.c index 70427ef66b04..acfe72004646 100644 --- a/fs/btrfs/scrub.c +++ b/fs/btrfs/scrub.c @@ -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);