* [Qemu-devel] [PATCH] exec: check offset_within_address_space for register subpage
@ 2013-08-29 10:21 Hu Tao
2013-09-03 10:54 ` Paolo Bonzini
0 siblings, 1 reply; 2+ messages in thread
From: Hu Tao @ 2013-08-29 10:21 UTC (permalink / raw)
To: qemu-devel
Cc: Peter Maydell, Paolo Bonzini, Andreas Färber, Blue Swirl,
Richard Henderson
If offset_within_address_space falls in a page, then we register a
subpage. So check offset_within_address_space rather than
offset_within_region.
Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: Richard Henderson <rth@twiddle.net>
Cc: "Andreas Färber" <afaerber@suse.de>
Cc: Peter Maydell <peter.maydell@linaro.org>
Cc: Blue Swirl <blauwirbel@gmail.com>
Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>
---
exec.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/exec.c b/exec.c
index 3ca9381..f1f9151 100644
--- a/exec.c
+++ b/exec.c
@@ -869,7 +869,7 @@ static void mem_add(MemoryListener *listener, MemoryRegionSection *section)
now = remain;
if (int128_lt(remain.size, page_size)) {
register_subpage(d, &now);
- } else if (remain.offset_within_region & ~TARGET_PAGE_MASK) {
+ } else if (remain.offset_within_address_space & ~TARGET_PAGE_MASK) {
now.size = page_size;
register_subpage(d, &now);
} else {
--
1.8.1.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [Qemu-devel] [PATCH] exec: check offset_within_address_space for register subpage
2013-08-29 10:21 [Qemu-devel] [PATCH] exec: check offset_within_address_space for register subpage Hu Tao
@ 2013-09-03 10:54 ` Paolo Bonzini
0 siblings, 0 replies; 2+ messages in thread
From: Paolo Bonzini @ 2013-09-03 10:54 UTC (permalink / raw)
To: Hu Tao
Cc: Blue Swirl, Peter Maydell, qemu-devel, Andreas Färber,
Richard Henderson
Il 29/08/2013 12:21, Hu Tao ha scritto:
> If offset_within_address_space falls in a page, then we register a
> subpage. So check offset_within_address_space rather than
> offset_within_region.
>
> Cc: Paolo Bonzini <pbonzini@redhat.com>
> Cc: Richard Henderson <rth@twiddle.net>
> Cc: "Andreas Färber" <afaerber@suse.de>
> Cc: Peter Maydell <peter.maydell@linaro.org>
> Cc: Blue Swirl <blauwirbel@gmail.com>
> Signed-off-by: Hu Tao <hutao@cn.fujitsu.com>
> ---
> exec.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/exec.c b/exec.c
> index 3ca9381..f1f9151 100644
> --- a/exec.c
> +++ b/exec.c
> @@ -869,7 +869,7 @@ static void mem_add(MemoryListener *listener, MemoryRegionSection *section)
> now = remain;
> if (int128_lt(remain.size, page_size)) {
> register_subpage(d, &now);
> - } else if (remain.offset_within_region & ~TARGET_PAGE_MASK) {
> + } else if (remain.offset_within_address_space & ~TARGET_PAGE_MASK) {
> now.size = page_size;
> register_subpage(d, &now);
> } else {
>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-09-03 10:54 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-08-29 10:21 [Qemu-devel] [PATCH] exec: check offset_within_address_space for register subpage Hu Tao
2013-09-03 10:54 ` Paolo Bonzini
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).