]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
blk/zoned: do not use g_ceph_context for reading conf 36054/head
authorKefu Chai <kchai@redhat.com>
Mon, 13 Jul 2020 03:19:53 +0000 (11:19 +0800)
committerKefu Chai <kchai@redhat.com>
Mon, 13 Jul 2020 03:19:55 +0000 (11:19 +0800)
use local `cct` instead, more consistent this way

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/blk/zoned/HMSMRDevice.cc

index fcf36c833c543a54b88d3ce97e1646ea4d7e81b4..3ae72c35f836b3a91d67f25691e7f4c9c1874547 100644 (file)
@@ -34,7 +34,6 @@
 #include "common/debug.h"
 #include "common/numa.h"
 
-#include "global/global_context.h"
 #include "kernel/io_uring.h"
 
 extern "C" {
@@ -61,7 +60,7 @@ HMSMRDevice::HMSMRDevice(CephContext* cct, aio_callback_t cb, void *cbpriv, aio_
   fd_directs.resize(WRITE_LIFE_MAX, -1);
   fd_buffereds.resize(WRITE_LIFE_MAX, -1);
 
-  bool use_ioring = g_ceph_context->_conf.get_val<bool>("bluestore_ioring");
+  bool use_ioring = cct->_conf.get_val<bool>("bluestore_ioring");
   unsigned int iodepth = cct->_conf->bdev_aio_max_queue_depth;
 
   if (use_ioring && ioring_queue_t::supported()) {