]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
librbd/cache/pwl: revert patch 76f4d29d92be3f9f45767cb1ac6cc50.
authorJianpeng Ma <jianpeng.ma@intel.com>
Sun, 28 Nov 2021 05:00:14 +0000 (13:00 +0800)
committerDeepika Upadhyay <dupadhya@redhat.com>
Fri, 10 Dec 2021 07:18:54 +0000 (12:48 +0530)
In fact, After BlockGuard to fix flush reorder issue, patch
76f4d29d9 don't need. So revert.

Signed-off-by: Jianpeng Ma <jianpeng.ma@intel.com>
(cherry picked from commit cc8dae1d89a6cc44f6133a10424d767fc3291dd2)

src/librbd/cache/pwl/AbstractWriteLog.cc
src/librbd/cache/pwl/AbstractWriteLog.h
src/librbd/cache/pwl/rwl/WriteLog.cc
src/librbd/cache/pwl/ssd/WriteLog.cc

index a7ac93153b313328b46b83b69fbcac277427d4d7..ee82d382125e127625dfb488e03641458e2368d8 100644 (file)
@@ -1744,10 +1744,6 @@ void AbstractWriteLog<I>::process_writeback_dirty_entries() {
         break;
       }
 
-      if (m_flush_ops_will_send) {
-       ldout(cct, 20) << "Previous flush-ops is still not sent" << dendl;
-       break;
-      }
       auto candidate = m_dirty_log_entries.front();
       bool flushable = can_flush_entry(candidate);
       if (flushable) {
@@ -1764,7 +1760,6 @@ void AbstractWriteLog<I>::process_writeback_dirty_entries() {
            m_lowest_flushing_sync_gen = candidate->ram_entry.sync_gen_number;
          }
          m_flush_ops_in_flight += 1;
-         m_flush_ops_will_send += 1;
          /* For write same this is the bytes affected by the flush op, not the bytes transferred */
          m_flush_bytes_in_flight += candidate->ram_entry.write_bytes;
        }
index e66562234026ea498ce51a809ed46d4d4c28bddd..e53c632069479abdef2f8541158d820066dcd385 100644 (file)
@@ -296,7 +296,6 @@ protected:
   std::atomic<int> m_async_flush_ops = {0};
   std::atomic<int> m_async_append_ops = {0};
 
-  std::atomic<int> m_flush_ops_will_send = {0};
   /* Acquire locks in order declared here */
 
   mutable ceph::mutex m_log_retire_lock;
index 128add41beb4ef22efd58164ea1114cb63ae863a..78647a98660a390a576d91bd33bde72892e1764c 100644 (file)
@@ -595,7 +595,6 @@ void WriteLog<I>::construct_flush_entries(pwl::GenericLogEntries entries_to_flus
                  ldout(m_image_ctx.cct, 15) << "flushing:" << log_entry
                                             << " " << *log_entry << dendl;
                  log_entry->writeback(this->m_image_writeback, ctx);
-                 this->m_flush_ops_will_send -= 1;
              }), 0);
          });
        }
index 62445d8f8bc6584751556fc96eacf5b51101f182..fdec734d39e1f8878d9b14e13f8d577d4d7fe956 100644 (file)
@@ -563,7 +563,6 @@ void WriteLog<I>::construct_flush_entries(pwl::GenericLogEntries entries_to_flus
                    ldout(m_image_ctx.cct, 15) << "flushing:" << log_entry
                                                << " " << *log_entry << dendl;
                    log_entry->writeback(this->m_image_writeback, ctx);
-                   this->m_flush_ops_will_send -= 1;
                  }), 0);
              });
             }
@@ -612,7 +611,6 @@ void WriteLog<I>::construct_flush_entries(pwl::GenericLogEntries entries_to_flus
                                               << " " << *log_entry << dendl;
                    log_entry->writeback_bl(this->m_image_writeback, ctx,
                                             std::move(captured_entry_bl));
-                   this->m_flush_ops_will_send -= 1;
                  }), 0);
              });
          } else {
@@ -625,7 +623,6 @@ void WriteLog<I>::construct_flush_entries(pwl::GenericLogEntries entries_to_flus
                    ldout(m_image_ctx.cct, 15) << "flushing:" << log_entry
                                                << " " << *log_entry << dendl;
                    log_entry->writeback(this->m_image_writeback, ctx);
-                   this->m_flush_ops_will_send -= 1;
                  }), 0);
             });
          }