[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v2 12/13] Use unsigned types for the 'len' argument
From: |
Martin Galvan |
Subject: |
[Qemu-devel] [PATCH v2 12/13] Use unsigned types for the 'len' argument of all memory read/write functions |
Date: |
Tue, 1 Mar 2016 12:57:38 -0300 |
---
include/hw/sparc/sun4m.h | 6 +++---
target-sparc/cpu.h | 2 +-
target-sparc/mmu_helper.c | 6 +++---
3 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/include/hw/sparc/sun4m.h b/include/hw/sparc/sun4m.h
index 9c17425..fe0de1e 100644
--- a/include/hw/sparc/sun4m.h
+++ b/include/hw/sparc/sun4m.h
@@ -9,17 +9,17 @@
/* iommu.c */
void sparc_iommu_memory_rw(void *opaque, hwaddr addr,
- uint8_t *buf, int len, int is_write);
+ uint8_t *buf, size_t len, int is_write);
static inline void sparc_iommu_memory_read(void *opaque,
hwaddr addr,
- uint8_t *buf, int len)
+ uint8_t *buf, size_t len)
{
sparc_iommu_memory_rw(opaque, addr, buf, len, 0);
}
static inline void sparc_iommu_memory_write(void *opaque,
hwaddr addr,
- uint8_t *buf, int len)
+ uint8_t *buf, size_t len)
{
sparc_iommu_memory_rw(opaque, addr, buf, len, 1);
}
diff --git a/target-sparc/cpu.h b/target-sparc/cpu.h
index dc46122..49c458c 100644
--- a/target-sparc/cpu.h
+++ b/target-sparc/cpu.h
@@ -521,7 +521,7 @@ void dump_mmu(FILE *f, fprintf_function cpu_fprintf,
CPUSPARCState *env);
#if !defined(TARGET_SPARC64) && !defined(CONFIG_USER_ONLY)
int sparc_cpu_memory_rw_debug(CPUState *cpu, vaddr addr,
- uint8_t *buf, int len, bool is_write);
+ uint8_t *buf, size_t len, bool is_write);
#endif
diff --git a/target-sparc/mmu_helper.c b/target-sparc/mmu_helper.c
index aa80c48..ac95f85 100644
--- a/target-sparc/mmu_helper.c
+++ b/target-sparc/mmu_helper.c
@@ -358,13 +358,13 @@ void dump_mmu(FILE *f, fprintf_function cpu_fprintf,
CPUSPARCState *env)
* that the sparc ABI is followed.
*/
int sparc_cpu_memory_rw_debug(CPUState *cs, vaddr address,
- uint8_t *buf, int len, bool is_write)
+ uint8_t *buf, size_t len, bool is_write)
{
SPARCCPU *cpu = SPARC_CPU(cs);
CPUSPARCState *env = &cpu->env;
target_ulong addr = address;
- int i;
- int len1;
+ size_t i;
+ size_t len1;
int cwp = env->cwp;
if (!is_write) {
--
2.7.1
- [Qemu-devel] [PATCH v2 02/13] Use unsigned types for the 'len' argument of all memory read/write functions, (continued)
- [Qemu-devel] [PATCH v2 02/13] Use unsigned types for the 'len' argument of all memory read/write functions, Martin Galvan, 2016/03/01
- [Qemu-devel] [PATCH v2 04/13] Use unsigned types for the 'len' argument of all memory read/write functions, Martin Galvan, 2016/03/01
- [Qemu-devel] [PATCH v2 05/13] Use unsigned types for the 'len' argument of all memory read/write functions, Martin Galvan, 2016/03/01
- [Qemu-devel] [PATCH v2 06/13] Use unsigned types for the 'len' argument of all memory read/write functions, Martin Galvan, 2016/03/01
- [Qemu-devel] [PATCH v2 07/13] Use unsigned types for the 'len' argument of all memory read/write functions, Martin Galvan, 2016/03/01
- [Qemu-devel] [PATCH v2 08/13] Use unsigned types for the 'len' argument of all memory read/write functions, Martin Galvan, 2016/03/01
- [Qemu-devel] [PATCH v2 09/13] Use unsigned types for the 'len' argument of all memory read/write functions, Martin Galvan, 2016/03/01
- [Qemu-devel] [PATCH v2 10/13] Use unsigned types for the 'len' argument of all memory read/write functions, Martin Galvan, 2016/03/01
- [Qemu-devel] [PATCH v2 11/13] Use unsigned types for the 'len' argument of all memory read/write functions, Martin Galvan, 2016/03/01
- [Qemu-devel] [PATCH v2 12/13] Use unsigned types for the 'len' argument of all memory read/write functions,
Martin Galvan <=
- [Qemu-devel] [PATCH v2 13/13] Use unsigned types for the 'len' argument of all memory read/write functions, Martin Galvan, 2016/03/01
- Re: [Qemu-devel] [PATCH v2 01/13] Use unsigned types for the 'len' argument of all memory read/write functions, Eric Blake, 2016/03/01