Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934700AbcJUJcC (ORCPT ); Fri, 21 Oct 2016 05:32:02 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:47115 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933343AbcJUJVc (ORCPT ); Fri, 21 Oct 2016 05:21:32 -0400 From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Evgeny Voevodin , Vineet Gupta Subject: [PATCH 4.8 06/57] ARCv2: fix local_save_flags Date: Fri, 21 Oct 2016 11:17:29 +0200 Message-Id: <20161021091435.734981474@linuxfoundation.org> X-Mailer: git-send-email 2.10.0 In-Reply-To: <20161021091435.435647262@linuxfoundation.org> References: <20161021091435.435647262@linuxfoundation.org> User-Agent: quilt/0.64 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1137 Lines: 35 4.8-stable review patch. If anyone has any objections, please let me know. ------------------ From: Vineet Gupta commit cd5d38b052384daa2893e9a1d94900d5a20ed4b5 upstream. Commit d9676fa152c83b ("ARCv2: Enable LOCKDEP"), changed local_save_flags() to not return raw STATUS32 but encoded in the form such that it could be fed directly to CLRI/SETI instructions. However the STATUS32.E[] was not captured correctly as it corresponds to bits [4:1] in the register and not [3:0] Fixes: d9676fa152c83b ("ARCv2: Enable LOCKDEP") Cc: Evgeny Voevodin Signed-off-by: Vineet Gupta Signed-off-by: Greg Kroah-Hartman --- arch/arc/include/asm/irqflags-arcv2.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/arch/arc/include/asm/irqflags-arcv2.h +++ b/arch/arc/include/asm/irqflags-arcv2.h @@ -112,7 +112,7 @@ static inline long arch_local_save_flags */ temp = (1 << 5) | ((!!(temp & STATUS_IE_MASK)) << CLRI_STATUS_IE_BIT) | - (temp & CLRI_STATUS_E_MASK); + ((temp >> 1) & CLRI_STATUS_E_MASK); return temp; }