]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
clien: rados: bench: remove unused variables
authorGreg Farnum <gregory.farnum@dreamhost.com>
Mon, 18 Jul 2011 20:19:57 +0000 (13:19 -0700)
committerGreg Farnum <gregory.farnum@dreamhost.com>
Mon, 18 Jul 2011 20:24:41 +0000 (13:24 -0700)
Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
src/client/Client.cc
src/osdc/rados_bencher.h
src/rados.cc

index 08d04cd0d38bef86813b4a097f3bb263ae422105..e293b3f1127ced883255edff9cee46d9daa8b74c 100644 (file)
@@ -996,16 +996,6 @@ int Client::make_request(MetaRequest *request,
                         int use_mds,
                         bufferlist *pdirbl)
 {
-  // time the call
-  utime_t start = ceph_clock_now(cct);
-  
-  bool nojournal = false;
-  int op = request->get_op();
-  if (op == CEPH_MDS_OP_GETATTR ||
-      op == CEPH_MDS_OP_READDIR ||
-      op == CEPH_MDS_OP_OPEN)
-    nojournal = true;
-
   // assign a unique tid
   tid_t tid = ++last_tid;
   request->set_tid(tid);
@@ -1529,10 +1519,6 @@ bool Client::ms_dispatch(Message *m)
 
 void Client::handle_mds_map(MMDSMap* m)
 {
-  int frommds = -1;
-  if (m->get_source().is_mds())
-    frommds = m->get_source().num();
-
   if (m->get_epoch() < mdsmap->get_epoch()) {
     ldout(cct, 1) << "handle_mds_map epoch " << m->get_epoch() << " is older than our "
            << mdsmap->get_epoch() << dendl;
@@ -3013,7 +2999,6 @@ void Client::handle_cap_grant(Inode *in, int mds, InodeCap *cap, MClientCaps *m)
                         m->get_time_warp_seq(), m->get_ctime(), m->get_mtime(), m->get_atime(), issued);
 
   // max_size
-  bool kick_writers = false;
   if (cap == in->auth_cap &&
       m->get_max_size() != in->max_size) {
     ldout(cct, 10) << "max_size " << in->max_size << " -> " << m->get_max_size() << dendl;
@@ -3022,7 +3007,6 @@ void Client::handle_cap_grant(Inode *in, int mds, InodeCap *cap, MClientCaps *m)
       in->wanted_max_size = 0;
       in->requested_max_size = 0;
     }
-    kick_writers = true;
   }
 
   check_cap_issue(in, cap, issued);
index 9420fb4cbfc1b51b1017b5252d6edff5d7219a4e..d0be2a735a3d7b88562544f1e3205d130b6d76c0 100644 (file)
@@ -294,9 +294,6 @@ int write_bench(librados::Rados& rados, librados::IoCtx& io_ctx,
        << "Min latency:           " << data->min_latency << std::endl;
 
   //write object size/number data for read benchmarks
-  int written_objects[2];
-  written_objects[0] = data->object_size;
-  written_objects[1] = data->finished;
   ::encode(data->object_size, b_write);
   ::encode(data->finished, b_write);
   ::encode(getpid(), b_write);
index bbe1b6e8867d7f96e79cf0bcea20eae81448a7a1..8d53e085c1214b5305cf0cc3bcf31ee0326b9672 100644 (file)
@@ -416,18 +416,17 @@ int LoadGen::bootstrap(const char *pool)
 void LoadGen::run_op(LoadGenOp *op)
 {
   op->completion = rados->aio_create_completion(op, _load_gen_cb, NULL);
-  int ret;
 
   switch (op->type) {
   case OP_READ:
-    ret = io_ctx.aio_read(op->oid, op->completion, &op->bl, op->len, op->off);
+    io_ctx.aio_read(op->oid, op->completion, &op->bl, op->len, op->off);
     break;
   case OP_WRITE:
     bufferptr p = buffer::create(op->len);
     memset(p.c_str(), 0, op->len);
     op->bl.push_back(p);
     
-    ret = io_ctx.aio_write(op->oid, op->completion, op->bl, op->len, op->off);
+    io_ctx.aio_write(op->oid, op->completion, op->bl, op->len, op->off);
     break;
   }