void finish(int r) {
auto mds = get_mds(); // to keep dout happy
- auto in = mds->server->rdlock_path_pin_ref(mdr, true);
+ auto in = mdr->in[0];
ceph_assert(in != nullptr);
h->record_uninline_passed();
in->uninline_finished();
mdr->apply();
+ in->auth_unpin(this); // for uninline data
mds->server->respond_to_request(mdr, r);
}
};
void finish(int r) override {
auto mds = get_mds(); // to keep dout/derr happy
- auto in = mds->server->rdlock_path_pin_ref(mdr, true);
+ auto in = mdr->in[0];
+
+ ceph_assert(in != nullptr);
// return faster if operation has failed (non-zero) status
if (r) {
in->make_path_string(path);
h->record_uninline_status(in->ino(), r, path);
in->uninline_finished();
+ in->auth_unpin(this); // for uninline data
mds->server->respond_to_request(mdr, r);
return;
}
void MDCache::uninline_data_work(MDRequestRef mdr)
{
- CInode *in = mds->server->rdlock_path_pin_ref(mdr, true);
+ CInode *in = mdr->in[0];
- if (!in) {
- return;
- }
+ ceph_assert(in != nullptr);
MutationImpl::LockOpVec lov;
lov.add_xlock(&in->authlock);
if (!in->has_inline_data()) {
dout(20) << "(uninline_data) inode doesn't have inline data anymore " << *in << dendl;
in->uninline_finished();
+ in->auth_unpin(this); // for uninline_data
mds->server->respond_to_request(mdr, 0);
return;
}