Date: Tue, 9 Jun 2020 14:13:56 +0200
From: Kamil Rytarowski <[email protected]>
Message-ID: <[email protected]>
| Here is the simplest reproducer crashing the kernel on negative pg_jobc:
I have not looked at this closely yet, but this is likely because
ptrace() fiddles p_pptr which the routines that manipulate the pg_jobc
more or less expect to be a constant.
Is there any known reproducer of this problem which does not involve ptrace() ?
At first glance, the manipulations of pg_jobc looks a bit dodgy to me, but I
haven't investigated enough to be able to spot a definite problem yet
(possible ptrace() generated issue aside - and yes, those need to work as
well).
I doubt very much that adding a new mutex will make a difference, all the
manipulations are done with proc_lock held, which is kind of the "big lock"
for process manipulation - adding finer grained locking might improve
performance, by improving concurrency, but is unlikely (at this stage,
nothing is impossible) to be a fix for this problem.
kre