Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp6654528pxb; Wed, 17 Feb 2021 09:46:42 -0800 (PST) X-Google-Smtp-Source: ABdhPJwN1Y2ONBTP255t3BLpK7fNEs0wqkSvZP1DWHVlNBeS45TJFdk6/AzdTWEto4Xy6nKZQ6I9 X-Received: by 2002:a17:907:da3:: with SMTP id go35mr142250ejc.26.1613584002437; Wed, 17 Feb 2021 09:46:42 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1613584002; cv=none; d=google.com; s=arc-20160816; b=dIuZfPe/gWkXeF/KRkEzOsDOwl3NJGH0ZxvYl2pMWbRV7zH13L9YV8PLGcMmISp76/ wGnFlJ71M74eXT6f+ULFRfFsrcekrgRaSehAsU1OgP+WwaCdlvGmSgDLn9mBBLTDgBsQ 6T5fYBseUdBQy2QnyJO0WKGjNSdpYHH5sxebmga5F6A4XVpNo/H7AsNOhmsTrF4FJ33q GhlKps5Uy/0pPZJ2dRn/jou9mr1PYifl4krHDu9/Z4g5Dcja0rdKA65M2p8jbvgxU64O zF+DQV8KyxNEKFywq9XS3QjHSmy5UHLcVifhOwBbXgxd3VcPC9hNMJvIxAfVEyKCRev7 U+AQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:robot-unsubscribe :robot-id:message-id:mime-version:references:in-reply-to:cc:subject :to:reply-to:sender:from:dkim-signature:dkim-signature:date; bh=qpAC4avhCQfBak38YIGESeWZ1qr62c8rol0Lyq8c7Ec=; b=HJn5PzUS3x2ZX6nY3dxSBv1/7R4wFZVHlEmUcFY+v7R4ehsZ1TH9Nw4ycJdT/0HCDv WOY2wZ0z/pPTEPME4+A07lyaW0SV223LaVEi1+bVUef2jMK54U1CE18iBUoRrxc/SAlX 1v6TXVOqxzRF7W3WEpkZaxhasnvYlwPcbF6iwqwfDCNOvXytqzENEljXXkiQ/fYHKEAt gAYn9ufhRmaZoz1iuU86SJr+OkrMB3s4gNSeJpQf3eck9Kop0c4WsXitpfI9mekVyoCL NoIrzznQYknXy4VKK88tCT/q7r73cKfEK28iPzpPVr249xnGgC0IsyYZ8UMND31Nq/y6 Zmyg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=WT+FUuU5; dkim=neutral (no key) header.i=@linutronix.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id o6si2042150edh.21.2021.02.17.09.46.18; Wed, 17 Feb 2021 09:46:42 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=WT+FUuU5; dkim=neutral (no key) header.i=@linutronix.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229753AbhBQNW7 (ORCPT + 99 others); Wed, 17 Feb 2021 08:22:59 -0500 Received: from Galois.linutronix.de ([193.142.43.55]:45252 "EHLO galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232839AbhBQNSS (ORCPT ); Wed, 17 Feb 2021 08:18:18 -0500 Date: Wed, 17 Feb 2021 13:17:36 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1613567856; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=qpAC4avhCQfBak38YIGESeWZ1qr62c8rol0Lyq8c7Ec=; b=WT+FUuU5niNSlyV4nveaJLrH22u2gknpCp5MMiKmZRC0jwpG8u8V9USBDPP9se7AijBGjd 1GSeNqHAI4Pxzpo9SicuteQFUCBhahrA4vBOXYAUgBhfr+33An8m+HZTdIDI+/NvrWnQX+ O0sBmvyer8Oxdd32EoGqizxlChVNv2XzyZ9xt1pFSMmvRl4PQwjA94PTdAJ3XaqPiTs6vy Msxj+UUZjGuMqTQk+JIUA0HRtZ/8x7fmTDQVQwe/4SMce0EMUGQC5Pwvcx690UVqSom2oH C05/Z8a2E14/6ZV+ehoFGEk9oD3sOh+4zIjUiDCqHEdzJRM7Efsm34E+b5Ohcw== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1613567856; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=qpAC4avhCQfBak38YIGESeWZ1qr62c8rol0Lyq8c7Ec=; b=rdhe5X9rzYq1IWMnuZmygKDGx9GnGeRjT946CRxsvmXAwhzl/uENEoKj4ZjQt/fEsjdwaC EKlQ1P2BQSyv51AA== From: "tip-bot2 for Dietmar Eggemann" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: sched/core] sched/core: Update task_prio() function header Cc: Dietmar Eggemann , "Peter Zijlstra (Intel)" , Ingo Molnar , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20210128131040.296856-4-dietmar.eggemann@arm.com> References: <20210128131040.296856-4-dietmar.eggemann@arm.com> MIME-Version: 1.0 Message-ID: <161356785604.20312.11097939924109968883.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The following commit has been merged into the sched/core branch of tip: Commit-ID: c541bb7835a306cdbbe8abbdf4e4df507e0ca27a Gitweb: https://git.kernel.org/tip/c541bb7835a306cdbbe8abbdf4e4df507e0ca27a Author: Dietmar Eggemann AuthorDate: Thu, 28 Jan 2021 14:10:40 +01:00 Committer: Ingo Molnar CommitterDate: Wed, 17 Feb 2021 14:08:30 +01:00 sched/core: Update task_prio() function header The description of the RT offset and the values for 'normal' tasks needs update. Moreover there are DL tasks now. task_prio() has to stay like it is to guarantee compatibility with the /proc//stat priority field: # cat /proc//stat | awk '{ print $18; }' Signed-off-by: Dietmar Eggemann Signed-off-by: Peter Zijlstra (Intel) Signed-off-by: Ingo Molnar Link: https://lkml.kernel.org/r/20210128131040.296856-4-dietmar.eggemann@arm.com --- kernel/sched/core.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/kernel/sched/core.c b/kernel/sched/core.c index f0b0b67..4afbdd2 100644 --- a/kernel/sched/core.c +++ b/kernel/sched/core.c @@ -5616,8 +5616,12 @@ SYSCALL_DEFINE1(nice, int, increment) * @p: the task in question. * * Return: The priority value as seen by users in /proc. - * RT tasks are offset by -200. Normal tasks are centered - * around 0, value goes from -16 to +15. + * + * sched policy return value kernel prio user prio/nice + * + * normal, batch, idle [0 ... 39] [100 ... 139] 0/[-20 ... 19] + * fifo, rr [-2 ... -100] [98 ... 0] [1 ... 99] + * deadline -101 -1 0 */ int task_prio(const struct task_struct *p) {