Question on btrfs filesystem defragment args

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Liu Bo created test 284 for xfstests to exercise btrfs defragmentation.

One test sends an argument including "-s -1" meaning "start at negative one"

That's failing today, because parse_size now rejects negative numbers.
(that might be something to fix on its own, since length = (u64)-1
might imply the whole file, per kernel comments).

But has "start at -1" ever had an expected meaning?  That doesn't make
sense to me, but the test does it:

+echo "a single file | start < 0 && 0 < len < file size | off"
+_rundefrag 1 2 1

...

+_btrfs_online_defrag()
+{
+       str=""
+       if [ "$2" = "2" ];then
+               str="$str -s -1 -l $((filesize / 2)) "

and expects a silent result:

...
+a single file | default |  on
+a single file | start < 0 && 0 < len < file size | off
+a single file | start > file size && 0 < len < file size | off
...

What was this test intended to do when it was written?

Thanks,
-Eric
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Filesystem Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux