From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.1 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id AA50CC282F6 for ; Mon, 21 Jan 2019 10:39:54 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 7BA4C2084A for ; Mon, 21 Jan 2019 10:39:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1548067194; bh=/J6AiSb4T4IvE2URHzHMlSx+kaHrrZYlZ+vOWSmhs6o=; h=Subject:To:Cc:From:Date:List-ID:From; b=DJPSGGObUG6Eo5bb0A2xhW2tf4sreVKcoa1Op9gZ7ZAbSc617yEUrFoDAg1B9OuUx d9vMMtph9V7En7A8YzDtOCl8Jo8qy/rKvxQDacVf/xj1dUE+gYI7vH/vesuplyccpu OHB6+yQhmzPe6XLv2nlL/su+HLflsSZW+qA9Kkdk= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727360AbfAUKjy (ORCPT ); Mon, 21 Jan 2019 05:39:54 -0500 Received: from new3-smtp.messagingengine.com ([66.111.4.229]:47851 "EHLO new3-smtp.messagingengine.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727178AbfAUKjx (ORCPT ); Mon, 21 Jan 2019 05:39:53 -0500 Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailnew.nyi.internal (Postfix) with ESMTP id B52C41144E; Mon, 21 Jan 2019 05:39:52 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute6.internal (MEProxy); Mon, 21 Jan 2019 05:39:52 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:message-id:mime-version:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; bh=hg/xUd /mFP2ANTIDFzUUDKcktpdy1h8WR5ZfKjmPG2E=; b=f6IuCdRw0AUvefvmrJvDz/ fm7XWOrYQNp4dcrabQNpY8DhKtiBu5zWfnvVg+9sUVvpfYypChqaeZiZVoa1aJbn dZOk6Ok0ddRJOoQzDmm4hhfxKiwwxxKsqT5Gb7ERDYIYFl5DV7cSlu+2gbWp18sR jElb2tak0DmoxUJMrRfYd1LdJ5y7L1/+1EmKvi6Ult2/+QwrMZWfGGSFJbwFPhVV j+LhfZJKTEfUF83NpS5kX6uE2MEyMCjlPiP5/cTKLwEEWVO/tvVlnjuylsM+alk5 ZgIlzfIMVfAv7K9iw0J3Eu6/8APRJAbA+QeF+GXaApRbOvfwPZ5KqyxkTWT893DA == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedtledrheeigddulecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfhuthenuceurghilhhouhhtmecufedt tdenucgoufhprghmkfhpucdlfedttddmnecujfgurhepuffvhfffkfggtgfgsehtkeertd dttdflnecuhfhrohhmpeeoghhrvghgkhhhsehlihhnuhigfhhouhhnuggrthhiohhnrdho rhhgqeenucfkphepkeefrdekiedrkeelrddutdejnecurfgrrhgrmhepmhgrihhlfhhroh hmpehgrhgvgheskhhrohgrhhdrtghomhenucevlhhushhtvghrufhiiigvpedu X-ME-Proxy: Received: from localhost (5356596b.cm-6-7b.dynamic.ziggo.nl [83.86.89.107]) by mail.messagingengine.com (Postfix) with ESMTPA id 210D0100BB; Mon, 21 Jan 2019 05:39:51 -0500 (EST) Subject: FAILED: patch "[PATCH] powerpc/tm: Limit TM code inside PPC_TRANSACTIONAL_MEM" failed to apply to 4.19-stable tree To: leitao@debian.org, linux-kernel.bfrz@manchmal.in-ulm.de, mpe@ellerman.id.au Cc: From: Date: Mon, 21 Jan 2019 11:39:49 +0100 Message-ID: <1548067189218100@kroah.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ANSI_X3.4-1968 Content-Transfer-Encoding: 8bit Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org The patch below does not apply to the 4.19-stable tree. If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to . thanks, greg k-h ------------------ original commit in Linus's tree ------------------ >From 897bc3df8c5aebb54c32d831f917592e873d0559 Mon Sep 17 00:00:00 2001 From: Breno Leitao Date: Wed, 9 Jan 2019 11:16:45 -0200 Subject: [PATCH] powerpc/tm: Limit TM code inside PPC_TRANSACTIONAL_MEM Commit e1c3743e1a20 ("powerpc/tm: Set MSR[TS] just prior to recheckpoint") moved a code block around and this block uses a 'msr' variable outside of the CONFIG_PPC_TRANSACTIONAL_MEM, however the 'msr' variable is declared inside a CONFIG_PPC_TRANSACTIONAL_MEM block, causing a possible error when CONFIG_PPC_TRANSACTION_MEM is not defined. error: 'msr' undeclared (first use in this function) This is not causing a compilation error in the mainline kernel, because 'msr' is being used as an argument of MSR_TM_ACTIVE(), which is defined as the following when CONFIG_PPC_TRANSACTIONAL_MEM is *not* set: #define MSR_TM_ACTIVE(x) 0 This patch just fixes this issue avoiding the 'msr' variable usage outside the CONFIG_PPC_TRANSACTIONAL_MEM block, avoiding trusting in the MSR_TM_ACTIVE() definition. Cc: stable@vger.kernel.org Reported-by: Christoph Biedl Fixes: e1c3743e1a20 ("powerpc/tm: Set MSR[TS] just prior to recheckpoint") Signed-off-by: Breno Leitao Signed-off-by: Michael Ellerman diff --git a/arch/powerpc/kernel/signal_64.c b/arch/powerpc/kernel/signal_64.c index bd5e6834ca69..6794466f6420 100644 --- a/arch/powerpc/kernel/signal_64.c +++ b/arch/powerpc/kernel/signal_64.c @@ -755,11 +755,12 @@ SYSCALL_DEFINE0(rt_sigreturn) if (restore_tm_sigcontexts(current, &uc->uc_mcontext, &uc_transact->uc_mcontext)) goto badframe; - } + } else #endif - /* Fall through, for non-TM restore */ - if (!MSR_TM_ACTIVE(msr)) { + { /* + * Fall through, for non-TM restore + * * Unset MSR[TS] on the thread regs since MSR from user * context does not have MSR active, and recheckpoint was * not called since restore_tm_sigcontexts() was not called