Support procfs inode defragmentation Cc: Alexey Dobriyan <adobriyan@xxxxx> Reviewed-by: Rik van Riel <riel@xxxxxxxxxx> Signed-off-by: Christoph Lameter <clameter@xxxxxxx> Signed-off-by: Christoph Lameter <cl@xxxxxxxxxxxxxxxxxxxx> --- fs/proc/inode.c | 8 ++++++++ 1 files changed, 8 insertions(+), 0 deletions(-) Index: linux-2.6/fs/proc/inode.c =================================================================== --- linux-2.6.orig/fs/proc/inode.c 2008-07-31 12:18:12.000000000 -0500 +++ linux-2.6/fs/proc/inode.c 2008-07-31 12:18:15.000000000 -0500 @@ -106,6 +106,12 @@ inode_init_once(&ei->vfs_inode); } +static void *proc_get_inodes(struct kmem_cache *s, int nr, void **v) +{ + return fs_get_inodes(s, nr, v, + offsetof(struct proc_inode, vfs_inode)); +}; + int __init proc_init_inodecache(void) { proc_inode_cachep = kmem_cache_create("proc_inode_cache", @@ -113,6 +119,8 @@ 0, (SLAB_RECLAIM_ACCOUNT| SLAB_MEM_SPREAD|SLAB_PANIC), init_once); + kmem_cache_setup_defrag(proc_inode_cachep, + proc_get_inodes, kick_inodes); return 0; } -- -- To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html