From: James Morris Date: Wed, 22 Mar 2006 08:09:22 +0000 (-0800) Subject: [PATCH] SELinux: add slab cache for inode security struct X-Git-Tag: v2.6.17-rc1~1129^2~5 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7cae7e26f245151b9ccad868bf2edf8c8048d307;p=pandora-kernel.git [PATCH] SELinux: add slab cache for inode security struct Add a slab cache for the SELinux inode security struct, one of which is allocated for every inode instantiated by the system. The memory savings are considerable. On 64-bit, instead of the size-128 cache, we have a slab object of 96 bytes, saving 32 bytes per object. After booting, I see about 4000 of these and then about 17,000 after a kernel compile. With this patch, we save around 530KB of kernel memory in the latter case. On 32-bit, the savings are about half of this. Signed-off-by: James Morris Acked-by: Stephen Smalley Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed