Hi Amir,

I've done a bunch of cleanup which Peter and I had recommended
during review.  The major bits are:

* Note reserved bits of control registers, which may include
  the entire control register.
* Complete conversion to registerfields.h.
* Use pointer to shadow register set, akin to Sparc windows.
* Use -M 10m50-ghrd,vic=on to enable VIC.

I can test this to a point, but not the final result.
It works to a point with our existing nios2 kernels,
but of course no interrupts are received. So it verifies
that something changes, and that the init doesn't crash,
but that's about it.


r~


Amir Gonnen (5):
  target/nios2: Check supervisor on eret
  target/nios2: Add NUM_GP_REGS and NUM_CP_REGS
  target/nios2: Split out helper for eret instruction
  hw/intc: Vectored Interrupt Controller (VIC)
  hw/nios2: Machine with a Vectored Interrupt Controller

Richard Henderson (28):
  target/nios2: Stop generating code if gen_check_supervisor fails
  target/nios2: Split PC out of env->regs[]
  target/nios2: Do not create TCGv for control registers
  linux-user/nios2: Trim target_pc_regs to sp and pc
  target/nios2: Remove cpu_interrupts_enabled
  target/nios2: Split control registers away from general registers
  target/nios2: Clean up nios2_cpu_dump_state
  target/nios2: Use hw/registerfields.h for CR_STATUS fields
  target/nios2: Use hw/registerfields.h for CR_EXCEPTION fields
  target/nios2: Use hw/registerfields.h for CR_TLBADDR fields
  target/nios2: Use hw/registerfields.h for CR_TLBACC fields
  target/nios2: Use hw/registerfields.h for CR_TLBMISC fields
  target/nios2: Move R_FOO and CR_BAR into enumerations
  target/nios2: Prevent writes to read-only or reserved control fields
  target/nios2: Implement cpuid
  target/nios2: Implement CR_STATUS.RSIE
  target/nios2: Remove CPU_INTERRUPT_NMI
  target/nios2: Use tcg_constant_tl
  target/nios2: Introduce dest_gpr
  target/nios2: Drop CR_STATUS_EH from tb->flags
  target/nios2: Introduce shadow register sets
  target/nios2: Implement rdprs, wrprs
  target/nios2: Update helper_eret for shadow registers
  target/nios2: Create EXCP_SEMIHOST for semi-hosting
  target/nios2: Clean up nios2_cpu_do_interrupt
  target/nios2: Implement EIC interrupt processing
  hw/nios2: Introduce Nios2MachineState
  hw/nios2: Move memory regions into Nios2Machine

 linux-user/nios2/target_syscall.h |  25 +-
 target/nios2/cpu.h                | 253 ++++++++++++------
 target/nios2/helper.h             |   3 +
 hw/intc/nios2_vic.c               | 341 ++++++++++++++++++++++++
 hw/nios2/10m50_devboard.c         | 118 +++++++--
 hw/nios2/boot.c                   |   8 +-
 linux-user/elfload.c              |   5 +-
 linux-user/nios2/cpu_loop.c       |  39 +--
 linux-user/nios2/signal.c         |   6 +-
 target/nios2/cpu.c                | 194 +++++++++++---
 target/nios2/helper.c             | 218 +++++++--------
 target/nios2/mmu.c                |  73 +++---
 target/nios2/nios2-semi.c         |  13 +-
 target/nios2/op_helper.c          |  39 +++
 target/nios2/translate.c          | 422 +++++++++++++++++++-----------
 hw/intc/Kconfig                   |   3 +
 hw/intc/meson.build               |   1 +
 hw/nios2/Kconfig                  |   1 +
 18 files changed, 1223 insertions(+), 539 deletions(-)
 create mode 100644 hw/intc/nios2_vic.c

-- 
2.25.1


Reply via email to