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] [day] [month] [year] [list]
Message-ID: <YpE9pSVwqzrj+Rso@bombadil.infradead.org>
Date:   Fri, 27 May 2022 14:07:49 -0700
From:   Luis Chamberlain <mcgrof@...nel.org>
To:     mingo@...hat.com, peterz@...radead.org, juri.lelli@...hat.com
Cc:     vincent.guittot@...aro.org, dietmar.eggemann@....com,
        rostedt@...dmis.org, Baisong Zhong <zhongbaisong@...wei.com>,
        kbuild-all@...ts.01.org, bsegall@...gle.com, mgorman@...e.de,
        bristot@...hat.com, linux-kernel@...r.kernel.org
Subject: [PATCH] sched/rt: fix compilation on i386 for umax_rt_runtime

On i386 you can end up with this compilation warning:

kernel/sched/rt.c:9:18: warning: 'max_rt_runtime' defined but not used [-Wunused-const-variable=]

This can happen when SYSCTL or RT_GROUP_SCHED is disabled.
Fix this.

Reported-by: kernel test robot <lkp@...el.com>
Cc: Baisong Zhong <zhongbaisong@...wei.com>
Signed-off-by: Luis Chamberlain <mcgrof@...140507bm04>
---
 kernel/sched/rt.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/kernel/sched/rt.c b/kernel/sched/rt.c
index 8c9ed9664840..eb2a167be098 100644
--- a/kernel/sched/rt.c
+++ b/kernel/sched/rt.c
@@ -5,8 +5,10 @@
  */
 
 int sched_rr_timeslice = RR_TIMESLICE;
+#if defined(CONFIG_SYSCTL) || defined(CONFIG_RT_GROUP_SCHED)
 /* More than 4 hours if BW_SHIFT equals 20. */
 static const u64 max_rt_runtime = MAX_BW;
+#endif
 
 static int do_sched_rt_period_timer(struct rt_bandwidth *rt_b, int overrun);
 
-- 
2.35.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ