[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-trivial] [PATCH v5 23/46] hw/tricore: Use the IEC binary prefix de
From: |
Philippe Mathieu-Daudé |
Subject: |
[Qemu-trivial] [PATCH v5 23/46] hw/tricore: Use the IEC binary prefix definitions |
Date: |
Mon, 25 Jun 2018 09:42:15 -0300 |
It eases code review, unit is explicit.
Patch generated using:
$ git grep -E '(1024|2048|4096|8192|(<<|>>).?(10|20|30))' hw/ include/hw/
and modified manually.
Signed-off-by: Philippe Mathieu-Daudé <address@hidden>
Acked-by: Bastian Koppelmann <address@hidden>
---
hw/tricore/tricore_testboard.c | 13 +++++++------
1 file changed, 7 insertions(+), 6 deletions(-)
diff --git a/hw/tricore/tricore_testboard.c b/hw/tricore/tricore_testboard.c
index 8e61dfc3e6..a58096f05e 100644
--- a/hw/tricore/tricore_testboard.c
+++ b/hw/tricore/tricore_testboard.c
@@ -19,6 +19,7 @@
#include "qemu/osdep.h"
+#include "qemu/units.h"
#include "qapi/error.h"
#include "qemu-common.h"
#include "cpu.h"
@@ -72,17 +73,17 @@ static void tricore_testboard_init(MachineState *machine,
int board_id)
cpu = TRICORE_CPU(cpu_create(machine->cpu_type));
env = &cpu->env;
memory_region_init_ram(ext_cram, NULL, "powerlink_ext_c.ram",
- 2 * 1024 * 1024, &error_fatal);
+ 2 * MiB, &error_fatal);
memory_region_init_ram(ext_dram, NULL, "powerlink_ext_d.ram",
- 4 * 1024 * 1024, &error_fatal);
- memory_region_init_ram(int_cram, NULL, "powerlink_int_c.ram", 48 * 1024,
+ 4 * MiB, &error_fatal);
+ memory_region_init_ram(int_cram, NULL, "powerlink_int_c.ram", 48 * KiB,
&error_fatal);
- memory_region_init_ram(int_dram, NULL, "powerlink_int_d.ram", 48 * 1024,
+ memory_region_init_ram(int_dram, NULL, "powerlink_int_d.ram", 48 * KiB,
&error_fatal);
memory_region_init_ram(pcp_data, NULL, "powerlink_pcp_data.ram",
- 16 * 1024, &error_fatal);
+ 16 * KiB, &error_fatal);
memory_region_init_ram(pcp_text, NULL, "powerlink_pcp_text.ram",
- 32 * 1024, &error_fatal);
+ 32 * KiB, &error_fatal);
memory_region_add_subregion(sysmem, 0x80000000, ext_cram);
memory_region_add_subregion(sysmem, 0xa1000000, ext_dram);
--
2.18.0
- [Qemu-trivial] [PATCH v5 19/46] hw/s390x: Use the IEC binary prefix definitions, (continued)
- [Qemu-trivial] [PATCH v5 21/46] hw/xtensa: Use the IEC binary prefix definitions, Philippe Mathieu-Daudé, 2018/06/25
- [Qemu-trivial] [PATCH v5 22/46] hw/alpha: Use the IEC binary prefix definitions, Philippe Mathieu-Daudé, 2018/06/25
- [Qemu-trivial] [PATCH v5 24/46] hw/microblaze: Use the IEC binary prefix definitions, Philippe Mathieu-Daudé, 2018/06/25
- [Qemu-trivial] [PATCH v5 23/46] hw/tricore: Use the IEC binary prefix definitions,
Philippe Mathieu-Daudé <=
- [Qemu-trivial] [PATCH v5 25/46] hw/nios2: Use the IEC binary prefix definitions, Philippe Mathieu-Daudé, 2018/06/25
- [Qemu-trivial] [PATCH v5 26/46] hw/cris: Use the IEC binary prefix definitions, Philippe Mathieu-Daudé, 2018/06/25
- [Qemu-trivial] [PATCH v5 28/46] hw/sh4: Use the IEC binary prefix definitions, Philippe Mathieu-Daudé, 2018/06/25
- [Qemu-trivial] [PATCH v5 27/46] hw/lm32: Use the IEC binary prefix definitions, Philippe Mathieu-Daudé, 2018/06/25
- [Qemu-trivial] [PATCH v5 29/46] hw/mips/r4k: Constify params_size, Philippe Mathieu-Daudé, 2018/06/25
- [Qemu-trivial] [PATCH v5 30/46] hw/mips: Use the IEC binary prefix definitions, Philippe Mathieu-Daudé, 2018/06/25