From: Paolo Bonzini <pbonzini@redhat.com>
To: qemu-devel@nongnu.org
Cc: dgilbert@redhat.com
Subject: [Qemu-devel] [PATCH 1/4] memory: remove memory_region_test_and_clear_dirty
Date: Fri, 9 Feb 2018 11:45:43 +0100 [thread overview]
Message-ID: <20180209104546.29401-2-pbonzini@redhat.com> (raw)
In-Reply-To: <20180209104546.29401-1-pbonzini@redhat.com>
It is unused after g364fb has been converted to use DirtyBitmapSnapshot.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
include/exec/memory.h | 24 +++---------------------
memory.c | 8 --------
2 files changed, 3 insertions(+), 29 deletions(-)
diff --git a/include/exec/memory.h b/include/exec/memory.h
index 783ef64570..6779d14a7b 100644
--- a/include/exec/memory.h
+++ b/include/exec/memory.h
@@ -1090,33 +1090,15 @@ bool memory_region_get_dirty(MemoryRegion *mr, hwaddr addr,
void memory_region_set_dirty(MemoryRegion *mr, hwaddr addr,
hwaddr size);
-/**
- * memory_region_test_and_clear_dirty: Check whether a range of bytes is dirty
- * for a specified client. It clears them.
- *
- * Checks whether a range of bytes has been written to since the last
- * call to memory_region_reset_dirty() with the same @client. Dirty logging
- * must be enabled.
- *
- * @mr: the memory region being queried.
- * @addr: the address (relative to the start of the region) being queried.
- * @size: the size of the range being queried.
- * @client: the user of the logging information; %DIRTY_MEMORY_MIGRATION or
- * %DIRTY_MEMORY_VGA.
- */
-bool memory_region_test_and_clear_dirty(MemoryRegion *mr, hwaddr addr,
- hwaddr size, unsigned client);
-
/**
* memory_region_snapshot_and_clear_dirty: Get a snapshot of the dirty
* bitmap and clear it.
*
* Creates a snapshot of the dirty bitmap, clears the dirty bitmap and
* returns the snapshot. The snapshot can then be used to query dirty
- * status, using memory_region_snapshot_get_dirty. Unlike
- * memory_region_test_and_clear_dirty this allows to query the same
- * page multiple times, which is especially useful for display updates
- * where the scanlines often are not page aligned.
+ * status, using memory_region_snapshot_get_dirty. Snapshotting allows
+ * querying the same page multiple times, which is especially useful for
+ * display updates where the scanlines often are not page aligned.
*
* The dirty bitmap region which gets copyed into the snapshot (and
* cleared afterwards) can be larger than requested. The boundaries
diff --git a/memory.c b/memory.c
index 93258a6655..9e75bb9526 100644
--- a/memory.c
+++ b/memory.c
@@ -1971,14 +1971,6 @@ void memory_region_set_dirty(MemoryRegion *mr, hwaddr addr,
memory_region_get_dirty_log_mask(mr));
}
-bool memory_region_test_and_clear_dirty(MemoryRegion *mr, hwaddr addr,
- hwaddr size, unsigned client)
-{
- assert(mr->ram_block);
- return cpu_physical_memory_test_and_clear_dirty(
- memory_region_get_ram_addr(mr) + addr, size, client);
-}
-
DirtyBitmapSnapshot *memory_region_snapshot_and_clear_dirty(MemoryRegion *mr,
hwaddr addr,
hwaddr size,
--
2.14.3
next prev parent reply other threads:[~2018-02-09 10:46 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-09 10:45 [Qemu-devel] [PATCH 0/4] tcg: fix dirty bitmap race with MTTCG Paolo Bonzini
2018-02-09 10:45 ` Paolo Bonzini [this message]
2018-02-09 20:13 ` [Qemu-devel] [PATCH 1/4] memory: remove memory_region_test_and_clear_dirty Richard Henderson
2018-02-09 10:45 ` [Qemu-devel] [PATCH 2/4] memory: hide memory_region_sync_dirty_bitmap behind DirtyBitmapSnapshot Paolo Bonzini
2018-02-09 20:16 ` Richard Henderson
2018-02-09 10:45 ` [Qemu-devel] [PATCH 3/4] memory: introduce memory_global_after_dirty_log_sync Paolo Bonzini
2018-02-09 20:20 ` Richard Henderson
2018-02-09 10:45 ` [Qemu-devel] [PATCH 4/4] memory: unify loops to sync dirty log bitmap Paolo Bonzini
2018-02-09 20:23 ` Richard Henderson
2018-02-09 11:02 ` [Qemu-devel] [PATCH 0/4] tcg: fix dirty bitmap race with MTTCG no-reply
2018-02-09 11:33 ` no-reply
2018-02-09 11:33 ` no-reply
2018-02-09 20:27 ` Dr. David Alan Gilbert
2018-02-13 11:10 ` Dr. David Alan Gilbert
2018-10-30 12:21 ` Alex Bennée
2018-10-30 13:48 ` Paolo Bonzini
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20180209104546.29401-2-pbonzini@redhat.com \
--to=pbonzini@redhat.com \
--cc=dgilbert@redhat.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).