summaryrefslogtreecommitdiffstats
path: root/kernel/ucount.c
diff options
context:
space:
mode:
authorEric W. Biederman <ebiederm@xmission.com>2021-10-16 12:51:58 -0500
committerEric W. Biederman <ebiederm@xmission.com>2021-10-20 10:45:34 -0500
commit99c31f9feda41d0f10d030dc04ba106c93295aa2 (patch)
treecbc53b3ce9d8731a2d3b38cfe39f02c7fa9a64a3 /kernel/ucount.c
parent5ebcbe342b1c12fae44b4f83cbeae1520e09857e (diff)
downloadlinux-stable-99c31f9feda41d0f10d030dc04ba106c93295aa2.tar.gz
linux-stable-99c31f9feda41d0f10d030dc04ba106c93295aa2.tar.bz2
linux-stable-99c31f9feda41d0f10d030dc04ba106c93295aa2.zip
ucounts: In set_cred_ucounts assume new->ucounts is non-NULL
Any cred that is destined for use by commit_creds must have a non-NULL cred->ucounts field. Only curing credential construction is a NULL cred->ucounts valid. Only abort_creds, put_cred, and put_cred_rcu needs to deal with a cred with a NULL ucount. As set_cred_ucounts is non of those case don't confuse people by handling something that can not happen. Link: https://lkml.kernel.org/r/871r4irzds.fsf_-_@disp2133 Tested-by: Yu Zhao <yuzhao@google.com> Reviewed-by: Alexey Gladkov <legion@kernel.org> Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Diffstat (limited to 'kernel/ucount.c')
0 files changed, 0 insertions, 0 deletions