[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-trivial] [PATCH v2 12/30] hw/hppa: use the BYTE-based definitions
From: |
Philippe Mathieu-Daudé |
Subject: |
[Qemu-trivial] [PATCH v2 12/30] hw/hppa: use the BYTE-based definitions |
Date: |
Mon, 5 Mar 2018 08:27:14 -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>
---
hw/hppa/dino.c | 2 +-
hw/hppa/machine.c | 8 ++++----
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/hw/hppa/dino.c b/hw/hppa/dino.c
index 15aefde09c..7728123cc8 100644
--- a/hw/hppa/dino.c
+++ b/hw/hppa/dino.c
@@ -76,7 +76,7 @@
/* #define xxx 0x200 - bit 9 not used */
#define RS232INT 0x400
-#define DINO_MEM_CHUNK_SIZE (8 * 1024 * 1024) /* 8MB */
+#define DINO_MEM_CHUNK_SIZE (8 * M_BYTE)
#define DINO_PCI_HOST_BRIDGE(obj) \
OBJECT_CHECK(DinoState, (obj), TYPE_DINO_PCI_HOST_BRIDGE)
diff --git a/hw/hppa/machine.c b/hw/hppa/machine.c
index 22a15112df..8fd364ad43 100644
--- a/hw/hppa/machine.c
+++ b/hw/hppa/machine.c
@@ -177,8 +177,8 @@ static void machine_hppa_init(MachineState *machine)
}
qemu_log_mask(CPU_LOG_PAGE, "Kernel loaded at 0x%08" PRIx64
"-0x%08" PRIx64 ", entry at 0x%08" PRIx64
- ", size %ld kB.\n",
- kernel_low, kernel_high, kernel_entry, size / 1024);
+ ", size %llu kB\n",
+ kernel_low, kernel_high, kernel_entry, size / K_BYTE);
if (kernel_cmdline) {
cpu[0]->env.gr[24] = 0x4000;
@@ -202,8 +202,8 @@ static void machine_hppa_init(MachineState *machine)
(1) Due to sign-extension problems and PDC,
put the initrd no higher than 1G.
(2) Reserve 64k for stack. */
- initrd_base = MIN(ram_size, 1024 * 1024 * 1024);
- initrd_base = initrd_base - 64 * 1024;
+ initrd_base = MIN(ram_size, 1 * G_BYTE);
+ initrd_base = initrd_base - 64 * K_BYTE;
initrd_base = (initrd_base - initrd_size) & TARGET_PAGE_MASK;
if (initrd_base < kernel_high) {
--
2.16.2
- [Qemu-trivial] [PATCH v2 06/30] hw/mips: use the BYTE-based definitions, (continued)
- [Qemu-trivial] [PATCH v2 06/30] hw/mips: use the BYTE-based definitions, Philippe Mathieu-Daudé, 2018/03/05
- [Qemu-trivial] [PATCH v2 07/30] hw/arm: use the BYTE-based definitions, Philippe Mathieu-Daudé, 2018/03/05
- [Qemu-trivial] [PATCH v2 08/30] hw/i386: use the BYTE-based definitions, Philippe Mathieu-Daudé, 2018/03/05
- [Qemu-trivial] [PATCH v2 09/30] hw/sparc: use the BYTE-based definitions, Philippe Mathieu-Daudé, 2018/03/05
- [Qemu-trivial] [PATCH v2 10/30] hw/ppc: use the BYTE-based definitions, Philippe Mathieu-Daudé, 2018/03/05
- [Qemu-trivial] [PATCH v2 11/30] hw/s390x: use the BYTE-based definitions, Philippe Mathieu-Daudé, 2018/03/05
- [Qemu-trivial] [PATCH v2 13/30] hw/xtensa: use the BYTE-based definitions, Philippe Mathieu-Daudé, 2018/03/05
- [Qemu-trivial] [PATCH v2 12/30] hw/hppa: use the BYTE-based definitions,
Philippe Mathieu-Daudé <=
- [Qemu-trivial] [PATCH v2 15/30] hw/lm32: use the BYTE-based definitions, Philippe Mathieu-Daudé, 2018/03/05
- [Qemu-trivial] [PATCH v2 17/30] hw/tricore: use the BYTE-based definitions, Philippe Mathieu-Daudé, 2018/03/05
- [Qemu-trivial] [PATCH v2 14/30] hw/alpha: use the BYTE-based definitions, Philippe Mathieu-Daudé, 2018/03/05
- [Qemu-trivial] [PATCH v2 16/30] hw/sh4: use the BYTE-based definitions, Philippe Mathieu-Daudé, 2018/03/05
- [Qemu-trivial] [PATCH v2 18/30] hw/microblaze: use the BYTE-based definitions, Philippe Mathieu-Daudé, 2018/03/05
- [Qemu-trivial] [PATCH v2 19/30] hw/nios2: use the BYTE-based definitions, Philippe Mathieu-Daudé, 2018/03/05
- [Qemu-trivial] [PATCH v2 20/30] hw/cris: use the BYTE-based definitions, Philippe Mathieu-Daudé, 2018/03/05
- [Qemu-trivial] [PATCH v2 21/30] hw/misc: use the BYTE-based definitions, Philippe Mathieu-Daudé, 2018/03/05
- [Qemu-trivial] [PATCH v2 25/30] hw/scsi: use the BYTE-based definitions, Philippe Mathieu-Daudé, 2018/03/05