Date: Sun, 11 Dec 2016 19:53:45 +0000 From: "jchandra (Jayachandran C)" <phabric-noreply@FreeBSD.org> To: freebsd-arm@freebsd.org Subject: [Differential] D8751: Fix gic_cpu_mask calculation Message-ID: <differential-rev-PHID-DREV-rk6kp4lshzqwt24lhaq4-req@FreeBSD.org>
index | next in thread | raw e-mail
[-- Attachment #1 --]
jchandra created this revision.
jchandra added reviewers: arm64, freebsd-arm-list, andrew.
jchandra set the repository for this revision to rS FreeBSD src repository.
Herald added a subscriber: imp.
REVISION SUMMARY
r309616 changed the definition of GICD_ITARGETSR(n) right shift n
by 2, but the usage of the macro in gic_cpu_mask() was not updated
to reflect this. This causes the cpu mask to be computed incorrectly.
Fix this by updating gic_cpu_mask(). This fixes a hang seen when
booting on ARM64 with SMP enabled.
REPOSITORY
rS FreeBSD src repository
REVISION DETAIL
https://reviews.freebsd.org/D8751
AFFECTED FILES
sys/arm/arm/gic.c
CHANGE DETAILS
diff --git a/sys/arm/arm/gic.c b/sys/arm/arm/gic.c
--- a/sys/arm/arm/gic.c
+++ b/sys/arm/arm/gic.c
@@ -190,7 +190,7 @@
/* Read the current cpuid mask by reading ITARGETSR{0..7} */
for (i = 0; i < 8; i++) {
- mask = gic_d_read_4(sc, GICD_ITARGETSR(i));
+ mask = gic_d_read_4(sc, GICD_ITARGETSR(4 * i));
if (mask != 0)
break;
}
EMAIL PREFERENCES
https://reviews.freebsd.org/settings/panel/emailpreferences/
To: jchandra, #arm64, freebsd-arm-list, andrew
Cc: imp
[-- Attachment #2 --]
diff --git a/sys/arm/arm/gic.c b/sys/arm/arm/gic.c
--- a/sys/arm/arm/gic.c
+++ b/sys/arm/arm/gic.c
@@ -190,7 +190,7 @@
/* Read the current cpuid mask by reading ITARGETSR{0..7} */
for (i = 0; i < 8; i++) {
- mask = gic_d_read_4(sc, GICD_ITARGETSR(i));
+ mask = gic_d_read_4(sc, GICD_ITARGETSR(4 * i));
if (mask != 0)
break;
}
home |
help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?differential-rev-PHID-DREV-rk6kp4lshzqwt24lhaq4-req>
