[PATCH v5 0/4] riscv: AIA: Add in-kernel irqchips save and restore function support

Wang Yechao posted 4 patches 4 weeks ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20261026024048.630015-1-wang.yechao255@zte.com.cn
Maintainers: Palmer Dabbelt <palmer@dabbelt.com>, Alistair Francis <alistair.francis@wdc.com>, Weiwei Li <liwei1518@gmail.com>, Daniel Henrique Barboza <daniel.barboza@oss.qualcomm.com>, Liu Zhiwei <zhiwei_liu@linux.alibaba.com>, Chao Liu <chao.liu@processmission.com>, Peter Xu <peterx@redhat.com>, Fabiano Rosas <farosas@suse.de>
hw/intc/riscv_aplic.c         | 201 +++++++++++++++++++++++++++++-----
hw/intc/riscv_imsic.c         | 180 +++++++++++++++++++++++++++---
include/hw/intc/riscv_aplic.h |   4 +
include/hw/intc/riscv_imsic.h |   3 +
include/qemu/bitops.h         |   1 +
migration/vmstate-types.c     |   3 +-
target/riscv/kvm/kvm-cpu.c    |   7 +-
target/riscv/kvm/kvm_riscv.h  |   1 +
8 files changed, 357 insertions(+), 43 deletions(-)
[PATCH v5 0/4] riscv: AIA: Add in-kernel irqchips save and restore function support
Posted by Wang Yechao 4 weeks ago
This series adds support for in-kernel AIA irqchip save and restore
on RISC-V.

Changes in v5:
- Fix typos in the patch descriptions.
- Split the non-RISC-V-specific changes into a separate patch (patch 03).
- Drop the TCG vmstate debug fix from this series.
- Link to v4: https://lore.kernel.org/qemu-devel/20261023021237.486091-1-wang.yechao255@zte.com.cn/

Changes in v4:
- Fix build issues in the TCG-only configuration.
- Rename several functions to make them more readable.
- Fix the missing section footer problem.
- Add patch 04, which fixes an assertion failure during save on
  --disable-tcg builds.

- Link to v3: https://lore.kernel.org/qemu-devel/20260602142930300qtONy7P2DkDM40BX_T3_A@zte.com.cn/
 
Changes in v3:
- Removed unnecessary changes in bitops.h
- Link to v2: https://lore.kernel.org/qemu-devel/20260305171729291ZzfxmqZ48P2Tbz9TGCtST@zte.com.cn/

Changes in v2:
- Added the BITS_TO_U64S macro
- Added the nr_eix field and dynamically allocated the eie/eip arrays
- Replaced the CONFIG_32BIT macro with is_32bit boolean flag
- Link to v1: https://lore.kernel.org/qemu-devel/20260227180104794YvW9Rb2I_kAGzUruZL11Q@zte.com.cn/


Wang Yechao (1):
  include/qemu/bitops: Move BITS_TO_U64S to bitops.h

Xuemei Liu (3):
  target/riscv/kvm: create kvm_riscv_aia_access_reg
  hw/intc/riscv_aplic: Add in-kernel aplic save and restore function
  hw/intc/imsic: Add in-kernel imsic save and restore function

 hw/intc/riscv_aplic.c         | 201 +++++++++++++++++++++++++++++-----
 hw/intc/riscv_imsic.c         | 180 +++++++++++++++++++++++++++---
 include/hw/intc/riscv_aplic.h |   4 +
 include/hw/intc/riscv_imsic.h |   3 +
 include/qemu/bitops.h         |   1 +
 migration/vmstate-types.c     |   3 +-
 target/riscv/kvm/kvm-cpu.c    |   7 +-
 target/riscv/kvm/kvm_riscv.h  |   1 +
 8 files changed, 357 insertions(+), 43 deletions(-)

-- 
2.47.3
Re: [PATCH v5 0/4] riscv: AIA: Add in-kernel irqchips save and restore function support
Posted by Alistair Francis 1 week, 4 days ago
On Mon, 2026-10-26 at 10:40 +0800, Wang Yechao wrote:
> This series adds support for in-kernel AIA irqchip save and restore
> on RISC-V.
> 
> Changes in v5:
> - Fix typos in the patch descriptions.
> - Split the non-RISC-V-specific changes into a separate patch (patch
> 03).
> - Drop the TCG vmstate debug fix from this series.
> - Link to v4:
> https://lore.kernel.org/qemu-devel/20261023021237.486091-1-wang.yechao255@zte.com.cn/
> 
> Changes in v4:
> - Fix build issues in the TCG-only configuration.
> - Rename several functions to make them more readable.
> - Fix the missing section footer problem.
> - Add patch 04, which fixes an assertion failure during save on
>   --disable-tcg builds.
> 
> - Link to v3:
> https://lore.kernel.org/qemu-devel/20260602142930300qtONy7P2DkDM40BX_T3_A@zte.com.cn/
>  
> Changes in v3:
> - Removed unnecessary changes in bitops.h
> - Link to v2:
> https://lore.kernel.org/qemu-devel/20260305171729291ZzfxmqZ48P2Tbz9TGCtST@zte.com.cn/
> 
> Changes in v2:
> - Added the BITS_TO_U64S macro
> - Added the nr_eix field and dynamically allocated the eie/eip arrays
> - Replaced the CONFIG_32BIT macro with is_32bit boolean flag
> - Link to v1:
> https://lore.kernel.org/qemu-devel/20260227180104794YvW9Rb2I_kAGzUruZL11Q@zte.com.cn/
> 
> 
> Wang Yechao (1):
>   include/qemu/bitops: Move BITS_TO_U64S to bitops.h
> 
> Xuemei Liu (3):
>   target/riscv/kvm: create kvm_riscv_aia_access_reg
>   hw/intc/riscv_aplic: Add in-kernel aplic save and restore function
>   hw/intc/imsic: Add in-kernel imsic save and restore function

Thanks!

Applied to riscv-to-apply.next

Alistair

> 
>  hw/intc/riscv_aplic.c         | 201 +++++++++++++++++++++++++++++---
> --
>  hw/intc/riscv_imsic.c         | 180 +++++++++++++++++++++++++++---
>  include/hw/intc/riscv_aplic.h |   4 +
>  include/hw/intc/riscv_imsic.h |   3 +
>  include/qemu/bitops.h         |   1 +
>  migration/vmstate-types.c     |   3 +-
>  target/riscv/kvm/kvm-cpu.c    |   7 +-
>  target/riscv/kvm/kvm_riscv.h  |   1 +
>  8 files changed, 357 insertions(+), 43 deletions(-)