[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen stable-4.7] xen/arm: cpuerrata: Actually check errata on non-boot CPUs



commit c64e0c1cb5cda34407f8b2a0998418ad4562db54
Author:     Julien Grall <julien.grall@xxxxxxx>
AuthorDate: Wed Feb 14 12:22:23 2018 +0000
Commit:     Stefano Stabellini <sstabellini@xxxxxxxxxx>
CommitDate: Tue Feb 20 17:18:05 2018 -0800

    xen/arm: cpuerrata: Actually check errata on non-boot CPUs
    
    The cpu errata framework was introduced in commit 8b01f6364f "xen/arm:
    Detect silicon revision and set cap bits accordingly" and was meant to
    detect errata present on any CPUs (via check_local_cpu_errata). However,
    the function to check the MIDR (is_affected_midr_range) mistakenly
    always use the boot CPU MIDR.
    
    Fix is_affected_midr_range to use the current CPU MIDR.
    
    Reported-by: Stefano Stabellini <sstabellini@xxxxxxxxxx>
    Signed-off-by: Julien Grall <julien.grall@xxxxxxx>
    Reviewed-by: Stefano Stabellini <sstabellini@xxxxxxxxxx>
    (cherry picked from commit 27196d4cc917d91b5b5daee50173565139ca9c9d)
---
 xen/arch/arm/cpuerrata.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/xen/arch/arm/cpuerrata.c b/xen/arch/arm/cpuerrata.c
index 9329864..eaa91e0 100644
--- a/xen/arch/arm/cpuerrata.c
+++ b/xen/arch/arm/cpuerrata.c
@@ -226,7 +226,7 @@ static int enable_ic_inv_hardening(void *data)
 static bool_t __maybe_unused
 is_affected_midr_range(const struct arm_cpu_capabilities *entry)
 {
-    return MIDR_IS_CPU_MODEL_RANGE(boot_cpu_data.midr.bits, entry->midr_model,
+    return MIDR_IS_CPU_MODEL_RANGE(current_cpu_data.midr.bits, 
entry->midr_model,
                                    entry->midr_range_min,
                                    entry->midr_range_max);
 }
--
generated by git-patchbot for /home/xen/git/xen.git#stable-4.7

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/xen-changelog

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.