diff mbox series

[05/11] hw/mips/jazz: Rename ISA input IRQs as 'isa_irqs_in'

Message ID 20230210163744.32182-6-philmd@linaro.org
State New
Headers show
Series hw/isa: More housekeeping | expand

Commit Message

Philippe Mathieu-Daudé Feb. 10, 2023, 4:37 p.m. UTC
The following code:

     /* ISA devices */
     i8259 = i8259_init(isa_bus, ...);

gives the false idea that the function is creating a i8259
device. Instead this function returns an array of input IRQs.
Rename the variable to clarify:

     /* ISA devices */
     isa_irqs_in = i8259_init(isa_bus, ...);

Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
---
 hw/mips/jazz.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

Comments

Richard Henderson Feb. 11, 2023, 5:18 p.m. UTC | #1
On 2/10/23 06:37, Philippe Mathieu-Daudé wrote:
> The following code:
> 
>       /* ISA devices */
>       i8259 = i8259_init(isa_bus, ...);
> 
> gives the false idea that the function is creating a i8259
> device. Instead this function returns an array of input IRQs.
> Rename the variable to clarify:
> 
>       /* ISA devices */
>       isa_irqs_in = i8259_init(isa_bus, ...);
> 
> Signed-off-by: Philippe Mathieu-Daudé<philmd@linaro.org>
> ---
>   hw/mips/jazz.c | 6 +++---
>   1 file changed, 3 insertions(+), 3 deletions(-)

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>

r~
diff mbox series

Patch

diff --git a/hw/mips/jazz.c b/hw/mips/jazz.c
index 6aefe9a61b..fc7898006c 100644
--- a/hw/mips/jazz.c
+++ b/hw/mips/jazz.c
@@ -130,7 +130,7 @@  static void mips_jazz_init(MachineState *machine,
     MIPSCPU *cpu;
     MIPSCPUClass *mcc;
     CPUMIPSState *env;
-    qemu_irq *i8259;
+    qemu_irq *isa_irqs_in;
     rc4030_dma *dmas;
     IOMMUMemoryRegion *rc4030_dma_mr;
     MemoryRegion *isa_mem = g_new(MemoryRegion, 1);
@@ -248,8 +248,8 @@  static void mips_jazz_init(MachineState *machine,
     isa_bus = isa_bus_new(NULL, isa_mem, isa_io, &error_abort);
 
     /* ISA devices */
-    i8259 = i8259_init(isa_bus, env->irq[4]);
-    isa_bus_irqs(isa_bus, i8259);
+    isa_irqs_in = i8259_init(isa_bus, env->irq[4]);
+    isa_bus_irqs(isa_bus, isa_irqs_in);
     i8257_dma_init(isa_bus, 0);
     pit = i8254_pit_init(isa_bus, 0x40, 0, NULL);
     pcspk_init(isa_new(TYPE_PC_SPEAKER), isa_bus, pit);