From: Samuel Just Date: Thu, 3 Oct 2024 19:37:08 +0000 (-0700) Subject: crimson: remove unused PG::with_locked_obc X-Git-Tag: v20.0.0~685^2~7 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=177176beabd5121c6d4f1b8f7e5ddadc81dfe944;p=ceph.git crimson: remove unused PG::with_locked_obc Signed-off-by: Samuel Just --- diff --git a/src/crimson/osd/pg.cc b/src/crimson/osd/pg.cc index 5822c4f9a4f58..de39fb4571661 100644 --- a/src/crimson/osd/pg.cc +++ b/src/crimson/osd/pg.cc @@ -1226,31 +1226,6 @@ void PG::check_blocklisted_obc_watchers( } } -PG::load_obc_iertr::future<> -PG::with_locked_obc(const hobject_t &hobj, - const OpInfo &op_info, - with_obc_func_t &&f) -{ - if (__builtin_expect(stopping, false)) { - throw crimson::common::system_shutdown_exception(); - } - const hobject_t oid = get_oid(hobj); - auto wrapper = [f=std::move(f), this](auto head, auto obc) { - check_blocklisted_obc_watchers(obc); - return f(head, obc); - }; - switch (get_lock_type(op_info)) { - case RWState::RWREAD: - return obc_loader.with_obc(oid, std::move(wrapper)); - case RWState::RWWRITE: - return obc_loader.with_obc(oid, std::move(wrapper)); - case RWState::RWEXCL: - return obc_loader.with_obc(oid, std::move(wrapper)); - default: - ceph_abort(); - }; -} - void PG::update_stats(const pg_stat_t &stat) { peering_state.update_stats( [&stat] (auto& history, auto& stats) { diff --git a/src/crimson/osd/pg.h b/src/crimson/osd/pg.h index f7c2d417e4fac..0efb942126a69 100644 --- a/src/crimson/osd/pg.h +++ b/src/crimson/osd/pg.h @@ -590,11 +590,6 @@ public: using with_obc_func_t = std::function (ObjectContextRef, ObjectContextRef)>; - load_obc_iertr::future<> with_locked_obc( - const hobject_t &hobj, - const OpInfo &op_info, - with_obc_func_t&& f); - interruptible_future<> handle_rep_op(Ref m); void update_stats(const pg_stat_t &stat); interruptible_future<> update_snap_map(