[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v2 23/40] lasips2: rename LASIPS2Port irq field to birq
From: |
Mark Cave-Ayland |
Subject: |
[PATCH v2 23/40] lasips2: rename LASIPS2Port irq field to birq |
Date: |
Tue, 12 Jul 2022 22:52:34 +0100 |
The existing boolean irq field in LASIPS2Port will soon be replaced by a proper
qemu_irq, so rename the field to birq to allow the upcoming qemu_irq to use the
irq name.
Signed-off-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Tested-by: Helge Deller <deller@gmx.de>
Acked-by: Helge Deller <deller@gmx.de>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
---
hw/input/lasips2.c | 24 ++++++++++++------------
include/hw/input/lasips2.h | 2 +-
2 files changed, 13 insertions(+), 13 deletions(-)
diff --git a/hw/input/lasips2.c b/hw/input/lasips2.c
index ce87c66f2a..49e5c90b73 100644
--- a/hw/input/lasips2.c
+++ b/hw/input/lasips2.c
@@ -42,10 +42,10 @@ static const VMStateDescription vmstate_lasips2 = {
.fields = (VMStateField[]) {
VMSTATE_UINT8(kbd_port.parent_obj.control, LASIPS2State),
VMSTATE_UINT8(kbd_port.parent_obj.id, LASIPS2State),
- VMSTATE_BOOL(kbd_port.parent_obj.irq, LASIPS2State),
+ VMSTATE_BOOL(kbd_port.parent_obj.birq, LASIPS2State),
VMSTATE_UINT8(mouse_port.parent_obj.control, LASIPS2State),
VMSTATE_UINT8(mouse_port.parent_obj.id, LASIPS2State),
- VMSTATE_BOOL(mouse_port.parent_obj.irq, LASIPS2State),
+ VMSTATE_BOOL(mouse_port.parent_obj.birq, LASIPS2State),
VMSTATE_END_OF_LIST()
}
};
@@ -119,10 +119,10 @@ static const char *lasips2_write_reg_name(uint64_t addr)
static void lasips2_update_irq(LASIPS2State *s)
{
- trace_lasips2_intr(s->kbd_port.parent_obj.irq |
- s->mouse_port.parent_obj.irq);
- qemu_set_irq(s->irq, s->kbd_port.parent_obj.irq |
- s->mouse_port.parent_obj.irq);
+ trace_lasips2_intr(s->kbd_port.parent_obj.birq |
+ s->mouse_port.parent_obj.birq);
+ qemu_set_irq(s->irq, s->kbd_port.parent_obj.birq |
+ s->mouse_port.parent_obj.birq);
}
static void lasips2_reg_write(void *opaque, hwaddr addr, uint64_t val,
@@ -141,7 +141,7 @@ static void lasips2_reg_write(void *opaque, hwaddr addr,
uint64_t val,
case REG_PS2_XMTDATA:
if (port->control & LASIPS2_CONTROL_LOOPBACK) {
port->buf = val;
- port->irq = true;
+ port->birq = true;
port->loopback_rbne = true;
lasips2_update_irq(port->parent);
break;
@@ -176,7 +176,7 @@ static uint64_t lasips2_reg_read(void *opaque, hwaddr addr,
unsigned size)
case REG_PS2_RCVDATA:
if (port->control & LASIPS2_CONTROL_LOOPBACK) {
- port->irq = false;
+ port->birq = false;
port->loopback_rbne = false;
lasips2_update_irq(port->parent);
ret = port->buf;
@@ -213,8 +213,8 @@ static uint64_t lasips2_reg_read(void *opaque, hwaddr addr,
unsigned size)
}
}
- if (port->parent->kbd_port.parent_obj.irq ||
- port->parent->mouse_port.parent_obj.irq) {
+ if (port->parent->kbd_port.parent_obj.birq ||
+ port->parent->mouse_port.parent_obj.birq) {
ret |= LASIPS2_STATUS_CMPINTR;
}
break;
@@ -245,7 +245,7 @@ static void lasips2_set_kbd_irq(void *opaque, int n, int
level)
LASIPS2State *s = LASIPS2(opaque);
LASIPS2Port *port = LASIPS2_PORT(&s->kbd_port);
- port->irq = level;
+ port->birq = level;
lasips2_update_irq(port->parent);
}
@@ -254,7 +254,7 @@ static void lasips2_set_mouse_irq(void *opaque, int n, int
level)
LASIPS2State *s = LASIPS2(opaque);
LASIPS2Port *port = LASIPS2_PORT(&s->mouse_port);
- port->irq = level;
+ port->birq = level;
lasips2_update_irq(port->parent);
}
diff --git a/include/hw/input/lasips2.h b/include/hw/input/lasips2.h
index 84807bec36..4c4b471737 100644
--- a/include/hw/input/lasips2.h
+++ b/include/hw/input/lasips2.h
@@ -40,7 +40,7 @@ struct LASIPS2Port {
uint8_t control;
uint8_t buf;
bool loopback_rbne;
- bool irq;
+ bool birq;
};
#define TYPE_LASIPS2_KBD_PORT "lasips2-kbd-port"
--
2.30.2
- [PATCH v2 13/40] lasips2: remove the qdev base property and the lasips2_properties array, (continued)
- [PATCH v2 13/40] lasips2: remove the qdev base property and the lasips2_properties array, Mark Cave-Ayland, 2022/07/12
- [PATCH v2 15/40] lasips2: change LASIPS2State dev pointer from void to PS2State, Mark Cave-Ayland, 2022/07/12
- [PATCH v2 14/40] lasips2: remove legacy lasips2_initfn() function, Mark Cave-Ayland, 2022/07/12
- [PATCH v2 16/40] lasips2: QOMify LASIPS2Port, Mark Cave-Ayland, 2022/07/12
- [PATCH v2 17/40] lasips2: introduce new LASIPS2_KBD_PORT QOM type, Mark Cave-Ayland, 2022/07/12
- [PATCH v2 18/40] lasips2: introduce new LASIPS2_MOUSE_PORT QOM type, Mark Cave-Ayland, 2022/07/12
- [PATCH v2 20/40] lasips2: move mouse port initialisation to new lasips2_mouse_port_init() function, Mark Cave-Ayland, 2022/07/12
- [PATCH v2 19/40] lasips2: move keyboard port initialisation to new lasips2_kbd_port_init() function, Mark Cave-Ayland, 2022/07/12
- [PATCH v2 21/40] lasips2: introduce lasips2_kbd_port_class_init() and lasips2_kbd_port_realize(), Mark Cave-Ayland, 2022/07/12
- [PATCH v2 22/40] lasips2: introduce lasips2_mouse_port_class_init() and lasips2_mouse_port_realize(), Mark Cave-Ayland, 2022/07/12
- [PATCH v2 23/40] lasips2: rename LASIPS2Port irq field to birq,
Mark Cave-Ayland <=
- [PATCH v2 24/40] lasips2: introduce port IRQ and new lasips2_port_init() function, Mark Cave-Ayland, 2022/07/12
- [PATCH v2 25/40] lasips2: introduce LASIPS2PortDeviceClass for the LASIPS2_PORT device, Mark Cave-Ayland, 2022/07/12
- [PATCH v2 26/40] lasips2: add named input gpio to port for downstream PS2 device IRQ, Mark Cave-Ayland, 2022/07/12
- [PATCH v2 27/40] lasips2: add named input gpio to handle incoming port IRQs, Mark Cave-Ayland, 2022/07/12
- [PATCH v2 28/40] lasips2: switch to using port-based IRQs, Mark Cave-Ayland, 2022/07/12
- [PATCH v2 29/40] lasips2: rename LASIPS2Port parent pointer to lasips2, Mark Cave-Ayland, 2022/07/12
- [PATCH v2 30/40] lasips2: standardise on lp name for LASIPS2Port variables, Mark Cave-Ayland, 2022/07/12
- [PATCH v2 32/40] lasips2: don't use legacy ps2_kbd_init() function, Mark Cave-Ayland, 2022/07/12
- [PATCH v2 31/40] lasips2: switch register memory region to DEVICE_BIG_ENDIAN, Mark Cave-Ayland, 2022/07/12
- [PATCH v2 33/40] lasips2: don't use legacy ps2_mouse_init() function, Mark Cave-Ayland, 2022/07/12