From: liguang <lig.fnst@cn.fujitsu.com>
To: qemu-devel@nongnu.org, qemu-trivial@nongnu.org
Cc: liguang <lig.fnst@cn.fujitsu.com>
Subject: [Qemu-devel] [PATCH 4/5] memory: use '=' instead of '|=' for memory_region_update_pending
Date: Tue, 11 Jun 2013 13:15:19 +0800 [thread overview]
Message-ID: <1370927720-4348-4-git-send-email-lig.fnst@cn.fujitsu.com> (raw)
In-Reply-To: <1370927720-4348-1-git-send-email-lig.fnst@cn.fujitsu.com>
because memory_region_update_pending is bool
Signed-off-by: liguang <lig.fnst@cn.fujitsu.com>
---
memory.c | 18 +++++++++---------
1 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/memory.c b/memory.c
index 5cb8f4a..d99eecd 100644
--- a/memory.c
+++ b/memory.c
@@ -1114,7 +1114,7 @@ void memory_region_set_log(MemoryRegion *mr, bool log, unsigned client)
memory_region_transaction_begin();
mr->dirty_log_mask = (mr->dirty_log_mask & ~mask) | (log * mask);
- memory_region_update_pending |= mr->enabled;
+ memory_region_update_pending = mr->enabled;
memory_region_transaction_commit();
}
@@ -1168,7 +1168,7 @@ void memory_region_set_readonly(MemoryRegion *mr, bool readonly)
if (mr->readonly != readonly) {
memory_region_transaction_begin();
mr->readonly = readonly;
- memory_region_update_pending |= mr->enabled;
+ memory_region_update_pending = mr->enabled;
memory_region_transaction_commit();
}
}
@@ -1178,7 +1178,7 @@ void memory_region_rom_device_set_romd(MemoryRegion *mr, bool romd_mode)
if (mr->romd_mode != romd_mode) {
memory_region_transaction_begin();
mr->romd_mode = romd_mode;
- memory_region_update_pending |= mr->enabled;
+ memory_region_update_pending = mr->enabled;
memory_region_transaction_commit();
}
}
@@ -1321,7 +1321,7 @@ void memory_region_add_eventfd(MemoryRegion *mr,
memmove(&mr->ioeventfds[i+1], &mr->ioeventfds[i],
sizeof(*mr->ioeventfds) * (mr->ioeventfd_nb-1 - i));
mr->ioeventfds[i] = mrfd;
- memory_region_update_pending |= mr->enabled;
+ memory_region_update_pending = mr->enabled;
memory_region_transaction_commit();
}
@@ -1354,7 +1354,7 @@ void memory_region_del_eventfd(MemoryRegion *mr,
--mr->ioeventfd_nb;
mr->ioeventfds = g_realloc(mr->ioeventfds,
sizeof(*mr->ioeventfds)*mr->ioeventfd_nb + 1);
- memory_region_update_pending |= mr->enabled;
+ memory_region_update_pending = mr->enabled;
memory_region_transaction_commit();
}
@@ -1398,7 +1398,7 @@ static void memory_region_add_subregion_common(MemoryRegion *mr,
}
QTAILQ_INSERT_TAIL(&mr->subregions, subregion, subregions_link);
done:
- memory_region_update_pending |= mr->enabled && subregion->enabled;
+ memory_region_update_pending = mr->enabled && subregion->enabled;
memory_region_transaction_commit();
}
@@ -1429,7 +1429,7 @@ void memory_region_del_subregion(MemoryRegion *mr,
assert(subregion->parent == mr);
subregion->parent = NULL;
QTAILQ_REMOVE(&mr->subregions, subregion, subregions_link);
- memory_region_update_pending |= mr->enabled && subregion->enabled;
+ memory_region_update_pending = mr->enabled && subregion->enabled;
memory_region_transaction_commit();
}
@@ -1475,7 +1475,7 @@ void memory_region_set_alias_offset(MemoryRegion *mr, hwaddr offset)
memory_region_transaction_begin();
mr->alias_offset = offset;
- memory_region_update_pending |= mr->enabled;
+ memory_region_update_pending = mr->enabled;
memory_region_transaction_commit();
}
@@ -1634,7 +1634,7 @@ void address_space_init(AddressSpace *as, MemoryRegion *root)
QTAILQ_INSERT_TAIL(&address_spaces, as, address_spaces_link);
as->name = NULL;
address_space_init_dispatch(as);
- memory_region_update_pending |= root->enabled;
+ memory_region_update_pending = root->enabled;
memory_region_transaction_commit();
}
--
1.7.2.5
next prev parent reply other threads:[~2013-06-11 5:18 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-06-11 5:15 [Qemu-devel] [PATCH 1/5] vnc: pass bool pararmeter for vnc_connect liguang
2013-06-11 5:15 ` [Qemu-devel] [PATCH 2/5] vnc: pass bool parameter for vnc_listen_read liguang
2013-06-11 11:36 ` Andreas Färber
2013-06-11 5:15 ` [Qemu-devel] [PATCH 3/5] qemu-char: pass bool parameter for qemu_opt_get_bool liguang
2013-06-11 11:35 ` [Qemu-devel] [Qemu-trivial] " Michael Tokarev
2013-06-18 2:33 ` li guang
2013-06-11 5:15 ` liguang [this message]
2013-06-11 11:34 ` [Qemu-devel] [Qemu-trivial] [PATCH 4/5] memory: use '=' instead of '|=' for memory_region_update_pending Michael Tokarev
2013-06-18 2:32 ` li guang
2013-06-18 3:50 ` Michael Tokarev
2013-06-18 4:08 ` li guang
2013-06-11 5:15 ` [Qemu-devel] [PATCH 5/5] sd: pass bool parameter for sd_init liguang
2013-06-11 11:39 ` [Qemu-devel] [PATCH 1/5] vnc: pass bool pararmeter for vnc_connect Andreas Färber
2013-06-11 11:50 ` [Qemu-devel] [Qemu-trivial] " Michael Tokarev
2013-06-18 2:34 ` li guang
2013-06-18 2:35 ` Michael Tokarev
2013-06-18 2:36 ` li guang
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=1370927720-4348-4-git-send-email-lig.fnst@cn.fujitsu.com \
--to=lig.fnst@cn.fujitsu.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-trivial@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).