summaryrefslogtreecommitdiff
path: root/drivers/cpufreq/amd_freq_sensitivity.c
diff options
context:
space:
mode:
authorZheng Yongjun <zhengyongjun3@huawei.com>2020-12-29 16:48:34 +0300
committerAlexei Starovoitov <ast@kernel.org>2021-01-09 00:39:24 +0300
commitec24e11e0817404ef9e04b50170e1a68793cd9f5 (patch)
tree93eece960e473dc112aa44952fc783cb6363ef9e /drivers/cpufreq/amd_freq_sensitivity.c
parent619775c3cfd2bc8559abc4395bf7d85b72bd723f (diff)
downloadlinux-ec24e11e0817404ef9e04b50170e1a68793cd9f5.tar.xz
bpf: Replace fput with sockfd_put in sock map
The function sockfd_lookup uses fget on the value that is stored in the file field of the returned structure, so fput should ultimately be applied to this value. This can be done directly, but it seems better to use the specific macro sockfd_put, which does the same thing. The cleanup was done using the following semantic patch: (http://www.emn.fr/x-info/coccinelle/) // <smpl> @@ expression s; @@ s = sockfd_lookup(...) ... + sockfd_put(s); ?- fput(s->file); // </smpl> Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Link: https://lore.kernel.org/bpf/20201229134834.22962-1-zhengyongjun3@huawei.com Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'drivers/cpufreq/amd_freq_sensitivity.c')
0 files changed, 0 insertions, 0 deletions