Skip to content

Rework i8259 and PC interrupt models

Jan Kiszka qemu-devel 2 versions – Applied

Status from this message: Thanks, applied all.

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest23 patches 7 repliesApplied
  2. v122 patches 64 repliesSuperseded

Changes in v2 from the cover letter

- kept PIC irq state update after reset but clarified why this required and only valid here
- additional fix: Clear ELCR on reset
- included already posted updates of patch 22 and 23

Patches in v2 Applied

#Subject and filesSizeRepliesApplied
1/23pc: Drop useless test from isa_irq_handlerhw/pc.c+2 -30 replies
2/23pc: Generalize ISA IRQs to GSIshw/ioapic.h hw/isa.h hw/pc.c +2 more+42 -310 replies
3/23pc: Convert GSIState::i8259_irq into arrayhw/pc.h hw/pc_piix.c+4 -20 replies
4/23pc: Fix and clean up PIC-to-APIC IRQ pathhw/apic.c hw/i8259.c hw/pc.c +1 more+12 -120 replies
5/23i8259: Remove premature inline function attributeshw/i8259.c+3 -30 replies
6/23i8259: Drop obsolete prototypeshw/pc.h+0 -20 replies
7/23i8259: Move pic_set_irq1 after pic_update_irqhw/i8259.c+29 -260 replies
8/23i8239: Introduce per-PIC output interrupthw/i8259.c+12 -90 replies
9/23i8259: Do not update IRQ output after spurious pic_poll_readhw/i8259.c+0 -10 replies
10/23i8259: Reorder intack in pic_read_irqhw/i8259.c+6 -40 replies
11/23i8259: Update IRQ state after resethw/i8259.c+1 -20 replies
12/23i8259: Clear ELCR on resethw/i8259.c+10 -50 replies
13/23i8259: Switch to per-PIC IRQ updatehw/i8259.c+21 -400 replies
14/23i8259: Fix poll commandhw/i8259.c+7 -10 replies
15/23i8259: Clean up pic_ioport_readhw/i8259.c+1 -20 replies
16/23i8259: PREP: Replace pic_intack_read with pic_read_irqhw/i8259.c hw/pc.h hw/ppc_prep.c+1 -412 replies
17/23i8259: Replace PicState::pics_state with master flaghw/i8259.c+9 -90 replies
18/23i8259: Eliminate PicState2hw/i8259.c hw/pc.h+34 -350 replies
19/23qdev: Add HEX8 propertyhw/qdev-properties.c hw/qdev.h+32 -01 reply
20/23i8259: Convert to qdevhw/i8259.c+100 -570 replies
21/23i8259: Fix coding stylehw/i8259.c+34 -200 replies
22/23monitor: Restrict pic/irq_info to supporting targetshw/an5206.c hw/arm_pic.c hw/cris_pic_cpu.c +11 more+33 -772 replies
23/23i8259: Move to hw libraryMakefile.objs Makefile.target default-configs/alpha-softmmu.mak +9 more+15 -41 reply

Reviews trailers per patch

2 of 23 patches have a Reviewed-by or Acked-by.

PatchBlue SwirlAndreas Färber
1/23
2/23
3/23
4/23
5/23
6/23
7/23
8/23
9/23
10/23
11/23
12/23
13/23
14/23
15/23
16/23T-b
17/23
18/23
19/23R-b
20/23
21/23
22/23A-b
23/23

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [Qemu-devel] [PATCH v2 00/23] Rework i8259 and PC interrupt models

Highlights of this series:
- generic i8259, now part of hwlib
- qdev conversion of i8259
- fix for i8259 poll mode (and removal of PREP hack)

The refactoring will also be important to instantiate i8259-kvm devices for in-kernel irqchip acceleration one day.

Changes in v2:
- kept PIC irq state update after reset but clarified why this required and only valid here
- additional fix: Clear ELCR on reset
- included already posted updates of patch 22 and 23

CC Andreas Färber <[email protected]>

Jan Kiszka (23):
pc: Drop useless test from isa_irq_handler
pc: Generalize ISA IRQs to GSIs
pc: Convert GSIState::i8259_irq into array
pc: Fix and clean up PIC-to-APIC IRQ path
i8259: Remove premature inline function attributes
i8259: Drop obsolete prototypes
i8259: Move pic_set_irq1 after pic_update_irq
i8239: Introduce per-PIC output interrupt
i8259: Do not update IRQ output after spurious pic_poll_read
i8259: Reorder intack in pic_read_irq
i8259: Update IRQ state after reset
i8259: Clear ELCR on reset
i8259: Switch to per-PIC IRQ update
i8259: Fix poll command
i8259: Clean up pic_ioport_read
i8259: PREP: Replace pic_intack_read with pic_read_irq
i8259: Replace PicState::pics_state with master flag
i8259: Eliminate PicState2
qdev: Add HEX8 property
i8259: Convert to qdev
i8259: Fix coding style
monitor: Restrict pic/irq_info to supporting targets
i8259: Move to hw library

 Makefile.objs                        |    1 +
 Makefile.target                      |    8 +-
 default-configs/alpha-softmmu.mak    |    1 +
 default-configs/i386-softmmu.mak     |    1 +
 default-configs/mips-softmmu.mak     |    1 +
 default-configs/mips64-softmmu.mak   |    1 +
 default-configs/mips64el-softmmu.mak |    1 +
 default-configs/mipsel-softmmu.mak   |    1 +
 default-configs/ppc-softmmu.mak      |    1 +
 default-configs/ppc64-softmmu.mak    |    1 +
 default-configs/ppcemb-softmmu.mak   |    1 +
 default-configs/x86_64-softmmu.mak   |    1 +
 hw/an5206.c                          |   10 -
 hw/apic.c                            |    4 +
 hw/arm_pic.c                         |   11 -
 hw/cris_pic_cpu.c                    |    6 -
 hw/etraxfs.h                         |    1 +
 hw/i8259.c                           |  397 ++++++++++++++++++----------------
 hw/ioapic.h                          |    7 +
 hw/isa.h                             |    2 +
 hw/lm32_pic.c                        |    4 +-
 hw/lm32_pic.h                        |    3 +
 hw/microblaze_pic_cpu.c              |    6 -
 hw/pc.c                              |   24 +--
 hw/pc.h                              |   29 ++--
 hw/pc_piix.c                         |   30 ++--
 hw/ppc_prep.c                        |    2 +-
 hw/qdev-properties.c                 |   29 +++
 hw/qdev.h                            |    3 +
 hw/s390-virtio.c                     |   11 -
 hw/shix.c                            |   11 -
 hw/sun4m.c                           |    4 +-
 hw/sun4m.h                           |    4 +
 hw/sun4u.c                           |    8 -
 hw/xtensa_pic.c                      |   10 -
 monitor.c                            |   21 ++
 36 files changed, 339 insertions(+), 317 deletions(-)
Signature · 1 line
1.7.3.4