aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Henderson <richard.henderson@linaro.org>2025-03-21 14:31:26 -0700
committerRichard Henderson <richard.henderson@linaro.org>2025-04-22 14:07:12 -0700
commit29bcd5a46a9de61587f490d92c5a5500b2684f22 (patch)
treef27f5cfb98b1cc4f48bcfe4eb7e4a0b259e27b99
parent6b661b7ed7cd02c54a78426d5eb7dd8543b030ed (diff)
downloadqemu-29bcd5a46a9de61587f490d92c5a5500b2684f22.zip
qemu-29bcd5a46a9de61587f490d92c5a5500b2684f22.tar.gz
qemu-29bcd5a46a9de61587f490d92c5a5500b2684f22.tar.bz2
target/avr: Remove OFFSET_CPU_REGISTERS
This define isn't really used. Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org> Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
-rw-r--r--target/avr/cpu.h2
-rw-r--r--target/avr/helper.c3
2 files changed, 1 insertions, 4 deletions
diff --git a/target/avr/cpu.h b/target/avr/cpu.h
index 06f5ae4..84a8f5c 100644
--- a/target/avr/cpu.h
+++ b/target/avr/cpu.h
@@ -60,8 +60,6 @@
#define OFFSET_CODE 0x00000000
/* CPU registers, IO registers, and SRAM */
#define OFFSET_DATA 0x00800000
-/* CPU registers specifically, these are mapped at the start of data */
-#define OFFSET_CPU_REGISTERS OFFSET_DATA
/*
* IO registers, including status register, stack pointer, and memory
* mapped peripherals, mapped just after CPU registers
diff --git a/target/avr/helper.c b/target/avr/helper.c
index 3412312..e5bf16c 100644
--- a/target/avr/helper.c
+++ b/target/avr/helper.c
@@ -340,8 +340,7 @@ void helper_fullwr(CPUAVRState *env, uint32_t data, uint32_t addr)
env->fullacc = false;
/* Following logic assumes this: */
- assert(OFFSET_CPU_REGISTERS == OFFSET_DATA);
- assert(OFFSET_IO_REGISTERS == OFFSET_CPU_REGISTERS +
+ assert(OFFSET_IO_REGISTERS == OFFSET_DATA +
NUMBER_OF_CPU_REGISTERS);
if (addr < NUMBER_OF_CPU_REGISTERS) {