[PATCH v2 0/5] Hexagon: fix lock, priv bugs

Brian Cain posted 5 patches 1 week, 1 day ago
target/hexagon/cpu.h                      |  1 +
target/hexagon/translate.h                |  1 +
target/hexagon/cpu.c                      |  2 +
target/hexagon/cpu_helper.c               |  6 +++
target/hexagon/hex_interrupts.c           |  8 +++-
target/hexagon/hex_mmu.c                  |  6 +++
target/hexagon/op_helper.c                |  2 +
target/hexagon/translate.c                | 15 +++++++
target/hexagon/gen_tcg_funcs.py           | 16 +++++---
tests/functional/hexagon/meson.build      |  1 +
tests/functional/hexagon/test_minivm.py   | 48 +++++++++++++++++++++++
tests/functional/hexagon/test_systests.py |  3 ++
12 files changed, 101 insertions(+), 8 deletions(-)
create mode 100755 tests/functional/hexagon/test_minivm.py
[PATCH v2 0/5] Hexagon: fix lock, priv bugs
Posted by Brian Cain 1 week, 1 day ago
Testing with h2 and linux has uncovered some bugs in the way the locks are
implemented and privileged instructions.

Note that this will be rebased to make adjustments when the *next_pc removals
land.  See https://lore.kernel.org/qemu-devel/20261008211005.1853542-1-brian.cain@oss.qualcomm.com/

In v2:
- now rebased after *next_pc state removal, hex_tlb_lock() now receives the
packet PC, records that PC before halting the CPU, then exits TB.
- minivm test now preserves sparse test_mmu file in the archive, so
extraction is fast, disk space required is small.  Removed skipBigDataTest
filter and subTest() hack.

v1: https://lore.kernel.org/qemu-devel/20261009192541.4163758-1-brian.cain@oss.qualcomm.com/

Brian Cain (5):
  target/hexagon: check privilege mode for system instructions
  target/hexagon: wake K0 and TLB lock waiters
  target/hexagon: halt on tlblock when the TLB lock is contended
  target/hexagon: set a started thread's enable bit when start retires
  tests/functional/hexagon: add MiniVM, lock tests

 target/hexagon/cpu.h                      |  1 +
 target/hexagon/translate.h                |  1 +
 target/hexagon/cpu.c                      |  2 +
 target/hexagon/cpu_helper.c               |  6 +++
 target/hexagon/hex_interrupts.c           |  8 +++-
 target/hexagon/hex_mmu.c                  |  6 +++
 target/hexagon/op_helper.c                |  2 +
 target/hexagon/translate.c                | 15 +++++++
 target/hexagon/gen_tcg_funcs.py           | 16 +++++---
 tests/functional/hexagon/meson.build      |  1 +
 tests/functional/hexagon/test_minivm.py   | 48 +++++++++++++++++++++++
 tests/functional/hexagon/test_systests.py |  3 ++
 12 files changed, 101 insertions(+), 8 deletions(-)
 create mode 100755 tests/functional/hexagon/test_minivm.py

-- 
2.34.1