From: Samuel Just Date: Mon, 23 Nov 2015 23:40:33 +0000 (-0800) Subject: ReplicatedPG::close_op_ctx: the err argument is unused X-Git-Tag: v10.1.0~277^2~12 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=82896f2c6e2655db8c9a05a7cc31a9e65c9aa350;p=ceph.git ReplicatedPG::close_op_ctx: the err argument is unused Signed-off-by: Samuel Just --- diff --git a/src/osd/ReplicatedPG.cc b/src/osd/ReplicatedPG.cc index a06c5d1a7d40..e0c271869817 100644 --- a/src/osd/ReplicatedPG.cc +++ b/src/osd/ReplicatedPG.cc @@ -160,7 +160,7 @@ public: if (ctx->op) ctx->pg->requeue_op(ctx->op); } - ctx->pg->close_op_ctx(ctx, r); + ctx->pg->close_op_ctx(ctx); } } @@ -2035,13 +2035,13 @@ void ReplicatedPG::do_op(OpRequestRef& op) } else if (!get_rw_locks(write_ordered, ctx)) { dout(20) << __func__ << " waiting for rw locks " << dendl; op->mark_delayed("waiting for rw locks"); - close_op_ctx(ctx, -EBUSY); + close_op_ctx(ctx); return; } if (r) { dout(20) << __func__ << " returned an error: " << r << dendl; - close_op_ctx(ctx, r); + close_op_ctx(ctx); osd->reply_op_error(op, r); return; } @@ -2070,7 +2070,7 @@ void ReplicatedPG::do_op(OpRequestRef& op) classic = true; } fill_in_copy_get_noent(op, oid, m->ops[0], classic); - close_op_ctx(ctx, -ENOENT); + close_op_ctx(ctx); return; } reply_ctx(ctx, -ENOENT); @@ -2894,7 +2894,7 @@ void ReplicatedPG::execute_ctx(OpContext *ctx) if (result == -EAGAIN) { // clean up after the ctx - close_op_ctx(ctx, result); + close_op_ctx(ctx); return; } @@ -3037,14 +3037,14 @@ void ReplicatedPG::reply_ctx(OpContext *ctx, int r) { if (ctx->op) osd->reply_op_error(ctx->op, r); - close_op_ctx(ctx, r); + close_op_ctx(ctx); } void ReplicatedPG::reply_ctx(OpContext *ctx, int r, eversion_t v, version_t uv) { if (ctx->op) osd->reply_op_error(ctx->op, r, v, uv); - close_op_ctx(ctx, r); + close_op_ctx(ctx); } void ReplicatedPG::log_op_stats(OpContext *ctx) @@ -6796,7 +6796,7 @@ void ReplicatedPG::complete_read_ctx(int result, OpContext *ctx) reply->set_result(result); reply->add_flags(CEPH_OSD_FLAG_ACK | CEPH_OSD_FLAG_ONDISK); osd->send_message_osd_client(reply, m->get_connection()); - close_op_ctx(ctx, 0); + close_op_ctx(ctx); } // ======================================================================== @@ -9848,7 +9848,7 @@ void ReplicatedPG::on_change(ObjectStore::Transaction *t) in_progress_async_reads.begin(); i != in_progress_async_reads.end(); in_progress_async_reads.erase(i++)) { - close_op_ctx(i->second, -ECANCELED); + close_op_ctx(i->second); if (is_primary()) requeue_op(i->first); } diff --git a/src/osd/ReplicatedPG.h b/src/osd/ReplicatedPG.h index 60558f7be38a..2e09ebd1b8ce 100644 --- a/src/osd/ReplicatedPG.h +++ b/src/osd/ReplicatedPG.h @@ -804,7 +804,7 @@ protected: * * @param ctx [in] ctx to clean up */ - void close_op_ctx(OpContext *ctx, int r) { + void close_op_ctx(OpContext *ctx) { release_op_ctx_locks(ctx); ctx->op_t.reset(); for (auto p = ctx->on_finish.begin();