IMA: only allocate iint when needed
authorEric Paris <eparis@redhat.com>
Mon, 25 Oct 2010 18:42:05 +0000 (14:42 -0400)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 26 Oct 2010 18:37:18 +0000 (11:37 -0700)
commitbc7d2a3e66b40477270c3cbe3b89b47093276e7a
tree8f0198b8ad455fde11b24e32a2e32c008a5ececb
parenta178d2027d3198b0a04517d764326ab71cd73da2
IMA: only allocate iint when needed

IMA always allocates an integrity structure to hold information about
every inode, but only needed this structure to track the number of
readers and writers currently accessing a given inode.  Since that
information was moved into struct inode instead of the integrity struct
this patch stops allocating the integrity stucture until it is needed.
Thus greatly reducing memory usage.

Signed-off-by: Eric Paris <eparis@redhat.com>
Acked-by: Mimi Zohar <zohar@linux.vnet.ibm.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
security/integrity/ima/ima_main.c
security/security.c