qemu-cr16/hw/nvram
Kane-Chen-AS 8970c95c4d hw/nvram/aspeed_otp: Add OTP programming semantics and tracing
Implement correct OTP programming behavior for Aspeed OTP:
- Support read-modify-write flow with one-way bit programming:
  * prog_bit uses 0s as the "to-be-programmed" mask.
  * Even-indexed words: 0->1, odd-indexed words: 1->0.
  * Reject non-programmable requests and log conflicts.
- Enable unaligned accesses in MemoryRegionOps.
  Since each OTP address maps to a 1DW (4B) or 2DW (8B) block in the
  backing store, upper-layer accesses may be unaligned to block
  boundaries.

This matches the irreversible, word-parity-dependent programming rules
of Aspeed SoCs and exposes changes via QEMU trace events.

Signed-off-by: Kane-Chen-AS <kane_chen@aspeedtech.com>
Reviewed-by: Cédric Le Goater <clg@redhat.com>
Link: https://lore.kernel.org/qemu-devel/20250812094011.2617526-6-kane_chen@aspeedtech.com
[ clg: Fixed PRIx64 format in aspeed_otp_write() ]
Signed-off-by: Cédric Le Goater <clg@redhat.com>
2025-09-29 18:00:20 +02:00
..
aspeed_otp.c hw/nvram/aspeed_otp: Add OTP programming semantics and tracing 2025-09-29 18:00:20 +02:00
bcm2835_otp.c qom: Have class_init() take a const data argument 2025-04-25 17:00:41 +02:00
chrp_nvram.c include: Rename sysemu/ -> system/ 2024-12-20 17:44:56 +01:00
ds1225y.c qom: Have class_init() take a const data argument 2025-04-25 17:00:41 +02:00
eeprom93xx.c hw/nvram: Constify VMState 2023-12-30 07:38:06 +11:00
eeprom_at24c.c qom: Have class_init() take a const data argument 2025-04-25 17:00:41 +02:00
fw_cfg-acpi.c license: Update deprecated SPDX tag GPL-2.0+ to GPL-2.0-or-later 2024-09-20 10:11:59 +03:00
fw_cfg-interface.c hw/nvram: Always register FW_CFG_DATA_GENERATOR_INTERFACE 2020-10-12 11:50:20 -04:00
fw_cfg.c hw/nvram/fw_cfg: Remove legacy FW_CFG_ORDER_OVERRIDE 2025-05-30 09:52:08 +02:00
Kconfig hw/nvram: Introduce Xilinx battery-backed ram 2021-09-30 13:42:10 +01:00
mac_nvram.c qom: Have class_init() take a const data argument 2025-04-25 17:00:41 +02:00
meson.build hw/nvram/aspeed_otp: Add ASPEED OTP memory device model 2025-09-29 18:00:20 +02:00
npcm7xx_otp.c qom: Have class_init() take a const data argument 2025-04-25 17:00:41 +02:00
nrf51_nvm.c qom: Have class_init() take a const data argument 2025-04-25 17:00:41 +02:00
spapr_nvram.c qom: Have class_init() take a const data argument 2025-04-25 17:00:41 +02:00
trace-events hw/nvram/aspeed_otp: Add OTP programming semantics and tracing 2025-09-29 18:00:20 +02:00
trace.h trace: switch position of headers to what Meson requires 2020-08-21 06:18:24 -04:00
xlnx-bbram.c qom: Have class_init() take a const data argument 2025-04-25 17:00:41 +02:00
xlnx-efuse-crc.c hw/nvram: Introduce Xilinx eFuse QOM 2021-09-30 13:42:09 +01:00
xlnx-efuse.c qom: Have class_init() take a const data argument 2025-04-25 17:00:41 +02:00
xlnx-versal-efuse-cache.c qom: Have class_init() take a const data argument 2025-04-25 17:00:41 +02:00
xlnx-versal-efuse-ctrl.c qom: Have class_init() take a const data argument 2025-04-25 17:00:41 +02:00
xlnx-zynqmp-efuse.c qom: Have class_init() take a const data argument 2025-04-25 17:00:41 +02:00