Re: [PATCH v3] btrfs: fix check_shared for fiemap ioctl

2016-06-12 Thread Lu Fengqi
At 06/09/2016 05:15 PM, David Sterba wrote: On Wed, Jun 08, 2016 at 08:53:00AM -0700, Mark Fasheh wrote: On Wed, Jun 08, 2016 at 01:13:03PM +0800, Lu Fengqi wrote: Only in the case of different root_id or different object_id, check_shared identified extent as the shared. However, If a extent wa

Re: [PATCH v3] btrfs: fix check_shared for fiemap ioctl

2016-06-09 Thread David Sterba
On Wed, Jun 08, 2016 at 08:53:00AM -0700, Mark Fasheh wrote: > On Wed, Jun 08, 2016 at 01:13:03PM +0800, Lu Fengqi wrote: > > Only in the case of different root_id or different object_id, check_shared > > identified extent as the shared. However, If a extent was referred by > > different offset of

Re: [PATCH v3] btrfs: fix check_shared for fiemap ioctl

2016-06-08 Thread Mark Fasheh
On Wed, Jun 08, 2016 at 01:13:03PM +0800, Lu Fengqi wrote: > Only in the case of different root_id or different object_id, check_shared > identified extent as the shared. However, If a extent was referred by > different offset of same file, it should also be identified as shared. > In addition, che

[PATCH v3] btrfs: fix check_shared for fiemap ioctl

2016-06-07 Thread Lu Fengqi
Only in the case of different root_id or different object_id, check_shared identified extent as the shared. However, If a extent was referred by different offset of same file, it should also be identified as shared. In addition, check_shared's loop scale is at least n^3, so if a extent has too man