+--- ceph-15.2.16/src/tools/rbd_mirror/image_replayer/snapshot/Replayer.cc.orig 2022-03-01 07:44:29.000000000 +0100
++++ ceph-15.2.16/src/tools/rbd_mirror/image_replayer/snapshot/Replayer.cc 2022-06-13 06:26:31.761657298 +0200
+@@ -253,7 +253,7 @@ bool Replayer<I>::get_replay_status(std:
+
+ json_spirit::mObject root_obj;
+ root_obj["replay_state"] = replay_state;
+- root_obj["remote_snapshot_timestamp"] = remote_snap_info->timestamp.sec();
++ root_obj["remote_snapshot_timestamp"] = static_cast<int64_t>(remote_snap_info->timestamp.sec());
+
+ auto matching_remote_snap_id = util::compute_remote_snap_id(
+ m_state_builder->local_image_ctx->image_lock,
+@@ -268,7 +268,7 @@ bool Replayer<I>::get_replay_status(std:
+ // the local snapshot would just be the time the snapshot was
+ // synced and not the consistency point in time.
+ root_obj["local_snapshot_timestamp"] =
+- matching_remote_snap_it->second.timestamp.sec();
++ static_cast<int64_t>(matching_remote_snap_it->second.timestamp.sec());
+ }
+
+ matching_remote_snap_it = m_state_builder->remote_image_ctx->snap_info.find(
+@@ -276,7 +276,7 @@ bool Replayer<I>::get_replay_status(std:
+ if (m_remote_snap_id_end != CEPH_NOSNAP &&
+ matching_remote_snap_it !=
+ m_state_builder->remote_image_ctx->snap_info.end()) {
+- root_obj["syncing_snapshot_timestamp"] = remote_snap_info->timestamp.sec();
++ root_obj["syncing_snapshot_timestamp"] = static_cast<int64_t>(remote_snap_info->timestamp.sec());
+ root_obj["syncing_percent"] = static_cast<uint64_t>(
+ 100 * m_local_mirror_snap_ns.last_copied_object_number /
+ static_cast<float>(std::max<uint64_t>(1U, m_local_object_count)));
+--- ceph-15.2.16/src/librbd/object_map/DiffRequest.cc.orig 2022-03-01 07:44:29.000000000 +0100
++++ ceph-15.2.16/src/librbd/object_map/DiffRequest.cc 2022-06-13 06:09:45.790195571 +0200
+@@ -187,7 +187,7 @@ void DiffRequest<I>::handle_load_object_
+ m_object_map.resize(m_object_diff_state->size());
+ }
+
+- uint64_t overlap = std::min(m_object_map.size(), prev_object_diff_state_size);
++ uint64_t overlap = std::min<uint64_t>(m_object_map.size(), prev_object_diff_state_size);
+ auto it = m_object_map.begin();
+ auto overlap_end_it = it + overlap;
+ auto diff_it = m_object_diff_state->begin();