diff options
author | Alastair D'Silva <alastair@d-silva.org> | 2018-05-11 16:12:59 +1000 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2018-06-03 20:40:31 +1000 |
commit | 71cc64a85d8d99936f6851709a07f18c87a0adab (patch) | |
tree | d24635c72fdf6d279c20574381df9b722f54cc0e /drivers/misc/ocxl/link.c | |
parent | 3449f191ca9be1a6ac9757b8ab55f239092362e5 (diff) | |
download | kernel_replicant_linux-71cc64a85d8d99936f6851709a07f18c87a0adab.tar.gz kernel_replicant_linux-71cc64a85d8d99936f6851709a07f18c87a0adab.tar.bz2 kernel_replicant_linux-71cc64a85d8d99936f6851709a07f18c87a0adab.zip |
powerpc: use task_pid_nr() for TID allocation
The current implementation of TID allocation, using a global IDR, may
result in an errant process starving the system of available TIDs.
Instead, use task_pid_nr(), as mentioned by the original author. The
scenario described which prevented it's use is not applicable, as
set_thread_tidr can only be called after the task struct has been
populated.
In the unlikely event that 2 threads share the TID and are waiting,
all potential outcomes have been determined safe.
Signed-off-by: Alastair D'Silva <alastair@d-silva.org>
Reviewed-by: Frederic Barrat <fbarrat@linux.vnet.ibm.com>
Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'drivers/misc/ocxl/link.c')
0 files changed, 0 insertions, 0 deletions