Project

General

Profile

Actions

Bug #47847

closed

[librbd] update AioCompletion return value before evaluating pending count

Added by Jason Dillaman over 3 years ago. Updated over 3 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
Jason Dillaman
Target version:
-
% Done:

0%

Source:
Tags:
Backport:
octopus
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

If the pending count is decremented before the return value is updated,
there is a possibility of two ASIO threads concurrently decrementing the
pending count down from 2 -> 1 -> 0. In the second thread (the one that
performs the final decrement from 1 -> 0), it can finalize the completion
before the first thread has had a chance to update the return value.


Related issues 1 (0 open1 closed)

Copied to rbd - Backport #47888: octopus: [librbd] update AioCompletion return value before evaluating pending countResolvedNathan CutlerActions
Actions

Also available in: Atom PDF