lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20150811074454.GI16853@twins.programming.kicks-ass.net>
Date:	Tue, 11 Aug 2015 09:44:54 +0200
From:	Peter Zijlstra <peterz@...radead.org>
To:	Larry Finger <Larry.Finger@...inger.net>
Cc:	Paolo Bonzini <pbonzini@...hat.com>,
	LKML <linux-kernel@...r.kernel.org>
Subject: Re: Kernel crashes in VirtualBox module after commit 2ecd9d29abb1

On Mon, Aug 10, 2015 at 04:49:49PM -0500, Larry Finger wrote:
> A problem with the VirtualBox kernel module vboxdrv.ko has been bisected to
> commit 2ecd9d29abb1 "sched, preempt_notifier: separate notifier registration
> from static_key inc/dec".  The affected kernels crash is various ways. The
> most instructive includes a warning issued at kernel/sched/core.c:2342 in
> prempt_notifier_register() for "registering prempt_notifier while notifiers
> disabled" The call from vboxdrv is as follows:
> 
>         /*
>          * Register the callback.
>          */
>         preempt_disable();
>         pThis->fEnabled = true;
>         preempt_notifier_register(&pThis->LnxPreemptNotifier);
>         preempt_enable();
> 
> As I have no reason to suspect the kernel after this patch, I would like
> some suggestions regarding the best method to patch/fix the VirtualBox code.

You have to call preempt_notifier_inc() when creating your virtual box
instance _before_ creating your vCPU threads which will register the
preempt_notifiers.

You also have to call a matching preempt_notifier_dec() when destroying
your virtual box instance.

The patch you refer adds these calls in
kvm_create_vm()/kvm_destroy_vm(). Mirror that and things should work
again.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ