s3:locking: add share_mode_entry_prepare_{lock,unlock}() infrastructure