[Ocfs2-devel] [PATCH 1/1] dlm: fix a race in lockres mastery

2010-03-22 Thread Srinivas Eeda
In dlm_assert_master_handler, spinlock is released little sooner which creates a window for two nodes to race during mastery. In a scenario where node A had a head start during lock mastery and dlm spinlock is just released on node B in dlm_assert_master_handler. Right then a process on node B

Re: [Ocfs2-devel] [PATCH 1/1] dlm: fix a race in lockres mastery

2010-03-22 Thread Sunil Mushran
= In o2dlm, the resource master maintains a (ref)map of all nodes that are informed of the fact that that node masters that resource. This is done to prevent the master from purging the resource before the other node can create a

Re: [Ocfs2-devel] [PATCH 1/1] dlm: fix a race in lockres mastery

2010-03-22 Thread Joel Becker
On Mon, Mar 22, 2010 at 05:41:43PM -0700, Sunil Mushran wrote: = In o2dlm, the resource master maintains a (ref)map of all nodes that are informed of the fact that that node masters that resource. This is done to prevent the

Re: [Ocfs2-devel] [PATCH 1/1] dlm: fix a race in lockres mastery

2010-03-22 Thread Sunil Mushran
yes, your wording is better. and yes, dlm-spinlock is the top level lock. Joel Becker wrote: On Mon, Mar 22, 2010 at 05:41:43PM -0700, Sunil Mushran wrote: = In o2dlm, the resource master maintains a (ref)map of all nodes that

Re: [Ocfs2-devel] [PATCH 1/1] dlm: fix a race in lockres mastery

2010-03-22 Thread Joel Becker
On Mon, Mar 22, 2010 at 06:20:32PM -0700, Sunil Mushran wrote: yes, your wording is better. and yes, dlm-spinlock is the top level lock. This patch is now in the 'fixes' branch of ocfs2.git. Joel -- Life's Little Instruction Book #314 Never underestimate the power of

Re: [Ocfs2-devel] [PATCH 1/1] dlm: fix a race in lockres mastery

2010-03-22 Thread SRINIVAS EEDA
Sunil, Joel, thanks for modifying the comments :) On 3/22/2010 6:47 PM, Joel Becker wrote: On Mon, Mar 22, 2010 at 06:20:32PM -0700, Sunil Mushran wrote: yes, your wording is better. and yes, dlm-spinlock is the top level lock. This patch is now in the 'fixes' branch of