Andrew Mahone
2012-Jun-05 16:21 UTC
PATCH: btrfs defrag ioctl, override extent count and size checks compression enabled.
I noticed a few days ago that btrfs fi defrag -cXXX can not be used to compress files unless they are fragmented. The attached patch passes the compression flag to should_defrag_range, where it disables the adjacent-extent and extent size checks if set. The inline/sparse extent check is not modified - I assumed it would not be useful to compress inline extents. -- Andrew Mahone andrew DOT mahone AT gmail DOT com\
Josef Bacik
2012-Jun-15 15:57 UTC
Re: PATCH: btrfs defrag ioctl, override extent count and size checks compression enabled.
On Tue, Jun 05, 2012 at 12:21:40PM -0400, Andrew Mahone wrote:> I noticed a few days ago that btrfs fi defrag -cXXX can not be used to > compress files unless they are fragmented. The attached patch passes > the compression flag to should_defrag_range, where it disables the > adjacent-extent and extent size checks if set. The inline/sparse > extent check is not modified - I assumed it would not be useful to > compress inline extents. >Need a Signed-off-by: line and please inline your patches, don''t attach them. Once you resubmit I''ll include in btrfs-next. Thanks, Josef -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html