Received: by 10.223.176.5 with SMTP id f5csp2858817wra; Mon, 5 Feb 2018 11:04:41 -0800 (PST) X-Google-Smtp-Source: AH8x224iG7l5YncEwYwpeRG+8+hwzy/brdUVT5KgTOwTVx2FINTgEUi2+mGwlAOWpGufqI27T7OQ X-Received: by 2002:a17:902:8c89:: with SMTP id t9-v6mr43132378plo.2.1517857481196; Mon, 05 Feb 2018 11:04:41 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1517857481; cv=none; d=google.com; s=arc-20160816; b=mAFM4OBXhkvh7GuofzYDWPSpluwl/udhQ/8D56ih8R6kSDlaw/jNbMN3ZZv24nAWdz ouftmstzLEwjzVwwRyO3MnFtqPhKb2l3sV8ICVz9IkXBuRa0qYbOBf24N47RFQAY1dD1 puWfiWNIia2FvttElGVrRfV3ObFcuC8oJRgShJlqW/CD/RcO6AVTQlWeKIRg8Yr0e2W2 s9N54tP2FIFgAfFlydQPpiYCUDhqw2dChQmru/W5JKVoDCSwgPu+YtuLHcqxGf7LwwbX mNZ2b0cxm5uscTldX4cy082v3wsGGQjg3IkfZFpY1zWCwZPR+1B0Rb20dCQyRjRyJVZ7 +cEg== 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 :arc-authentication-results; bh=5LFrGL3hViVR6YbViR/Td5evOcFa4raCNbnrNG8QQjM=; b=Q4MpzmmlCuL74mVFHf8e5XcwplWVBlmnvtXZwQTVjhoJyz7r8rRTSEbCKDucIsXMGe VTaB4e57Jaop6/IarWJTavnZKEGUz4J9AV/0yVf9p132fmvtgq/o3tONcOl1CmmsAol/ dxSHSstqLsuwQsU3vG09zn6n4Wg8LhpqHqDEd1ykyFyzYurlyfvfx/mzBs1zV0R5iABo XOrhNtfEIveeQaYZt2wXSa7B8/zKAGC6zGzNFmWepbhMY79/UCSzLH48zTmcYQSsTmmo 3/KIY/1LHtWcNKghNRzLmOk2FUOOc9Bs79nFyvkM1ncP0fxhPIpGg4+Y3qOtDLBrrD/f O0wA== ARC-Authentication-Results: i=1; mx.google.com; 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 v85si1156390pfk.57.2018.02.05.11.04.26; Mon, 05 Feb 2018 11:04:41 -0800 (PST) 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; 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 S1753682AbeBETDd (ORCPT + 99 others); Mon, 5 Feb 2018 14:03:33 -0500 Received: from mail.linuxfoundation.org ([140.211.169.12]:51616 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753246AbeBESY0 (ORCPT ); Mon, 5 Feb 2018 13:24:26 -0500 Received: from localhost (unknown [104.132.1.108]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 9D2A610B8; Mon, 5 Feb 2018 18:24:21 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Josh Poimboeuf , Thomas Gleixner , Juergen Gross , Andrea Arcangeli , Peter Zijlstra , Andi Kleen , Ashok Raj , Jun Nakajima , Tim Chen , Rusty Russell , Dave Hansen , Asit Mallick , Andy Lutomirski , Linus Torvalds , Jason Baron , Paolo Bonzini , Alok Kataria , Arjan Van De Ven , David Woodhouse , Dan Williams Subject: [PATCH 4.14 51/64] x86/paravirt: Remove noreplace-paravirt cmdline option Date: Mon, 5 Feb 2018 10:23:10 -0800 Message-Id: <20180205182140.667697807@linuxfoundation.org> X-Mailer: git-send-email 2.16.1 In-Reply-To: <20180205182138.571333346@linuxfoundation.org> References: <20180205182138.571333346@linuxfoundation.org> User-Agent: quilt/0.65 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.14-stable review patch. If anyone has any objections, please let me know. ------------------ From: Josh Poimboeuf jpoimboe@redhat.com commit 12c69f1e94c89d40696e83804dd2f0965b5250cd The 'noreplace-paravirt' option disables paravirt patching, leaving the original pv indirect calls in place. That's highly incompatible with retpolines, unless we want to uglify paravirt even further and convert the paravirt calls to retpolines. As far as I can tell, the option doesn't seem to be useful for much other than introducing surprising corner cases and making the kernel vulnerable to Spectre v2. It was probably a debug option from the early paravirt days. So just remove it. Signed-off-by: Josh Poimboeuf Signed-off-by: Thomas Gleixner Reviewed-by: Juergen Gross Cc: Andrea Arcangeli Cc: Peter Zijlstra Cc: Andi Kleen Cc: Ashok Raj Cc: Greg KH Cc: Jun Nakajima Cc: Tim Chen Cc: Rusty Russell Cc: Dave Hansen Cc: Asit Mallick Cc: Andy Lutomirski Cc: Linus Torvalds Cc: Jason Baron Cc: Paolo Bonzini Cc: Alok Kataria Cc: Arjan Van De Ven Cc: David Woodhouse Cc: Dan Williams Link: https://lkml.kernel.org/r/20180131041333.2x6blhxirc2kclrq@treble Signed-off-by: Greg Kroah-Hartman --- Documentation/admin-guide/kernel-parameters.txt | 2 -- arch/x86/kernel/alternative.c | 14 -------------- 2 files changed, 16 deletions(-) --- a/Documentation/admin-guide/kernel-parameters.txt +++ b/Documentation/admin-guide/kernel-parameters.txt @@ -2718,8 +2718,6 @@ norandmaps Don't use address space randomization. Equivalent to echo 0 > /proc/sys/kernel/randomize_va_space - noreplace-paravirt [X86,IA-64,PV_OPS] Don't patch paravirt_ops - noreplace-smp [X86-32,SMP] Don't replace SMP instructions with UP alternatives --- a/arch/x86/kernel/alternative.c +++ b/arch/x86/kernel/alternative.c @@ -46,17 +46,6 @@ static int __init setup_noreplace_smp(ch } __setup("noreplace-smp", setup_noreplace_smp); -#ifdef CONFIG_PARAVIRT -static int __initdata_or_module noreplace_paravirt = 0; - -static int __init setup_noreplace_paravirt(char *str) -{ - noreplace_paravirt = 1; - return 1; -} -__setup("noreplace-paravirt", setup_noreplace_paravirt); -#endif - #define DPRINTK(fmt, args...) \ do { \ if (debug_alternative) \ @@ -599,9 +588,6 @@ void __init_or_module apply_paravirt(str struct paravirt_patch_site *p; char insnbuf[MAX_PATCH_LEN]; - if (noreplace_paravirt) - return; - for (p = start; p < end; p++) { unsigned int used;