From patchwork Mon Jun 19 18:30:40 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Willy Tarreau X-Patchwork-Id: 777936 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3ws06Y4jZcz9s82 for ; Tue, 20 Jun 2017 04:36:01 +1000 (AEST) Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="bg2Im/We"; dkim-atps=neutral DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=AZF9hQrcTMTFN/I/cdyGBvq8MyM+8oq14ubDObVKSj0=; b=bg2Im/We6utLb0CjG/l+CSlql+ /jUyZI0AbkCTIlHbfcVtUdItyOmIP/5zd1j1EnuO+MDOeTzPanbRGHsWTzmEkwLHxmWb87eoaNJgK BOUlJYVnFuDw3q0EnxVIB7sskQW1oMZ06Q1wKHujAM8G8c55Wsenl4/B69e6+Wvanr0+GRjAdEmJH 6VZc6S+WMLRLGuo3vhZdsU+FTXlhwe8KQELQVDaDgovaJVXCOWuAmDVoTLBzNU9HknExXoV1GrcTc h96LWWLEIjf5YjeOdKkeYeHpMnKhyPAHDVNf9W98MRyR9SWUWsN7rqQ15EH6T167OGyyyo1PiU+F9 NuJ8jKXg==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1dN1Wo-0004iY-V6; Mon, 19 Jun 2017 18:35:58 +0000 Received: from wtarreau.pck.nerim.net ([62.212.114.60] helo=1wt.eu) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1dN1Wl-0004MC-CD for linux-snps-arc@lists.infradead.org; Mon, 19 Jun 2017 18:35:57 +0000 Received: (from willy@localhost) by pcw.home.local (8.15.2/8.15.2/Submit) id v5JIXWiO015007; Mon, 19 Jun 2017 20:33:32 +0200 From: Willy Tarreau To: linux-kernel@vger.kernel.org, stable@vger.kernel.org, linux@roeck-us.net Subject: [PATCH 3.10 141/268] ARC: [arcompact] brown paper bag bug in unaligned access delay slot fixup Date: Mon, 19 Jun 2017 20:30:40 +0200 Message-Id: <1497897167-14556-142-git-send-email-w@1wt.eu> X-Mailer: git-send-email 2.8.0.rc2.1.gbe9624a In-Reply-To: <1497897167-14556-1-git-send-email-w@1wt.eu> References: <1497897167-14556-1-git-send-email-w@1wt.eu> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170619_113555_828154_C5518545 X-CRM114-Status: UNSURE ( 6.37 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -1.9 (-) X-Spam-Report: SpamAssassin version 3.4.1 on bombadil.infradead.org summary: Content analysis details: (-1.9 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at http://www.dnswl.org/, no trust [62.212.114.60 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record -0.0 SPF_HELO_PASS SPF: HELO matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-BeenThere: linux-snps-arc@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Linux on Synopsys ARC Processors List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Vineet Gupta , Vineet Gupta , linux-snps-arc@lists.infradead.org, Linus Torvalds , Willy Tarreau MIME-Version: 1.0 Sender: "linux-snps-arc" Errors-To: linux-snps-arc-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org From: Vineet Gupta commit a524c218bc94c705886a0e0fedeee45d1931da32 upstream. Reported-by: Jo-Philipp Wich Fixes: 9aed02feae57bf7 ("ARC: [arcompact] handle unaligned access delay slot") Cc: linux-kernel@vger.kernel.org Cc: linux-snps-arc@lists.infradead.org Signed-off-by: Vineet Gupta Signed-off-by: Linus Torvalds Signed-off-by: Willy Tarreau --- arch/arc/kernel/unaligned.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arc/kernel/unaligned.c b/arch/arc/kernel/unaligned.c index b13b422..e6b365d 100644 --- a/arch/arc/kernel/unaligned.c +++ b/arch/arc/kernel/unaligned.c @@ -230,7 +230,7 @@ int misaligned_fixup(unsigned long address, struct pt_regs *regs, /* clear any remanants of delay slot */ if (delay_mode(regs)) { - regs->ret = regs->bta ~1U; + regs->ret = regs->bta & ~1U; regs->status32 &= ~STATUS_DE_MASK; } else { regs->ret += state.instr_len;