[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 23/41] hw/char/pl011: Remove duplicated PL011_INT_[RT]X definition
From: |
Philippe Mathieu-Daudé |
Subject: |
[PULL 23/41] hw/char/pl011: Remove duplicated PL011_INT_[RT]X definitions |
Date: |
Thu, 31 Aug 2023 14:56:25 +0200 |
PL011_INT_TX duplicates INT_TX, and PL011_INT_RX INT_RX.
Follow other register fields definitions from this file,
keep the shorter form.
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20230522153144.30610-6-philmd@linaro.org>
---
hw/char/pl011.c | 9 +++------
1 file changed, 3 insertions(+), 6 deletions(-)
diff --git a/hw/char/pl011.c b/hw/char/pl011.c
index c3203e5b41..96675f52cc 100644
--- a/hw/char/pl011.c
+++ b/hw/char/pl011.c
@@ -48,9 +48,6 @@ DeviceState *pl011_create(hwaddr addr, qemu_irq irq, Chardev
*chr)
return dev;
}
-#define PL011_INT_TX 0x20
-#define PL011_INT_RX 0x10
-
/* Flag Register, UARTFR */
#define PL011_FLAG_TXFE 0x80
#define PL011_FLAG_RXFF 0x40
@@ -157,7 +154,7 @@ static uint64_t pl011_read(void *opaque, hwaddr offset,
s->flags |= PL011_FLAG_RXFE;
}
if (s->read_count == s->read_trigger - 1)
- s->int_level &= ~ PL011_INT_RX;
+ s->int_level &= ~ INT_RX;
trace_pl011_read_fifo(s->read_count);
s->rsr = c >> 8;
pl011_update(s);
@@ -262,7 +259,7 @@ static void pl011_write(void *opaque, hwaddr offset,
/* XXX this blocks entire thread. Rewrite to use
* qemu_chr_fe_write and background I/O callbacks */
qemu_chr_fe_write_all(&s->chr, &ch, 1);
- s->int_level |= PL011_INT_TX;
+ s->int_level |= INT_TX;
pl011_update(s);
break;
case 1: /* UARTRSR/UARTECR */
@@ -350,7 +347,7 @@ static void pl011_put_fifo(void *opaque, uint32_t value)
s->flags |= PL011_FLAG_RXFF;
}
if (s->read_count == s->read_trigger) {
- s->int_level |= PL011_INT_RX;
+ s->int_level |= INT_RX;
pl011_update(s);
}
}
--
2.41.0
- [PULL 14/41] target/helpers: Remove unnecessary 'qemu/main-loop.h' header, (continued)
- [PULL 14/41] target/helpers: Remove unnecessary 'qemu/main-loop.h' header, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 15/41] target/mips: Remove unused headers in lcsr_helper.c, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 17/41] qemu/processor: Remove unused 'qemu/atomic.h' header, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 18/41] exec/translation-block: Clean up includes, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 19/41] chardev/char-fe: Document FEWatchFunc typedef, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 22/41] hw/char/pl011: Display register name in trace events, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 20/41] hw/char: Have FEWatchFunc handlers return G_SOURCE_CONTINUE/REMOVE, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 16/41] target/xtensa: Include missing 'qemu/atomic.h' header, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 21/41] hw/char/pl011: Restrict MemoryRegionOps implementation access sizes, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 24/41] hw/char/pl011: Replace magic values by register field definitions, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 23/41] hw/char/pl011: Remove duplicated PL011_INT_[RT]X definitions,
Philippe Mathieu-Daudé <=
- [PULL 25/41] hw/i2c/pmbus_device: Fix modifying QOM class internals from instance, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 26/41] hw/i2c: spelling fixes, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 27/41] hw/ide: spelling fixes, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 29/41] hw/mips: spelling fixes, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 30/41] hw/sd: spelling fixes, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 31/41] hw/usb: spelling fixes, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 32/41] hw/usb/hcd-xhci: Avoid variable-length array in xhci_get_port_bandwidth(), Philippe Mathieu-Daudé, 2023/08/31
- [PULL 33/41] hw/i386: Remove unuseful kvmclock_create() stub, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 35/41] util/fifo8: Fix typo in fifo8_push_all() description, Philippe Mathieu-Daudé, 2023/08/31
- [PULL 34/41] hw/i386: Rename 'hw/kvm/clock.h' -> 'hw/i386/kvm/clock.h', Philippe Mathieu-Daudé, 2023/08/31