From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.linuxfoundation.org ([140.211.169.12]:57610 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752426AbdFOOkI (ORCPT ); Thu, 15 Jun 2017 10:40:08 -0400 Subject: Patch "proc: add a schedule point in proc_pid_readdir()" has been added to the 4.4-stable tree To: edumazet@google.com, akpm@linux-foundation.org, alexander.levin@verizon.com, gregkh@linuxfoundation.org, torvalds@linux-foundation.org Cc: , From: Date: Thu, 15 Jun 2017 16:39:59 +0200 Message-ID: <149753759922635@kroah.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ANSI_X3.4-1968 Content-Transfer-Encoding: 8bit Sender: stable-owner@vger.kernel.org List-ID: This is a note to let you know that I've just added the patch titled proc: add a schedule point in proc_pid_readdir() to the 4.4-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: proc-add-a-schedule-point-in-proc_pid_readdir.patch and it can be found in the queue-4.4 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let know about it. >>From foo@baz Thu Jun 15 16:23:46 CEST 2017 From: Eric Dumazet Date: Tue, 24 Jan 2017 15:18:07 -0800 Subject: proc: add a schedule point in proc_pid_readdir() From: Eric Dumazet [ Upstream commit 3ba4bceef23206349d4130ddf140819b365de7c8 ] We have seen proc_pid_readdir() invocations holding cpu for more than 50 ms. Add a cond_resched() to be gentle with other tasks. [akpm@linux-foundation.org: coding style fix] Link: http://lkml.kernel.org/r/1484238380.15816.42.camel@edumazet-glaptop3.roam.corp.google.com Signed-off-by: Eric Dumazet Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- fs/proc/base.c | 2 ++ 1 file changed, 2 insertions(+) --- a/fs/proc/base.c +++ b/fs/proc/base.c @@ -3058,6 +3058,8 @@ int proc_pid_readdir(struct file *file, iter.tgid += 1, iter = next_tgid(ns, iter)) { char name[PROC_NUMBUF]; int len; + + cond_resched(); if (!has_pid_permissions(ns, iter.task, 2)) continue; Patches currently in stable-queue which might be from edumazet@google.com are queue-4.4/proc-add-a-schedule-point-in-proc_pid_readdir.patch queue-4.4/ipv6-fix-flow-labels-when-the-traffic-class-is-non-0.patch