X-Git-Url: https://git.proxmox.com/?a=blobdiff_plain;f=kernel%2Ffutex.c;h=1f450e092c7416e3d43aba84da7b73b9a2a47b3d;hb=6c86eedc206dd1f9d37a2796faa8e6f2278215d2;hp=7f719d11090810622ff010c0b8adc3fe954c478d;hpb=68c5735eaa5e680e701c9a2d1e3c7880bdf5ab66;p=mirror_ubuntu-hirsute-kernel.git diff --git a/kernel/futex.c b/kernel/futex.c index 7f719d110908..1f450e092c74 100644 --- a/kernel/futex.c +++ b/kernel/futex.c @@ -862,24 +862,6 @@ static void put_pi_state(struct futex_pi_state *pi_state) } } -/* - * Look up the task based on what TID userspace gave us. - * We dont trust it. - */ -static struct task_struct *futex_find_get_task(pid_t pid) -{ - struct task_struct *p; - - rcu_read_lock(); - p = find_task_by_vpid(pid); - if (p) - get_task_struct(p); - - rcu_read_unlock(); - - return p; -} - #ifdef CONFIG_FUTEX_PI /* @@ -1183,7 +1165,7 @@ static int attach_to_pi_owner(u32 uval, union futex_key *key, */ if (!pid) return -ESRCH; - p = futex_find_get_task(pid); + p = find_get_task_by_vpid(pid); if (!p) return -ESRCH;