Re: [PATCH 1/4] dlm: fix ordering of bast and cast
From: Steven Whitehouse
Date: Thu Mar 04 2010 - 07:41:19 EST
On Fri, 2010-02-26 at 13:17 -0600, David Teigland wrote:
> When both blocking and completion callbacks are queued for lock,
> the dlm would always deliver the completion callback (cast) first.
> In some cases the blocking callback (bast) is queued before the
> cast, though, and should be delivered first. This patch keeps
> track of the order in which they were queued and delivers them
> in that order.
> This patch also keeps track of the granted mode in the last cast
> and eliminates the following bast if the bast mode is compatible
> with the preceding cast mode. This happens when a remotely mastered
> lock is demoted, e.g. EX->NL, in which case the local node queues
> a cast immediately after sending the demote message. In this way
> a cast can be queued for a mode, e.g. NL, that makes an in-transit
> bast extraneous.
Some questions on this one... shouldn't the filtering of the basts go at
the start of dlm_add_ast() so that it catches both the basts heading to
userspace and the ones going via the kernel interface?
Also, when the short-cut of generating casts locally on certain remotly
mastered demote requests is used, does that somehow suppress the
generation of casts on the lock master? If not, where do the duplicate
cast messages get filtered out?
I notice that the variable lkb->lkb_bastmode_done has been added, but is
only ever assigned to and never read. Was that supposed to have been
made accessible via debugfs for example?
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/