linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] sched/clock: add dummy clear_sched_clock_stable stub function
@ 2017-01-27 17:38 Paul Gortmaker
  2017-02-01 10:15 ` [tip:sched/core] sched/clock: Add dummy clear_sched_clock_stable() " tip-bot for Paul Gortmaker
  0 siblings, 1 reply; 2+ messages in thread
From: Paul Gortmaker @ 2017-01-27 17:38 UTC (permalink / raw)
  To: linux-kernel; +Cc: Paul Gortmaker, Peter Zijlstra, Ingo Molnar

In commit acb04058de49458010c44bb35b849d45113fd668 ("sched/clock:
Fix hotplug crash") the parisc code gained a call to this function.

However the prototype for it is within HAVE_UNSTABLE_SCHED_CLOCK
ifdef/endif.  That, combined with this:

  arch/parisc/Kconfig:    select HAVE_UNSTABLE_SCHED_CLOCK if SMP

means that parisc can have it either enabled or disabled, resulting
in the following build fail:

arch/parisc/kernel/setup.c:180:2: error: implicit declaration of
function 'clear_sched_clock_stable' [-Werror=implicit-function-declaration]

Add a no-op stub for the non-SMP case to prevent this.

Fixes: acb04058de49 ("sched/clock: Fix hotplug crash")
Cc: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Ingo Molnar <mingo@kernel.org>
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
---
 include/linux/sched.h | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/include/linux/sched.h b/include/linux/sched.h
index 43c4840c0485..c8a257fde056 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -2498,6 +2498,10 @@ static inline void sched_clock_tick(void)
 {
 }
 
+static inline void clear_sched_clock_stable(void)
+{
+}
+
 static inline void sched_clock_idle_sleep_event(void)
 {
 }
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [tip:sched/core] sched/clock: Add dummy clear_sched_clock_stable() stub function
  2017-01-27 17:38 [PATCH] sched/clock: add dummy clear_sched_clock_stable stub function Paul Gortmaker
@ 2017-02-01 10:15 ` tip-bot for Paul Gortmaker
  0 siblings, 0 replies; 2+ messages in thread
From: tip-bot for Paul Gortmaker @ 2017-02-01 10:15 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: linux-kernel, peterz, efault, torvalds, tglx, mingo, hpa, paul.gortmaker

Commit-ID:  733ce725aa4bfa9063be053bfe7f4597d76f0dd1
Gitweb:     http://git.kernel.org/tip/733ce725aa4bfa9063be053bfe7f4597d76f0dd1
Author:     Paul Gortmaker <paul.gortmaker@windriver.com>
AuthorDate: Fri, 27 Jan 2017 12:38:16 -0500
Committer:  Ingo Molnar <mingo@kernel.org>
CommitDate: Wed, 1 Feb 2017 11:01:29 +0100

sched/clock: Add dummy clear_sched_clock_stable() stub function

In commit:

  acb04058de494 ("sched/clock: Fix hotplug crash")

the PARISC code gained a call to this function.

However the prototype for it is within a CONFIG_HAVE_UNSTABLE_SCHED_CLOCK=y
 #ifdef/#endif.  That, combined with this:

  arch/parisc/Kconfig:    select HAVE_UNSTABLE_SCHED_CLOCK if SMP

means that PARISC can have it either enabled or disabled, resulting
in the following build fail:

  arch/parisc/kernel/setup.c:180:2: error: implicit declaration of
  function 'clear_sched_clock_stable' [-Werror=implicit-function-declaration]

Add a no-op stub for the non-SMP case to prevent this.

Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Fixes: acb04058de49 ("sched/clock: Fix hotplug crash")
Link: http://lkml.kernel.org/r/20170127173816.22733-1-paul.gortmaker@windriver.com
Signed-off-by: Ingo Molnar <mingo@kernel.org>
---
 include/linux/sched.h | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/include/linux/sched.h b/include/linux/sched.h
index d176454..e2ed46d 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -2511,6 +2511,10 @@ static inline void sched_clock_tick(void)
 {
 }
 
+static inline void clear_sched_clock_stable(void)
+{
+}
+
 static inline void sched_clock_idle_sleep_event(void)
 {
 }

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-02-01 10:16 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-01-27 17:38 [PATCH] sched/clock: add dummy clear_sched_clock_stable stub function Paul Gortmaker
2017-02-01 10:15 ` [tip:sched/core] sched/clock: Add dummy clear_sched_clock_stable() " tip-bot for Paul Gortmaker

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).