If the kernel told us a metadata object could be optimized, we ask it to
do the optimization and it spits back that it doesn't support
optimizing, don't record this as an error since the fs is still
consistent.
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
case ENOTTY:
case EOPNOTSUPP:
/*
- * If we forced repairs, don't complain if kernel
- * doesn't know how to fix.
+ * If we forced repairs or this is a preen, don't
+ * error out if the kernel doesn't know how to fix.
*/
- if (debug_tweak_on("XFS_SCRUB_FORCE_REPAIR"))
+ if (is_unoptimized(&oldm) ||
+ debug_tweak_on("XFS_SCRUB_FORCE_REPAIR"))
return CHECK_DONE;
/* fall through */
case EINVAL: