lkml.org 
[lkml]   [2022]   [Apr]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [RFC 2/3] futex: exit: Print a warning when futex_cleanup fails
From


On 4/21/22 15:30, Matthew Wilcox wrote:
> On Thu, Apr 21, 2022 at 03:05:32PM -0400, Nico Pache wrote:
>> @@ -1007,13 +1013,15 @@ static inline void exit_pi_state_list(struct task_struct *curr) { }
>> static void futex_cleanup(struct task_struct *tsk)
>> {
>> if (unlikely(tsk->robust_list)) {
>> - exit_robust_list(tsk);
>> + if (!exit_robust_list(tsk))
>> + pr_info("futex: exit_robust_list failed");
>
> Doesn't this allow a malicious user process to spam the kernel logs
> with messages? There needs to be a ratelimit on this, at least.
Fair point, we'd need a ratelimited print if we want to continue forward with
this. Additionally we may want to limit this print to debug kernels, but thats
just a thought.

Thanks for the review :)
-- Nico

\
 
 \ /
  Last update: 2022-04-22 16:14    [W:0.075 / U:1.428 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site