From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752950AbeANUjd (ORCPT + 1 other); Sun, 14 Jan 2018 15:39:33 -0500 Received: from terminus.zytor.com ([65.50.211.136]:35403 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752231AbeANUjb (ORCPT ); Sun, 14 Jan 2018 15:39:31 -0500 Date: Sun, 14 Jan 2018 12:38:22 -0800 From: tip-bot for Jan Kiszka Message-ID: Cc: hpa@zytor.com, tglx@linutronix.de, linux-kernel@vger.kernel.org, jan.kiszka@siemens.com, mingo@kernel.org Reply-To: tglx@linutronix.de, linux-kernel@vger.kernel.org, hpa@zytor.com, jan.kiszka@siemens.com, mingo@kernel.org In-Reply-To: References: To: linux-tip-commits@vger.kernel.org Subject: [tip:x86/platform] x86/jailhouse: Halt instead of failing to restart Git-Commit-ID: fd498076821739db38babe72602f7c227587cbb5 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Return-Path: Commit-ID: fd498076821739db38babe72602f7c227587cbb5 Gitweb: https://git.kernel.org/tip/fd498076821739db38babe72602f7c227587cbb5 Author: Jan Kiszka AuthorDate: Mon, 27 Nov 2017 09:11:52 +0100 Committer: Thomas Gleixner CommitDate: Sun, 14 Jan 2018 21:11:57 +0100 x86/jailhouse: Halt instead of failing to restart Jailhouse provides no guest-initiated restart. So, do not even try to. Signed-off-by: Jan Kiszka Signed-off-by: Thomas Gleixner Cc: jailhouse-dev@googlegroups.com Link: https://lkml.kernel.org/r/ef8a0ef95c2b17c21066e5f28ea56b58bf7eaa82.1511770314.git.jan.kiszka@siemens.com --- arch/x86/kernel/jailhouse.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/arch/x86/kernel/jailhouse.c b/arch/x86/kernel/jailhouse.c index 54469ef..2b55672 100644 --- a/arch/x86/kernel/jailhouse.c +++ b/arch/x86/kernel/jailhouse.c @@ -10,10 +10,12 @@ #include #include +#include #include #include #include #include +#include #include static __initdata struct jailhouse_setup_data setup_data; @@ -77,6 +79,12 @@ static void __init jailhouse_get_smp_config(unsigned int early) smp_found_config = 1; } +static void jailhouse_no_restart(void) +{ + pr_notice("Jailhouse: Restart not supported, halting\n"); + machine_halt(); +} + static void __init jailhouse_init_platform(void) { u64 pa_data = boot_params.hdr.setup_data; @@ -96,6 +104,8 @@ static void __init jailhouse_init_platform(void) legacy_pic = &null_legacy_pic; + machine_ops.emergency_restart = jailhouse_no_restart; + while (pa_data) { mapping = early_memremap(pa_data, sizeof(header)); memcpy(&header, mapping, sizeof(header));