[linux-cifs-client] Re: [PATCH] cifs: fix slab memory pool
destruction order
Steve French
smfrench at gmail.com
Mon Jun 4 16:15:23 GMT 2007
Merged into cifs tree
Thanks.
On 6/3/07, Akinobu Mita <akinobu.mita at gmail.com> wrote:
> Slab cache used as memory pool can not be destroyed before the memory
> pool destruction. Because the memory pool still holds some objects and
> kmem_cache_destroy() says "Can't free all objects".
>
> Cc: Steve French <sfrench at samba.org>
> Signed-off-by: Akinobu Mita <akinobu.mita at gmail.com>
>
> Index: 2.6-mm/fs/cifs/cifsfs.c
> ===================================================================
> --- 2.6-mm.orig/fs/cifs/cifsfs.c
> +++ 2.6-mm/fs/cifs/cifsfs.c
> @@ -825,8 +825,8 @@ cifs_init_mids(void)
> sizeof (struct oplock_q_entry), 0,
> SLAB_HWCACHE_ALIGN, NULL, NULL);
> if (cifs_oplock_cachep == NULL) {
> - kmem_cache_destroy(cifs_mid_cachep);
> mempool_destroy(cifs_mid_poolp);
> + kmem_cache_destroy(cifs_mid_cachep);
> return -ENOMEM;
> }
>
>
--
Thanks,
Steve
More information about the linux-cifs-client
mailing list