Re: [Ocfs2-devel] [PATCH V2] ocfs2: Take inode cluster lock before moving reflinked inode from orphan dir

2018-05-01 Thread Ashish Samant
On 05/01/2018 05:08 PM, Andrew Morton wrote: > On Wed, 11 Apr 2018 12:31:47 -0700 Ashish Samant <ashish.sam...@oracle.com> > wrote: > >> While reflinking an inode, we create a new inode in orphan directory, then >> take EX lock on it, reflink the original inode to orp

[Ocfs2-devel] [PATCH V2] ocfs2: Take inode cluster lock before moving reflinked inode from orphan dir

2018-04-11 Thread Ashish Samant
locking in the ocfs2_init_security_and_acl() call chain. Signed-off-by: Ashish Samant <ashish.sam...@oracle.com> V1->V2: Modify commit message to better reflect the problem in upstream kernel. --- fs/ocfs2/refcounttree.c | 14 -- 1 file changed, 12 insertions(+), 2 deletions

Re: [Ocfs2-devel] [PATCH] ocfs2: Take inode cluster lock before moving reflinked inode from orphan dir

2018-04-10 Thread Ashish Samant
On 04/02/2018 02:17 AM, Joseph Qi wrote: > > On 18/3/31 01:42, Ashish Samant wrote: >> While reflinking an inode, we create a new inode in orphan directory, then >> take EX lock on it, reflink the original inode to orphan inode and release >> EX lock. Once the lock is rel

[Ocfs2-devel] [PATCH] ocfs2: Take inode cluster lock before moving reflinked inode from orphan dir

2018-03-30 Thread Ashish Samant
2_init_security_and_acl() call chain. Signed-off-by: Ashish Samant <ashish.sam...@oracle.com> --- fs/ocfs2/refcounttree.c | 14 -- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/fs/ocfs2/refcounttree.c b/fs/ocfs2/refcounttree.c index ab156e3..1b1283f 100644 --- a/

Re: [Ocfs2-devel] fstrim corrupts ocfs2 filesystems(become ready-only) on SSD device which is managed by multipath

2017-10-27 Thread Ashish Samant
Hi Gang, The following patch sent to the list should fix the issue. https://patchwork.kernel.org/patch/10002583/ Thanks, Ashish On 10/27/2017 02:47 AM, Gang He wrote: > Hello Guys, > > I got a bug from the customer, he said, fstrim command corrupted ocfs2 file > system on their SSD SAN, the

[Ocfs2-devel] [PATCH] ocfs2: fstrim: Fix start offset of first cluster group during fstrim

2017-10-12 Thread Ashish Samant
over into the next cluster group and zero out the group descriptor there. This can cause filesytem corruption that cannot be fixed by fsck. Signed-off-by: Ashish Samant <ashish.sam...@oracle.com> Cc: sta...@vger.kernel.org --- fs/ocfs2/alloc.c | 24 ++-- 1 file chang

[Ocfs2-devel] [PATCH] ocfs2: Fix double put of recount tree in ocfs2_lock_refcount_tree()

2016-09-15 Thread Ashish Samant
y avoiding the second call to ocfs2_refcount_tree_put() Signed-off-by: Ashish Samant <ashish.sam...@oracle.com> --- fs/ocfs2/refcounttree.c | 1 - 1 file changed, 1 deletion(-) diff --git a/fs/ocfs2/refcounttree.c b/fs/ocfs2/refcounttree.c index 92bbe93..a9d4102 100644 --- a/fs/ocfs2/refcoun

Re: [Ocfs2-devel] [PATCH] ocfs2: Fix start offset to ocfs2_zero_range_for_truncate()

2016-09-14 Thread Ashish Samant
On 09/14/2016 03:43 PM, Andrew Morton wrote: > On Thu, 11 Aug 2016 16:12:27 -0700 Ashish Samant <ashish.sam...@oracle.com> > wrote: > >> If we do fallocate with punch hole option on a reflink, with start offset >> on a cluster boundary and end offset somewhere in anot

Re: [Ocfs2-devel] [PATCH v2] ocfs2: Fix start offset to ocfs2_zero_range_for_truncate()

2016-08-30 Thread Ashish Samant
Hi Eric, I am able to reproduce this on 4.8.0-rc3 as well. Can you try again and issue a sync between fallocate and dd? On 08/30/2016 12:38 AM, Eric Ren wrote: > Hi, > > I'm on 4.8.0-rc3 kernel. Hope someone else can double-confirm this;-) > > On 08/30/2016 12:11 PM, Ashish Saman

Re: [Ocfs2-devel] [PATCH v2] ocfs2: Fix start offset to ocfs2_zero_range_for_truncate()

2016-08-29 Thread Ashish Samant
| hexdump -C cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd cd || * 1+0 records in 1+0 records out 0010 Thanks, Ashish On 08/29/2016 08:33 PM, Eric Ren wrote: > Hello, > > On 08/30/2016 03:23 AM, Ashish Samant wrote: >> Hi Eric, >> >> T

[Ocfs2-devel] [PATCH] ocfs2: Fix start offset to ocfs2_zero_range_for_truncate()

2016-08-11 Thread Ashish Samant
out. Fix this by skipping this cluster in such a scenario. Signed-off-by: Ashish Samant <ashish.sam...@oracle.com> --- fs/ocfs2/file.c | 34 -- 1 file changed, 24 insertions(+), 10 deletions(-) diff --git a/fs/ocfs2/file.c b/fs/ocfs2/file.c index 4a6e130..a