diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2012-04-02 18:48:12 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2012-04-03 12:49:59 -0400 |
commit | b61c37f57988567c84359645f8202a7c84bc798a (patch) | |
tree | a808c891711d060060a751f4119198dc06e2c847 /security/smack/smack_access.c | |
parent | 3f0882c48286e7bdb0bbdec9c4bfa934e0db8e09 (diff) |
lsm_audit: don't specify the audit pre/post callbacks in 'struct common_audit_data'
It just bloats the audit data structure for no good reason, since the
only time those fields are filled are just before calling the
common_lsm_audit() function, which is also the only user of those
fields.
So just make them be the arguments to common_lsm_audit(), rather than
bloating that structure that is passed around everywhere, and is
initialized in hot paths.
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'security/smack/smack_access.c')
-rw-r--r-- | security/smack/smack_access.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/security/smack/smack_access.c b/security/smack/smack_access.c index 2af7fcc98a71..c8115f7308f8 100644 --- a/security/smack/smack_access.c +++ b/security/smack/smack_access.c | |||
@@ -321,9 +321,8 @@ void smack_log(char *subject_label, char *object_label, int request, | |||
321 | sad->object = object_label; | 321 | sad->object = object_label; |
322 | sad->request = request_buffer; | 322 | sad->request = request_buffer; |
323 | sad->result = result; | 323 | sad->result = result; |
324 | a->lsm_pre_audit = smack_log_callback; | ||
325 | 324 | ||
326 | common_lsm_audit(a); | 325 | common_lsm_audit(a, smack_log_callback, NULL); |
327 | } | 326 | } |
328 | #else /* #ifdef CONFIG_AUDIT */ | 327 | #else /* #ifdef CONFIG_AUDIT */ |
329 | void smack_log(char *subject_label, char *object_label, int request, | 328 | void smack_log(char *subject_label, char *object_label, int request, |