Izik Eidus wrote:
>  void kvm_mmu_module_exit(void)
>  {
>       if (pte_chain_cache)
> @@ -1980,6 +2026,7 @@ void kvm_mmu_module_exit(void)
>               kmem_cache_destroy(rmap_desc_cache);
>       if (mmu_page_header_cache)
>               kmem_cache_destroy(mmu_page_header_cache);
> +     unregister_shrinker(&mmu_shrinker);
>  }
>   

kvm_mmu_module_exit() can be called from the nomem: label below, so the 
shrinker will be unregistered despite not being registered.

Suggest renaming kvm_mmu_module_exit() to mmu_destroy_caches(), and 
adding a new kvm_mmu_module_exit() which will call mmu_destroy_caches() 
and unregister_shrinker().

>  
>  int kvm_mmu_module_init(void)
> @@ -2001,6 +2048,8 @@ int kvm_mmu_module_init(void)
>       if (!mmu_page_header_cache)
>               goto nomem;
>  
> +     register_shrinker(&mmu_shrinker);
> +
>       return 0;
>  
>  nomem:
>   


-- 
error compiling committee.c: too many arguments to function


-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
_______________________________________________
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel

Reply via email to