Blame SOURCES/github_ddace972_exception_frame.patch

4eb2a4
commit ddace9720fe7582cd2c92000f75f1f261daa53fd
4eb2a4
Author: Dave Anderson <anderson@redhat.com>
4eb2a4
Date:   Fri Feb 9 16:26:27 2018 -0500
4eb2a4
4eb2a4
    Fix for the ARM64 "bt" command in kernels that contain commit
4eb2a4
    30d88c0e3ace625a92eead9ca0ad94093a8f59fe, titled "arm64: entry:
4eb2a4
    Apply BP hardening for suspicious interrupts from EL0".  Without
4eb2a4
    the patch, there may be invalid kernel kernel exception frames
4eb2a4
    displayed on an active task's kernel stack, often below a stackframe
4eb2a4
    of the "do_el0_ia_bp_hardening" function; the address translation
4eb2a4
    of the PC and LR values in the the bogus exception frame will
4eb2a4
    display "[unknown or invalid address]".
4eb2a4
    (anderson@redhat.com)
4eb2a4
4eb2a4
4eb2a4
--- crash-7.2.0/arm64.c.orig
4eb2a4
+++ crash-7.2.0/arm64.c
4eb2a4
@@ -2411,8 +2411,10 @@ arm64_back_trace_cmd(struct bt_info *bt)
4eb2a4
 
4eb2a4
 		if (arm64_in_exception_text(bt->instptr) && INSTACK(stackframe.fp, bt)) {
4eb2a4
 			if (!(bt->flags & BT_IRQSTACK) ||
4eb2a4
-			    (((stackframe.sp + SIZE(pt_regs)) < bt->stacktop)))
4eb2a4
-				exception_frame = stackframe.fp - KERN_EFRAME_OFFSET;
4eb2a4
+			    ((stackframe.sp + SIZE(pt_regs)) < bt->stacktop)) {
4eb2a4
+				if (arm64_is_kernel_exception_frame(bt, stackframe.fp - KERN_EFRAME_OFFSET))
4eb2a4
+					exception_frame = stackframe.fp - KERN_EFRAME_OFFSET;
4eb2a4
+			}
4eb2a4
 		}
4eb2a4
 
4eb2a4
 		if ((bt->flags & BT_IRQSTACK) &&