diff options
author | Mike Frysinger <vapier@gentoo.org> | 2022-12-25 00:31:19 -0500 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2022-12-25 02:09:18 -0500 |
commit | 46ebce9b9c70c85caa9e4cfb5c19340ccfec38fc (patch) | |
tree | 39ba280b008f2da2f0e6e1759c9c45983ea1c4e1 | |
parent | 70b920ed097442a4b663fc0e64319382397ae46b (diff) | |
download | binutils-46ebce9b9c70c85caa9e4cfb5c19340ccfec38fc.zip binutils-46ebce9b9c70c85caa9e4cfb5c19340ccfec38fc.tar.gz binutils-46ebce9b9c70c85caa9e4cfb5c19340ccfec38fc.tar.bz2 |
sim: or1k: fix iterator typo when setting up cpus
This code loops over available cpus with "c", but then looks up the
cpu with "i". Fix the typo so the code works correctly with smp.
-rw-r--r-- | sim/or1k/sim-if.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sim/or1k/sim-if.c b/sim/or1k/sim-if.c index d698d70..799812b 100644 --- a/sim/or1k/sim-if.c +++ b/sim/or1k/sim-if.c @@ -244,7 +244,7 @@ sim_open (SIM_OPEN_KIND kind, host_callback *callback, struct bfd *abfd, } /* Do some final OpenRISC sim specific initializations. */ - for (c = 0; c < MAX_NR_PROCESSORS; ++c) + for (i = 0; i < MAX_NR_PROCESSORS; ++i) { SIM_CPU *cpu = STATE_CPU (sd, i); /* Only needed for profiling, but the structure member is small. */ |