make the conditional a static inline instead of doing it in generic code.
Showing the changes to kernel (2 of 3 files). Show all
Unified · Split
| @@ -1594,7 +1594,7 @@ static void audit_log_exit(struct audit_context *context, struct task_struct *ts · 1593 unmodified lines | |||
| 1594 | * | 1594 | * |
| 1595 | * Called from copy_process and do_exit | 1595 | * Called from copy_process and do_exit |
| 1596 | */ | 1596 | */ |
| 1597 | void audit_free(struct task_struct *tsk) | 1597 | void __audit_free(struct task_struct *tsk) |
| 1598 | { | 1598 | { |
| 1599 | struct audit_context *context; | 1599 | struct audit_context *context; |
| 1600 | 1600 | ||
| @@ -964,8 +964,7 @@ NORET_TYPE void do_exit(long code) · 963 unmodified lines | |||
| 964 | acct_collect(code, group_dead); | 964 | acct_collect(code, group_dead); |
| 965 | if (group_dead) | 965 | if (group_dead) |
| 966 | tty_audit_exit(); | 966 | tty_audit_exit(); |
| 967 | if (unlikely(tsk->audit_context)) | 967 | audit_free(tsk); |
| 968 | audit_free(tsk); | ||
| 969 | 968 | ||
| 970 | tsk->exit_code = code; | 969 | tsk->exit_code = code; |
| 971 | taskstats_exit(tsk, group_dead); | 970 | taskstats_exit(tsk, group_dead); |