mirror of
https://github.com/ceph/ceph
synced 2024-12-27 14:03:25 +00:00
os/bluestore: release aios and pinned buffers on io complete
Once we're done with our IO, clear the aio list so that the pinned buffers are unpinned. This ensures we release memory quickly, even if the TransContext sticks around for a while (e.g., in the osr q). Signed-off-by: Sage Weil <sage@redhat.com>
This commit is contained in:
parent
d82af301c8
commit
4e160f20e4
@ -7575,6 +7575,9 @@ void BlueStore::_txc_finish_io(TransContext *txc)
|
||||
std::lock_guard<std::mutex> l(osr->qlock);
|
||||
txc->state = TransContext::STATE_IO_DONE;
|
||||
|
||||
// release aio contexts (including pinned buffers).
|
||||
txc->ioc.running_aios.clear();
|
||||
|
||||
OpSequencer::q_list_t::iterator p = osr->q.iterator_to(*txc);
|
||||
while (p != osr->q.begin()) {
|
||||
--p;
|
||||
|
Loading…
Reference in New Issue
Block a user