Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

os/bluestore: assert blob map returns success #14473

Merged
merged 1 commit into from Apr 27, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
7 changes: 4 additions & 3 deletions src/os/bluestore/BlueStore.cc
Expand Up @@ -5997,6 +5997,7 @@ int BlueStore::_do_read(
return r;
return 0;
});
assert(r == 0);
} else {
// read the pieces
for (auto& reg : p.second) {
Expand Down Expand Up @@ -6034,8 +6035,7 @@ int BlueStore::_do_read(
return r;
return 0;
});
if (r < 0)
return r;
assert(r == 0);
assert(reg.bl.length() == r_len);
}
}
Expand Down Expand Up @@ -9353,12 +9353,13 @@ int BlueStore::_do_alloc_write(
<< l->length() << std::dec << " write via deferred" << dendl;
bluestore_deferred_op_t *op = _get_deferred_op(txc, o);
op->op = bluestore_deferred_op_t::OP_WRITE;
b->get_blob().map(
int r = b->get_blob().map(
b_off, l->length(),
[&](uint64_t offset, uint64_t length) {
op->extents.emplace_back(bluestore_pextent_t(offset, length));
return 0;
});
assert(r == 0);
op->data = *l;
} else {
b->get_blob().map_bl(
Expand Down