diff options
| author | Peter Maydell <peter.maydell@linaro.org> | 2021-05-24 15:48:08 +0100 |
|---|---|---|
| committer | Peter Maydell <peter.maydell@linaro.org> | 2021-05-24 15:48:08 +0100 |
| commit | 0dab1d36f55c3ed649bb8e4c74b9269ef3a63049 (patch) | |
| tree | 212e624387db446a1bf062305e0851ccac18e4c5 /hw/remote/memory.c | |
| parent | 371ebfe28600fc5a435504b841cd401208a68f07 (diff) | |
| parent | 0a6f0c76a030710780ce10d6347a70f098024d21 (diff) | |
| download | focaccia-qemu-0dab1d36f55c3ed649bb8e4c74b9269ef3a63049.tar.gz focaccia-qemu-0dab1d36f55c3ed649bb8e4c74b9269ef3a63049.zip | |
Merge remote-tracking branch 'remotes/stefanha-gitlab/tags/block-pull-request' into staging
Pull request (Resent due to an email preparation mistake.) # gpg: Signature made Mon 24 May 2021 14:01:42 BST # gpg: using RSA key 8695A8BFD3F97CDAAC35775A9CA4ABB381AB73C8 # gpg: Good signature from "Stefan Hajnoczi <stefanha@redhat.com>" [full] # gpg: aka "Stefan Hajnoczi <stefanha@gmail.com>" [full] # Primary key fingerprint: 8695 A8BF D3F9 7CDA AC35 775A 9CA4 ABB3 81AB 73C8 * remotes/stefanha-gitlab/tags/block-pull-request: coroutine-sleep: introduce qemu_co_sleep coroutine-sleep: replace QemuCoSleepState pointer with struct in the API coroutine-sleep: move timer out of QemuCoSleepState coroutine-sleep: allow qemu_co_sleep_wake that wakes nothing coroutine-sleep: disallow NULL QemuCoSleepState** argument coroutine-sleep: use a stack-allocated timer bitops.h: Improve find_xxx_bit() documentation multi-process: Initialize variables declared with g_auto* Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw/remote/memory.c')
| -rw-r--r-- | hw/remote/memory.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/hw/remote/memory.c b/hw/remote/memory.c index 2d4174614a..472ed2a272 100644 --- a/hw/remote/memory.c +++ b/hw/remote/memory.c @@ -41,10 +41,9 @@ void remote_sysmem_reconfig(MPQemuMsg *msg, Error **errp) remote_sysmem_reset(); - for (region = 0; region < msg->num_fds; region++) { - g_autofree char *name; + for (region = 0; region < msg->num_fds; region++, suffix++) { + g_autofree char *name = g_strdup_printf("remote-mem-%u", suffix); subregion = g_new(MemoryRegion, 1); - name = g_strdup_printf("remote-mem-%u", suffix++); memory_region_init_ram_from_fd(subregion, NULL, name, sysmem_info->sizes[region], true, msg->fds[region], |