mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 16:23:55 -06:00
hw/mips: Use the IEC binary prefix definitions
It eases code review, unit is explicit. Patch generated using: $ git grep -E '(1024|2048|4096|8192|(<<|>>).?(10|20|30))' hw/ include/hw/ $ git grep -n '[<>][<>]= ?[1-5]0' and modified manually. Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by: Alistair Francis <alistair.francis@wdc.com> Message-Id: <20180625124238.25339-31-f4bug@amsat.org> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
parent
27773d8eee
commit
be01029e5d
7 changed files with 33 additions and 24 deletions
|
@ -18,6 +18,7 @@
|
|||
*/
|
||||
|
||||
#include "qemu/osdep.h"
|
||||
#include "qemu/units.h"
|
||||
#include "qemu/log.h"
|
||||
#include "qapi/error.h"
|
||||
#include "cpu.h"
|
||||
|
@ -80,7 +81,7 @@ static void itc_reconfigure(MIPSITUState *tag)
|
|||
uint64_t *am = &tag->ITCAddressMap[0];
|
||||
MemoryRegion *mr = &tag->storage_io;
|
||||
hwaddr address = am[0] & ITC_AM0_BASE_ADDRESS_MASK;
|
||||
uint64_t size = (1 << 10) + (am[1] & ITC_AM1_ADDR_MASK_MASK);
|
||||
uint64_t size = (1 * KiB) + (am[1] & ITC_AM1_ADDR_MASK_MASK);
|
||||
bool is_enabled = (am[0] & ITC_AM0_EN_MASK) != 0;
|
||||
|
||||
memory_region_transaction_begin();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue