aboutsummaryrefslogtreecommitdiff
path: root/kernel/audit.h
diff options
context:
space:
mode:
authorColin Ian King2020-10-29 15:11:03 +0000
committerPeter Zijlstra2020-11-10 18:38:49 +0100
commit8d4d9c7b4333abccb3bf310d76ef7ea2edb9828f (patch)
treee3a18d575d44955453501aa05b0dee98184162c5 /kernel/audit.h
parentb4c9c9f15649c98a5b45408919d1ff4fd7f5531c (diff)
sched/debug: Fix memory corruption caused by multiple small reads of flags
Reading /proc/sys/kernel/sched_domain/cpu*/domain0/flags mutliple times with small reads causes oopses with slub corruption issues because the kfree is free'ing an offset from a previous allocation. Fix this by adding in a new pointer 'buf' for the allocation and kfree and use the temporary pointer tmp to handle memory copies of the buf offsets. Fixes: 5b9f8ff7b320 ("sched/debug: Output SD flag names rather than their values") Reported-by: Jeff Bastian <jbastian@redhat.com> Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Reviewed-by: Valentin Schneider <valentin.schneider@arm.com> Link: https://lkml.kernel.org/r/20201029151103.373410-1-colin.king@canonical.com
Diffstat (limited to 'kernel/audit.h')
0 files changed, 0 insertions, 0 deletions