Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp2031117imm; Thu, 24 May 2018 04:49:54 -0700 (PDT) X-Google-Smtp-Source: AB8JxZrzCEkOPjI2lZ0/BG8jZVzO7rzgQxGFayiElNi1AAh3yhUBrL3soi7Eq3BycS3BkkpJ5M4a X-Received: by 2002:a17:902:7b83:: with SMTP id w3-v6mr2571480pll.12.1527162594848; Thu, 24 May 2018 04:49:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527162594; cv=none; d=google.com; s=arc-20160816; b=FvR3KuJ6XkoGk7Nm/f3LJoLNUQaIjQ3gLCaU3tioXFHrFhEcqh6qsZ/T1LwIODNsef rL05xN1/6QEVv0g7BuKhblTxEi3Ozk66Nl+WImgrpOMq7tPGaaLbWAg7s3evVET+VXqg 3yBZmhBXEagzPHK4qYXXrf0YDuPiM2/h6wk1rE/Kz24RRHp6L6AaNe1EfVz3B3XOJhL+ n10L08DRx3i3lXByi4ZkMyk6IunJTS0L6u6nIiCTVopjXxcbNbdLL82akjYjD1Ly3+9K II3nY7k6vjRRspiDlNBm6SgZy7IdIgg3MNMa4nCnh6VWIJn/uCGGiKMbdyIZ7TBGgHC5 SBkw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=vojFtKJNldIj/hJUpUVSaS2m90DD9dI0KCXu9qeVX5w=; b=jnqGIEl+eAvKYeWN4Duu20bILlpZYr7PMY+MsQ7GKvAItKHEiVF+mUEKgqndfgH+yX XKJLgyvqMOmYpHXovZJCh+w/FCXmF44L4nNKOpdelE+lSm/4okhULtP5jZvXicloSMIT jVTuOqkZDyEgntVtq8u/ogzvEoRyC0Ia8N2RS2rHDyYW/ghHv8x5gFTcEKNly1qWwqAS n+kJrR15J22QFDZXs8yeyCJbt9IiFmq1IPqREVb8fITfWFBO1G7edihilhkoQpyfIPC5 8Ao4C3JtD5O8X0EN89OCDgv2t4CAnCmyqmYQxhywbhukXgLVDBpU/YjOqP8ruwMRy+ev PLUA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=QQdqA85/; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i125-v6si11674318pgc.88.2018.05.24.04.49.40; Thu, 24 May 2018 04:49:54 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=QQdqA85/; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S966634AbeEXJrX (ORCPT + 99 others); Thu, 24 May 2018 05:47:23 -0400 Received: from mail.kernel.org ([198.145.29.99]:59616 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S967014AbeEXJrO (ORCPT ); Thu, 24 May 2018 05:47:14 -0400 Received: from localhost (LFbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id DA433208BA; Thu, 24 May 2018 09:47:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1527155234; bh=lizKrG0+G2bTGgYALSwfpVd9jBeaYM716IO0PvxXBZA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=QQdqA85/Mlk5IqUElSmEm15whIrfPyy5i6AMEyjtTP7/Jl0PkYvB7vgjTFnc5siRz 7rjOxCEmHPhcsM7AiEXvWxNDOp8kVVvUn9FjRG0su7FyV1Ldjqnh2BMIKO7ABYvuqs VvvFPuiyyaaD7qmMG/RXAi2PsrFaVtSl4GYnNJYk= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Greg Kroah-Hartman , Martin Schwidefsky , Hendrik Brueckner Subject: [PATCH 4.9 12/96] s390/lib: use expoline for indirect branches Date: Thu, 24 May 2018 11:37:55 +0200 Message-Id: <20180524093606.287016953@linuxfoundation.org> X-Mailer: git-send-email 2.17.0 In-Reply-To: <20180524093605.602125311@linuxfoundation.org> References: <20180524093605.602125311@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.9-stable review patch. If anyone has any objections, please let me know. ------------------ From: Martin Schwidefsky [ Upstream commit 97489e0663fa700d6e7febddc43b58df98d7bcda ] The return from the memmove, memset, memcpy, __memset16, __memset32 and __memset64 functions are done with "br %r14". These are indirect branches as well and need to use execute trampolines for CONFIG_EXPOLINE=y. Cc: stable@vger.kernel.org # 4.16 Fixes: f19fbd5ed6 ("s390: introduce execute-trampolines for branches") Reviewed-by: Hendrik Brueckner Signed-off-by: Martin Schwidefsky Signed-off-by: Greg Kroah-Hartman --- arch/s390/lib/mem.S | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) --- a/arch/s390/lib/mem.S +++ b/arch/s390/lib/mem.S @@ -6,6 +6,9 @@ #include #include +#include + + GEN_BR_THUNK %r14 /* * memset implementation @@ -39,7 +42,7 @@ ENTRY(memset) .Lmemset_clear_rest: larl %r3,.Lmemset_xc ex %r4,0(%r3) - br %r14 + BR_EX %r14 .Lmemset_fill: stc %r3,0(%r2) cghi %r4,1 @@ -56,7 +59,7 @@ ENTRY(memset) .Lmemset_fill_rest: larl %r3,.Lmemset_mvc ex %r4,0(%r3) - br %r14 + BR_EX %r14 .Lmemset_xc: xc 0(1,%r1),0(%r1) .Lmemset_mvc: @@ -79,7 +82,7 @@ ENTRY(memcpy) .Lmemcpy_rest: larl %r5,.Lmemcpy_mvc ex %r4,0(%r5) - br %r14 + BR_EX %r14 .Lmemcpy_loop: mvc 0(256,%r1),0(%r3) la %r1,256(%r1)