mirror of
https://github.com/ceph/ceph
synced 2024-12-29 15:03:33 +00:00
Merge branch 'testing' into unstable
Conflicts: configure.ac
This commit is contained in:
commit
de61991a87
9
debian/changelog
vendored
9
debian/changelog
vendored
@ -1,3 +1,12 @@
|
||||
ceph (0.23.1-1) experimental; urgency=low
|
||||
|
||||
* msgr: fixed rare messenger race/bug
|
||||
* client: fixed cache consitency with link(2)
|
||||
* client: fix lssnap
|
||||
* msgr: fix ipv6 addr parsing buffer overflow
|
||||
|
||||
-- Sage Weil <sage@newdream.net> Sun, 21 Nov 2010 15:22:21 -0800
|
||||
|
||||
ceph (0.23-1) experimental; urgency=low
|
||||
|
||||
* osd: use new btrfs snapshot ioctls
|
||||
|
@ -1059,7 +1059,7 @@ int Client::make_request(MetaRequest *request,
|
||||
return r;
|
||||
}
|
||||
|
||||
int Client::encode_inode_release(Inode *in, MClientRequest *req,
|
||||
int Client::encode_inode_release(Inode *in, MetaRequest *req,
|
||||
int mds, int drop,
|
||||
int unless, int force)
|
||||
{
|
||||
@ -1091,14 +1091,14 @@ int Client::encode_inode_release(Inode *in, MClientRequest *req,
|
||||
rel.wanted = caps->wanted;
|
||||
rel.dname_len = 0;
|
||||
rel.dname_seq = 0;
|
||||
req->releases.push_back(MClientRequest::Release(rel,""));
|
||||
req->cap_releases.push_back(MClientRequest::Release(rel,""));
|
||||
}
|
||||
dout(25) << "encode_inode_release exit(in:" << *in << ") released:"
|
||||
<< released << dendl;
|
||||
return released;
|
||||
}
|
||||
|
||||
void Client::encode_dentry_release(Dentry *dn, MClientRequest *req,
|
||||
void Client::encode_dentry_release(Dentry *dn, MetaRequest *req,
|
||||
int mds, int drop, int unless)
|
||||
{
|
||||
dout(20) << "encode_dentry_release enter(dn:"
|
||||
@ -1107,7 +1107,7 @@ void Client::encode_dentry_release(Dentry *dn, MClientRequest *req,
|
||||
mds, drop, unless, 1);
|
||||
if (released && dn->lease_mds == mds) {
|
||||
dout(25) << "preemptively releasing dn to mds" << dendl;
|
||||
MClientRequest::Release& rel = req->releases.back();
|
||||
MClientRequest::Release& rel = req->cap_releases.back();
|
||||
rel.item.dname_len = dn->name.length();
|
||||
rel.item.dname_seq = dn->lease_seq;
|
||||
rel.dname = dn->name;
|
||||
@ -1123,26 +1123,26 @@ void Client::encode_dentry_release(Dentry *dn, MClientRequest *req,
|
||||
* Additionally, if you set any *drop member, you'd better have
|
||||
* set the corresponding dentry!
|
||||
*/
|
||||
void Client::encode_cap_releases(MetaRequest *req, MClientRequest *m, int mds) {
|
||||
void Client::encode_cap_releases(MetaRequest *req, int mds) {
|
||||
dout(20) << "encode_cap_releases enter (req: "
|
||||
<< req << ", mds: " << mds << ")" << dendl;
|
||||
if (req->inode_drop && req->inode)
|
||||
encode_inode_release(req->inode, m,
|
||||
encode_inode_release(req->inode, req,
|
||||
mds, req->inode_drop,
|
||||
req->inode_unless);
|
||||
|
||||
if (req->old_inode_drop && req->old_inode)
|
||||
encode_inode_release(req->old_inode, m,
|
||||
encode_inode_release(req->old_inode, req,
|
||||
mds, req->old_inode_drop,
|
||||
req->old_inode_unless);
|
||||
|
||||
if (req->dentry_drop && req->dentry)
|
||||
encode_dentry_release(req->dentry, m,
|
||||
encode_dentry_release(req->dentry, req,
|
||||
mds, req->dentry_drop,
|
||||
req->dentry_unless);
|
||||
|
||||
if (req->old_dentry_drop && req->old_dentry)
|
||||
encode_dentry_release(req->old_dentry, m,
|
||||
encode_dentry_release(req->old_dentry, req,
|
||||
mds, req->old_dentry_drop,
|
||||
req->old_dentry_unless);
|
||||
dout(25) << "encode_cap_releases exit (req: "
|
||||
@ -1217,7 +1217,9 @@ void Client::send_request(MetaRequest *request, int mds)
|
||||
r->set_replayed_op();
|
||||
r->set_mdsmap_epoch(mdsmap->get_epoch());
|
||||
|
||||
encode_cap_releases(request, r, mds);
|
||||
if (request->cap_releases.empty())
|
||||
encode_cap_releases(request, mds);
|
||||
r->releases = request->cap_releases;
|
||||
|
||||
if (request->mds == -1) {
|
||||
request->sent_stamp = g_clock.now();
|
||||
|
@ -37,6 +37,7 @@ enum {
|
||||
#include "msg/Messenger.h"
|
||||
|
||||
#include "messages/MClientReply.h"
|
||||
#include "messages/MClientRequest.h"
|
||||
|
||||
#include "include/types.h"
|
||||
#include "include/lru.h"
|
||||
@ -113,6 +114,7 @@ struct MetaRequest {
|
||||
int old_inode_drop, old_inode_unless;
|
||||
int dentry_drop, dentry_unless;
|
||||
int old_dentry_drop, old_dentry_unless;
|
||||
vector<MClientRequest::Release> cap_releases;
|
||||
Inode *inode;
|
||||
Inode *old_inode;
|
||||
Dentry *dentry; //associated with path
|
||||
@ -829,11 +831,11 @@ public:
|
||||
//MClientRequest *req, int uid, int gid,
|
||||
Inode **ptarget = 0,
|
||||
int use_mds=-1, bufferlist *pdirbl=0);
|
||||
void encode_cap_releases(MetaRequest *request, MClientRequest *m, int mds);
|
||||
int encode_inode_release(Inode *in, MClientRequest *req,
|
||||
void encode_cap_releases(MetaRequest *request, int mds);
|
||||
int encode_inode_release(Inode *in, MetaRequest *req,
|
||||
int mds, int drop,
|
||||
int unless,int force=0);
|
||||
void encode_dentry_release(Dentry *dn, MClientRequest *req,
|
||||
void encode_dentry_release(Dentry *dn, MetaRequest *req,
|
||||
int mds, int drop, int unless);
|
||||
int choose_target_mds(MetaRequest *req);
|
||||
void connect_mds_targets(int mds);
|
||||
@ -1023,6 +1025,9 @@ protected:
|
||||
// unlink old dn from dir
|
||||
olddir->dentries.erase(olddn->name);
|
||||
olddir->dentry_map.erase(olddn->name);
|
||||
// HACK: in the case of hard links. Resolving #588 should include
|
||||
// rendering this unnecessary.
|
||||
olddir->parent_inode->flags &= ~I_COMPLETE;
|
||||
olddn->inode = 0;
|
||||
olddn->dir = 0;
|
||||
lru.lru_remove(olddn);
|
||||
|
Loading…
Reference in New Issue
Block a user