]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mds: drop mutation locks
authorSage Weil <sage@newdream.net>
Tue, 20 Apr 2010 16:59:16 +0000 (09:59 -0700)
committerSage Weil <sage@newdream.net>
Tue, 20 Apr 2010 16:58:53 +0000 (09:58 -0700)
Saw this one, but fixed others that appear broken as well:

mds/MDCache.h: In function 'virtual Mutation::~Mutation()':
mds/MDCache.h:115: FAILED assert(pins.empty())
 1: (Mutation::~Mutation()+0x46) [0x791716]
 2: (MDCache::truncate_inode_logged(CInode*, Mutation*)+0x7b) [0x7bd6b7]
 3: (C_MDC_TruncateLogged::finish(int)+0x2c) [0x84100e]
 4: (finish_contexts(std::list<Context*, std::allocator<Context*> >&, int)+0x1af) [0x74a807]
 5: (Journaler::_finish_flush(int, long, utime_t, bool)+0x873) [0x92ea71]
 6: (Journaler::C_Flush::finish(int)+0x43) [0x936503]
 7: (Objecter::handle_osd_op_reply(MOSDOpReply*)+0xcf5) [0x8ff00f]
 8: (MDS::_dispatch(Message*)+0x1ee0) [0x726372]
 9: (MDS::ms_dispatch(Message*)+0x2f) [0x7274b9]
 10: (Messenger::ms_deliver_dispatch(Message*)+0x55) [0x719949]
 11: (SimpleMessenger::dispatch_entry()+0x4f4) [0x7074b2]
 12: (SimpleMessenger::DispatchThread::entry()+0x29) [0x7039d1]
 13: (Thread::_entry_func(void*)+0x20) [0x71412e]
 14: /lib/libpthread.so.0 [0x7f25474e073a]
 15: (clone()+0x6d) [0x7f254670a69d]

src/mds/MDCache.cc

index d4e2096b9e9fbc1102b6fbbdd5fdd2a6d0c6d478..2934b662a43b7b9f4d0d1e01285fe4b2b7bf4a13 100644 (file)
@@ -804,6 +804,7 @@ void MDCache::subtree_merge_writebehind_finish(CInode *in, Mutation *mut)
   in->pop_and_dirty_projected_inode(mut->ls);
 
   mut->apply();
+  mds->locker->drop_locks(mut);
   mut->cleanup();
   delete mut;
 
@@ -4687,6 +4688,8 @@ void MDCache::truncate_inode_logged(CInode *in, Mutation *mut)
 {
   dout(10) << "truncate_inode_logged " << *in << dendl;
   mut->apply();
+  mds->locker->drop_locks(mut);
+  mut->cleanup();
   delete mut;
 
   in->put(CInode::PIN_TRUNCATING);
@@ -6821,6 +6824,7 @@ void MDCache::_snaprealm_create_finish(MDRequest *mdr, Mutation *mut, CInode *in
   // apply
   in->pop_and_dirty_projected_inode(mut->ls);
   mut->apply();
+  mds->locker->drop_locks(mut);
   mut->cleanup();
   delete mut;