From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH] Prevent trace call into unloaded module text Date: Wed, 26 Nov 2008 13:17:55 +0200 Message-ID: <492D3063.3030906@redhat.com> References: <20081124140427.GA14640@localhost> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: kvm@vger.kernel.org To: Wu Fengguang Return-path: Received: from mx2.redhat.com ([66.187.237.31]:51891 "EHLO mx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751814AbYKZLSB (ORCPT ); Wed, 26 Nov 2008 06:18:01 -0500 In-Reply-To: <20081124140427.GA14640@localhost> Sender: kvm-owner@vger.kernel.org List-ID: Wu Fengguang wrote: > Add marker_synchronize_unregister() before module unloading. > This prevents possible trace calls into unloaded module text. > > Signed-off-by: Wu Fengguang > --- > diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c > index a87f45e..64f38b3 100644 > --- a/virt/kvm/kvm_main.c > +++ b/virt/kvm/kvm_main.c > @@ -2102,5 +2102,6 @@ void kvm_exit(void) > kvm_arch_exit(); > kvm_exit_debug(); > __free_page(bad_page); > + marker_synchronize_unregister(); > } > EXPORT_SYMBOL_GPL(kvm_exit); > What about kvm-intel.ko and kvm-amd.ko? They also contain markers. (and, why doesn't module unload do this automatically?) -- error compiling committee.c: too many arguments to function