fs: dlm: make buffer handling per msg
authorAlexander Aring <aahringo@redhat.com>
Fri, 21 May 2021 19:08:42 +0000 (15:08 -0400)
committerDavid Teigland <teigland@redhat.com>
Tue, 25 May 2021 14:22:20 +0000 (09:22 -0500)
commit8f2dc78dbc2010b497bb58e0460cb44c678a3c5b
tree63b4528cf5521cfbf0c5aa085693170223afc634
parenta070a91cf1402b5328d3517d1fccbdeec58d3f2d
fs: dlm: make buffer handling per msg

This patch makes the void pointer handle for lowcomms functionality per
message and not per page allocation entry. A refcount handling for the
handle was added to keep the message alive until the user doesn't need
it anymore.

There exists now a per message callback which will be called when
allocating a new buffer. This callback will be guaranteed to be called
according the order of the sending buffer, which can be used that the
caller increments a sequence number for the dlm message handle.

For transition process we cast the dlm_mhandle to dlm_msg and vice versa
until the midcomms layer will implement a specific dlm_mhandle structure.

Signed-off-by: Alexander Aring <aahringo@redhat.com>
Signed-off-by: David Teigland <teigland@redhat.com>
fs/dlm/dlm_internal.h
fs/dlm/lowcomms.c
fs/dlm/lowcomms.h
fs/dlm/midcomms.c
fs/dlm/rcom.c