Re: [PATCH 1/1] kernfs: Allocating memory for kernfs_iattrs with kmem_cache.

From: Greg KH
Date: Thu Jan 31 2019 - 07:32:12 EST


On Thu, Jan 31, 2019 at 03:13:05PM +0530, Ayush Mittal wrote:
> @@ -414,4 +414,9 @@ void __init kernfs_init(void)
> 0,
> SLAB_PANIC | SLAB_TYPESAFE_BY_RCU,
> NULL);
> + kernfs_iattrs_cache = kmem_cache_create("kernfs_iattrs_cache",
> + sizeof(struct kernfs_iattrs),
> + 0,
> + SLAB_PANIC | SLAB_TYPESAFE_BY_RCU,
> + NULL);
> }

Are you sure the comment above this holds true for this new cache as
well? Please document it as well as the other one was, and remove the
SLAB_ flags as needed.

thanks,

greg k-h