Skip to content
Commit 9e29db0e authored by Chris Mason's avatar Chris Mason Committed by Andy Grover
Browse files

RDS: Use a generation counter to avoid rds_send_xmit loop



rds_send_xmit is required to loop around after it releases the lock
because someone else could done a trylock, found someone working on the
list and backed off.

But, once we drop our lock, it is possible that someone else does come
in and make progress on the list.  We should detect this and not loop
around if another process is actually working on the list.

This patch adds a generation counter that is bumped every time we
get the lock and do some send work.  If the retry notices someone else
has bumped the generation counter, it does not need to loop around and
continue working.

Signed-off-by: default avatarChris Mason <chris.mason@oracle.com>
Signed-off-by: default avatarAndy Grover <andy.grover@oracle.com>
parent acfcd4d4
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment