From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:44860) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SCWmE-0001Tl-Nm for qemu-devel@nongnu.org; Tue, 27 Mar 2012 09:49:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SCWm8-0008Ko-Bh for qemu-devel@nongnu.org; Tue, 27 Mar 2012 09:49:34 -0400 Received: from goliath.siemens.de ([192.35.17.28]:26087) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SCWm8-0008KJ-1w for qemu-devel@nongnu.org; Tue, 27 Mar 2012 09:49:28 -0400 Message-ID: <4F71C562.2040401@siemens.com> Date: Tue, 27 Mar 2012 15:49:22 +0200 From: Jan Kiszka MIME-Version: 1.0 References: <1332606390-3605-1-git-send-email-lee.essen@nowonline.co.uk> <1332606390-3605-2-git-send-email-lee.essen@nowonline.co.uk> In-Reply-To: <1332606390-3605-2-git-send-email-lee.essen@nowonline.co.uk> Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 2/4] Enable sigbus_reraise for Solaris List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Lee Essen Cc: Blue Swirl , =?ISO-8859-15?Q?Andreas_F=E4rber?= , qemu-devel@nongnu.org On 2012-03-24 17:26, Lee Essen wrote: > sigbus_reraise is used by the kvm_wait_io_event function and is > needed on both Linux and Solaris. This patch adds CONFIG_SOLARIS > to the current CONFIG_LINUX only ifdef. > > Signed-off-by: Lee Essen > --- > cpus.c | 4 +++- > 1 files changed, 3 insertions(+), 1 deletions(-) > > diff --git a/cpus.c b/cpus.c > index 25ba621..6550f22 100644 > --- a/cpus.c > +++ b/cpus.c > @@ -455,7 +455,7 @@ static void cpu_signal(int sig) > exit_request = 1; > } > > -#ifdef CONFIG_LINUX > +#if defined(CONFIG_LINUX) || defined(CONFIG_SOLARIS) > static void sigbus_reraise(void) > { > sigset_t set; > @@ -491,7 +491,9 @@ static void qemu_init_sigbus(void) > action.sa_sigaction = (void (*)(int, siginfo_t*, void*))sigbus_handler; > sigaction(SIGBUS, &action, NULL); > > +#if defined(CONFIG_LINUX) > prctl(PR_MCE_KILL, PR_MCE_KILL_SET, PR_MCE_KILL_EARLY, 0, 0); > +#endif BTW, this looks suspicious. Are you sure Solaris delivers a compatible SIGBUS with all the information KVM needs to translate it to a MCE? That is not a KVM subsystem feature, it's a kernel feature that Solaris would either have to provide in the same way as Linux, or you need some glue code to translate the differences. Jan -- Siemens AG, Corporate Technology, CT T DE IT 1 Corporate Competence Center Embedded Linux