From: Andrew Donnellan Date: Mon, 21 Dec 2015 07:28:37 +0000 (+1100) Subject: powerpc/powernv: Fix minor off-by-one error in opal_mce_check_early_recovery() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=dc3799bb9ab2666fa19081121f05a4e573ecae12;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git powerpc/powernv: Fix minor off-by-one error in opal_mce_check_early_recovery() Fix off-by-one error in opal_mce_check_early_recovery() when checking whether the NIP falls within OPAL space. Signed-off-by: Andrew Donnellan Signed-off-by: Michael Ellerman --- diff --git a/arch/powerpc/platforms/powernv/opal.c b/arch/powerpc/platforms/powernv/opal.c index b349dd3e76ea..81f4a3ab8743 100644 --- a/arch/powerpc/platforms/powernv/opal.c +++ b/arch/powerpc/platforms/powernv/opal.c @@ -548,7 +548,7 @@ bool opal_mce_check_early_recovery(struct pt_regs *regs) goto out; if ((regs->nip >= opal.base) && - (regs->nip <= (opal.base + opal.size))) + (regs->nip < (opal.base + opal.size))) recover_addr = find_recovery_address(regs->nip); /*