From patchwork Wed Aug 12 01:31:25 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Morton X-Patchwork-Id: 11709921 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id DAE7E109B for ; Wed, 12 Aug 2020 01:31:29 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id A7789206B2 for ; Wed, 12 Aug 2020 01:31:29 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=kernel.org header.i=@kernel.org header.b="m0ZQztRS" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org A7789206B2 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux-foundation.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 858646B0007; Tue, 11 Aug 2020 21:31:28 -0400 (EDT) Delivered-To: linux-mm-outgoing@kvack.org Received: by kanga.kvack.org (Postfix, from userid 40) id 7E2676B002E; Tue, 11 Aug 2020 21:31:28 -0400 (EDT) X-Original-To: int-list-linux-mm@kvack.org X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 6345E6B002F; Tue, 11 Aug 2020 21:31:28 -0400 (EDT) X-Original-To: linux-mm@kvack.org X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0034.hostedemail.com [216.40.44.34]) by kanga.kvack.org (Postfix) with ESMTP id 4A3C56B0007 for ; Tue, 11 Aug 2020 21:31:28 -0400 (EDT) Received: from smtpin12.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id 13442180AD807 for ; Wed, 12 Aug 2020 01:31:28 +0000 (UTC) X-FDA: 77140189056.12.tree15_280eb7326fe7 Received: from filter.hostedemail.com (10.5.16.251.rfc1918.com [10.5.16.251]) by smtpin12.hostedemail.com (Postfix) with ESMTP id D30BC18004A0E for ; Wed, 12 Aug 2020 01:31:27 +0000 (UTC) X-Spam-Summary: 1,0,0,4c85f7e2b101dc45,d41d8cd98f00b204,akpm@linux-foundation.org,,RULES_HIT:41:69:355:379:800:960:967:968:973:988:989:1260:1263:1345:1359:1381:1431:1437:1534:1542:1711:1730:1747:1777:1792:2393:2525:2553:2559:2563:2682:2685:2693:2839:2859:2902:2933:2937:2939:2942:2945:2947:2951:2954:3022:3138:3139:3140:3141:3142:3353:3865:3866:3867:3868:3870:3871:3872:3874:3934:3936:3938:3941:3944:3947:3950:3953:3956:3959:4321:5007:6117:6119:6261:6653:7514:7556:7576:7875:7901:7903:8599:9025:9545:9592:10004:10913:11026:11232:11473:11658:11914:12043:12048:12297:12517:12519:12555:12679:12683:12783:12986:13161:13229:13846:13869:14093:14096:14181:14721:14849:21080:21433:21450:21451:21627:21740:21939:21990:30003:30005:30054:30090,0,RBL:198.145.29.99:@linux-foundation.org:.lbl8.mailshell.net-64.100.201.201 62.2.0.100;04y8371oiwfo1t4machom6poct6pfypqqdkuiqtpqc6yszr4i1o9wprjyicnu96.bmkr9xckxrnhcgunafinfxbin8ugjgtndgw1yssoz6d9x4jd5h43h3pkiiyydgr.n-lbl8.mailshell.net-223.238.255.100,Cach eIP:none X-HE-Tag: tree15_280eb7326fe7 X-Filterd-Recvd-Size: 3519 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by imf34.hostedemail.com (Postfix) with ESMTP for ; Wed, 12 Aug 2020 01:31:27 +0000 (UTC) Received: from localhost.localdomain (c-73-231-172-41.hsd1.ca.comcast.net [73.231.172.41]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 4B35C207DA; Wed, 12 Aug 2020 01:31:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1597195886; bh=/kWyIb8nPbwGblmHcL6U6yO2NXxzfbmR/CRTPBMN9Ew=; h=Date:From:To:Subject:In-Reply-To:From; b=m0ZQztRSyw1IQOwNE9mdyw+HpSwEfCvu3d/3YtX0vSXSTqOExu3fZyfalLlWQy1YU YR+cS7rGgk6WGAFM0NK/hGzPOj2PIi7ckPoWcUvTL7V3TQEi+U500z9BAnd2sRiYmB RF0UgLvLk79CEyqYpnT8pmEjRdglfN6kwGqk+LkM= Date: Tue, 11 Aug 2020 18:31:25 -0700 From: Andrew Morton To: akpm@linux-foundation.org, corbet@lwn.net, laoar.shao@gmail.com, linux-mm@kvack.org, mhocko@suse.com, mm-commits@vger.kernel.org, rientjes@google.com, torvalds@linux-foundation.org Subject: [patch 022/165] doc, mm: sync up oom_score_adj documentation Message-ID: <20200812013125.T4WzqDPNY%akpm@linux-foundation.org> In-Reply-To: <20200811182949.e12ae9a472e3b5e27e16ad6c@linux-foundation.org> User-Agent: s-nail v14.8.16 X-Rspamd-Queue-Id: D30BC18004A0E X-Spamd-Result: default: False [0.00 / 100.00] X-Rspamd-Server: rspam02 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: From: Michal Hocko Subject: doc, mm: sync up oom_score_adj documentation There are at least two notes in the oom section. The 3% discount for root processes is gone since d46078b28889 ("mm, oom: remove 3% bonus for CAP_SYS_ADMIN processes"). Likewise children of the selected oom victim are not sacrificed since bbbe48029720 ("mm, oom: remove 'prefer children over parent' heuristic") Drop both of them. Link: http://lkml.kernel.org/r/20200709062603.18480-1-mhocko@kernel.org Signed-off-by: Michal Hocko Cc: Jonathan Corbet Cc: David Rientjes Cc: Yafang Shao Signed-off-by: Andrew Morton --- Documentation/filesystems/proc.rst | 8 -------- 1 file changed, 8 deletions(-) --- a/Documentation/filesystems/proc.rst~doc-mm-sync-up-oom_score_adj-documentation +++ a/Documentation/filesystems/proc.rst @@ -1633,9 +1633,6 @@ may allocate from based on an estimation For example, if a task is using all allowed memory, its badness score will be 1000. If it is using half of its allowed memory, its score will be 500. -There is an additional factor included in the badness score: the current memory -and swap usage is discounted by 3% for root processes. - The amount of "allowed" memory depends on the context in which the oom killer was called. If it is due to the memory assigned to the allocating task's cpuset being exhausted, the allowed memory represents the set of mems assigned to that @@ -1671,11 +1668,6 @@ The value of /proc//oom_score_adj m value set by a CAP_SYS_RESOURCE process. To reduce the value any lower requires CAP_SYS_RESOURCE. -Caveat: when a parent task is selected, the oom killer will sacrifice any first -generation children with separate address spaces instead, if possible. This -avoids servers and important system daemons from being killed and loses the -minimal amount of work. - 3.2 /proc//oom_score - Display current oom-killer score -------------------------------------------------------------