summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAngel Pons <th3fanbus@gmail.com>2021-12-19 17:15:48 +0100
committerFelix Held <felix-coreboot@felixheld.de>2021-12-23 14:31:53 +0000
commit2ea8b945ec181aff42011fc73e503eee91c72545 (patch)
tree7498f514248775eab3c1113e034b15958de56578
parente061fbf1e7837769964091cb40e75cde63fcc121 (diff)
nb/intel/ironlake: Use `NUM_CHANNELS` macro
Change-Id: I3f4dc26699e3618740af5a0ade1a19599d5a2cc7 Signed-off-by: Angel Pons <th3fanbus@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/60225 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
-rw-r--r--src/northbridge/intel/ironlake/raminit.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/northbridge/intel/ironlake/raminit.c b/src/northbridge/intel/ironlake/raminit.c
index 72c3028df8..9277477a8e 100644
--- a/src/northbridge/intel/ironlake/raminit.c
+++ b/src/northbridge/intel/ironlake/raminit.c
@@ -792,7 +792,7 @@ static void compute_derived_timings(struct raminfo *info)
info->max_slots_used_in_channel = 2;
else
info->max_slots_used_in_channel = 1;
- for (channel = 0; channel < 2; channel++)
+ for (channel = 0; channel < NUM_CHANNELS; channel++)
mchbar_write32(0x244 + (channel << 10),
((info->revision < 8) ? 1 : 0x200) |
((2 - info->max_slots_used_in_channel) << 17) |