summaryrefslogtreecommitdiffstats
path: root/hw/dma
diff options
context:
space:
mode:
authorPhilippe Mathieu-Daudé2020-02-19 19:08:49 +0100
committerPhilippe Mathieu-Daudé2020-02-20 14:47:08 +0100
commit9842a9cfdddfdc983f2ec09772a896be10c7373e (patch)
tree02891c1897010c3a94080304c2fafee986847aa7 /hw/dma
parenthw/ide/internal: Remove unused DMARestartFunc typedef (diff)
downloadqemu-9842a9cfdddfdc983f2ec09772a896be10c7373e.tar.gz
qemu-9842a9cfdddfdc983f2ec09772a896be10c7373e.tar.xz
qemu-9842a9cfdddfdc983f2ec09772a896be10c7373e.zip
hw/ide: Let the DMAIntFunc prototype use a boolean 'is_write' argument
The 'is_write' argument is either 0 or 1. Convert it to a boolean type. Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Diffstat (limited to 'hw/dma')
-rw-r--r--hw/dma/rc4030.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/hw/dma/rc4030.c b/hw/dma/rc4030.c
index ca0becd756..21e2c360ac 100644
--- a/hw/dma/rc4030.c
+++ b/hw/dma/rc4030.c
@@ -590,7 +590,7 @@ static const VMStateDescription vmstate_rc4030 = {
};
static void rc4030_do_dma(void *opaque, int n, uint8_t *buf,
- int len, int is_write)
+ int len, bool is_write)
{
rc4030State *s = opaque;
hwaddr dma_addr;
@@ -630,13 +630,13 @@ struct rc4030DMAState {
void rc4030_dma_read(void *dma, uint8_t *buf, int len)
{
rc4030_dma s = dma;
- rc4030_do_dma(s->opaque, s->n, buf, len, 0);
+ rc4030_do_dma(s->opaque, s->n, buf, len, false);
}
void rc4030_dma_write(void *dma, uint8_t *buf, int len)
{
rc4030_dma s = dma;
- rc4030_do_dma(s->opaque, s->n, buf, len, 1);
+ rc4030_do_dma(s->opaque, s->n, buf, len, true);
}
static rc4030_dma *rc4030_allocate_dmas(void *opaque, int n)