]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
blk/BlockDevice: changes block device size as atomic
authorJoshua Blanch <joshua.blanch@clyso.com>
Tue, 23 Dec 2025 22:37:52 +0000 (22:37 +0000)
committerJoshua Blanch <joshua.blanch@clyso.com>
Thu, 23 Apr 2026 15:05:55 +0000 (15:05 +0000)
Signed-off-by: Joshua Blanch <joshua.blanch@clyso.com>
src/blk/BlockDevice.h

index 51a39103aa44d47f98b5798a9cf012afc231f1af..58e2afacb75e03952aaa1564c7b666dfd17b0f5e 100644 (file)
@@ -179,7 +179,7 @@ private:
     void *cbpriv, aio_callback_t d_cb, void *d_cbpriv, const char* dev_name);
 
 protected:
-  uint64_t size = 0;
+  std::atomic<uint64_t> size = 0;
   uint64_t block_size = 0;
   uint64_t optimal_io_size = 0;
   bool support_discard = false;