Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751246AbdFANv0 (ORCPT ); Thu, 1 Jun 2017 09:51:26 -0400 Received: from out03.mta.xmission.com ([166.70.13.233]:57866 "EHLO out03.mta.xmission.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751122AbdFANvX (ORCPT ); Thu, 1 Jun 2017 09:51:23 -0400 From: ebiederm@xmission.com (Eric W. Biederman) To: Ben Hutchings Cc: linux-kernel@vger.kernel.org, stable@vger.kernel.org, Vovo Yang , Guenter Roeck , Greg Kroah-Hartman References: <20170523200856.903752266@linuxfoundation.org> <20170523200900.480278614@linuxfoundation.org> <1496318134.2790.18.camel@codethink.co.uk> Date: Thu, 01 Jun 2017 08:44:34 -0500 In-Reply-To: <1496318134.2790.18.camel@codethink.co.uk> (Ben Hutchings's message of "Thu, 01 Jun 2017 12:55:34 +0100") Message-ID: <87vaofesal.fsf@xmission.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-XM-SPF: eid=1dGQVQ-0003KN-0H;;;mid=<87vaofesal.fsf@xmission.com>;;;hst=in02.mta.xmission.com;;;ip=97.121.81.159;;;frm=ebiederm@xmission.com;;;spf=neutral X-XM-AID: U2FsdGVkX188ZCICKFw5dDOrA1oV5A41Fa+xSLa4GzI= X-SA-Exim-Connect-IP: 97.121.81.159 X-SA-Exim-Mail-From: ebiederm@xmission.com X-Spam-Report: * -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP * 0.0 TVD_RCVD_IP Message was received from an IP address * 0.7 XMSubLong Long Subject * 1.5 XMNoVowels Alpha-numberic number with no vowels * 0.5 XMGappySubj_01 Very gappy subject * 0.0 T_TM2_M_HEADER_IN_MSG BODY: No description available. * -0.5 BAYES_05 BODY: Bayes spam probability is 1 to 5% * [score: 0.0404] * -0.0 DCC_CHECK_NEGATIVE Not listed in DCC * [sa06 1397; Body=1 Fuz1=1 Fuz2=1] * 0.0 T_TooManySym_01 4+ unique symbols in subject * 0.0 T_TooManySym_02 5+ unique symbols in subject X-Spam-DCC: XMission; sa06 1397; Body=1 Fuz1=1 Fuz2=1 X-Spam-Combo: *;Ben Hutchings X-Spam-Relay-Country: X-Spam-Timing: total 5680 ms - load_scoreonly_sql: 0.03 (0.0%), signal_user_changed: 2.3 (0.0%), b_tie_ro: 1.55 (0.0%), parse: 0.71 (0.0%), extract_message_metadata: 13 (0.2%), get_uri_detail_list: 1.04 (0.0%), tests_pri_-1000: 6 (0.1%), tests_pri_-950: 1.17 (0.0%), tests_pri_-900: 0.95 (0.0%), tests_pri_-400: 17 (0.3%), check_bayes: 16 (0.3%), b_tokenize: 4.9 (0.1%), b_tok_get_all: 6 (0.1%), b_comp_prob: 1.69 (0.0%), b_tok_touch_all: 2.1 (0.0%), b_finish: 0.55 (0.0%), tests_pri_0: 134 (2.4%), check_dkim_signature: 0.44 (0.0%), check_dkim_adsp: 2.7 (0.0%), tests_pri_500: 5502 (96.9%), poll_dns_idle: 5495 (96.8%), rewrite_mail: 0.00 (0.0%) Subject: Re: [PATCH 4.4 040/103] pid_ns: Sleep in TASK_INTERRUPTIBLE in zap_pid_ns_processes X-Spam-Flag: No X-SA-Exim-Version: 4.2.1 (built Thu, 05 May 2016 13:38:54 -0600) X-SA-Exim-Scanned: Yes (on in02.mta.xmission.com) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1271 Lines: 34 Ben Hutchings writes: > On Tue, 2017-05-23 at 22:09 +0200, Greg Kroah-Hartman wrote: >> 4.4-stable review patch. If anyone has any objections, please let me know. >> >> ------------------ >> >> From: Eric W. Biederman >> >> commit b9a985db98961ae1ba0be169f19df1c567e4ffe0 upstream. >> >> The code can potentially sleep for an indefinite amount of time in >> zap_pid_ns_processes triggering the hung task timeout, and increasing >> the system average. This is undesirable. Sleep with a task state of >> TASK_INTERRUPTIBLE instead of TASK_UNINTERRUPTIBLE to remove these >> undesirable side effects. > [...] > > This seems to rely on the task not actually being signallable due to the > PF_EXITING flag. Using TASK_IDLE would be clearer (though less > backport-able). Point taken. And imporatantly TASK_IDLE also avoids the hung_task check. Right now backporting and well understood simplicity is the primary goal. I have a patch in the queue for 4.13 that will remove this wait all together, and just not allow reaping the zombie until the appropriate conditions are met. That seems to be the better long term approach, as it avoids blocking in such a weird way in a weird location all together. Eric