lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 21 Feb 2014 13:33:20 -0800
From:	tip-bot for Dongsheng Yang <tipbot@...or.com>
To:	linux-tip-commits@...r.kernel.org
Cc:	linux-kernel@...r.kernel.org, hpa@...or.com, mingo@...nel.org,
	peterz@...radead.org, tglx@...utronix.de,
	yangds.fnst@...fujitsu.com
Subject: [tip:sched/core] sched: prio:
  Use NICE_WIDTH macro to avoid using of hard coding of 40 and 20 in prio.h.

Commit-ID:  eb2ae7dad9dad350b4444962465d7e09bcfc128a
Gitweb:     http://git.kernel.org/tip/eb2ae7dad9dad350b4444962465d7e09bcfc128a
Author:     Dongsheng Yang <yangds.fnst@...fujitsu.com>
AuthorDate: Tue, 11 Feb 2014 15:34:47 +0800
Committer:  Thomas Gleixner <tglx@...utronix.de>
CommitDate: Fri, 21 Feb 2014 21:43:20 +0100

sched: prio: Use NICE_WIDTH macro to avoid using of hard coding of 40 and 20 in prio.h.

cc: Ingo Molnar <mingo@...nel.org>
cc: Peter Zijlstra <peterz@...radead.org>
Cc: Ingo Molnar <mingo@...nel.org>
Signed-off-by: Dongsheng Yang <yangds.fnst@...fujitsu.com>
Signed-off-by: Peter Zijlstra <peterz@...radead.org>
Link: http://lkml.kernel.org/r/72dc351df816a975e30b6320754fb52823d2aa3f.1392103744.git.yangds.fnst@cn.fujitsu.com
Signed-off-by: Thomas Gleixner <tglx@...utronix.de>
---
 include/linux/sched/prio.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/include/linux/sched/prio.h b/include/linux/sched/prio.h
index c6974c4..ac32258 100644
--- a/include/linux/sched/prio.h
+++ b/include/linux/sched/prio.h
@@ -21,8 +21,8 @@
 #define MAX_USER_RT_PRIO	100
 #define MAX_RT_PRIO		MAX_USER_RT_PRIO
 
-#define MAX_PRIO		(MAX_RT_PRIO + 40)
-#define DEFAULT_PRIO		(MAX_RT_PRIO + 20)
+#define MAX_PRIO		(MAX_RT_PRIO + NICE_WIDTH)
+#define DEFAULT_PRIO		(MAX_RT_PRIO + NICE_WIDTH / 2)
 
 /*
  * Convert user-nice values [ -20 ... 0 ... 19 ]
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ