Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757443Ab2ECO5k (ORCPT ); Thu, 3 May 2012 10:57:40 -0400 Received: from mail-wi0-f178.google.com ([209.85.212.178]:45494 "EHLO mail-wi0-f178.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757427Ab2ECO5c (ORCPT ); Thu, 3 May 2012 10:57:32 -0400 From: Gilad Ben-Yossef To: linux-kernel@vger.kernel.org Cc: Gilad Ben-Yossef , Thomas Gleixner , Tejun Heo , John Stultz , Andrew Morton , KOSAKI Motohiro , Mel Gorman , Mike Frysinger , David Rientjes , Hugh Dickins , Minchan Kim , Konstantin Khlebnikov , Christoph Lameter , Chris Metcalf , Hakan Akkan , Max Krasnyansky , Frederic Weisbecker , linux-mm@kvack.org Subject: [PATCH v1 6/6] x86: make clocksource watchdog configurable (not for mainline) Date: Thu, 3 May 2012 17:56:02 +0300 Message-Id: <1336056962-10465-7-git-send-email-gilad@benyossef.com> X-Mailer: git-send-email 1.7.0.4 In-Reply-To: <1336056962-10465-1-git-send-email-gilad@benyossef.com> References: <1336056962-10465-1-git-send-email-gilad@benyossef.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2605 Lines: 81 The clock source watchdog wakes up idle cores. Since I'm using KVM to test, where the TSC is always marked unstable, I've added this option to allow to disable it to assist testing. This is not intended for mainlining, the patch just serves as a reference for how I tested the patch set. Signed-off-by: Gilad Ben-Yossef CC: Thomas Gleixner CC: Tejun Heo CC: John Stultz CC: Andrew Morton CC: KOSAKI Motohiro CC: Mel Gorman CC: Mike Frysinger CC: David Rientjes CC: Hugh Dickins CC: Minchan Kim CC: Konstantin Khlebnikov CC: Christoph Lameter CC: Chris Metcalf CC: Hakan Akkan CC: Max Krasnyansky CC: Frederic Weisbecker CC: linux-kernel@vger.kernel.org CC: linux-mm@kvack.org --- arch/x86/Kconfig | 9 ++++++--- kernel/time/clocksource.c | 2 ++ 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig index 1d14cc6..6706c00 100644 --- a/arch/x86/Kconfig +++ b/arch/x86/Kconfig @@ -99,9 +99,6 @@ config ARCH_DEFCONFIG config GENERIC_CMOS_UPDATE def_bool y -config CLOCKSOURCE_WATCHDOG - def_bool y - config GENERIC_CLOCKEVENTS def_bool y @@ -1673,6 +1670,12 @@ config HOTPLUG_CPU automatically on SMP systems. ) Say N if you want to disable CPU hotplug. +config CLOCKSOURCE_WATCHDOG + bool "Clocksource watchdog" + default y + help + Enable clock source watchdog. + config COMPAT_VDSO def_bool y prompt "Compat VDSO support" diff --git a/kernel/time/clocksource.c b/kernel/time/clocksource.c index c958338..1eb5a4e 100644 --- a/kernel/time/clocksource.c +++ b/kernel/time/clocksource.c @@ -450,6 +450,8 @@ static void clocksource_enqueue_watchdog(struct clocksource *cs) static inline void clocksource_dequeue_watchdog(struct clocksource *cs) { } static inline void clocksource_resume_watchdog(void) { } static inline int clocksource_watchdog_kthread(void *data) { return 0; } +void clocksource_mark_unstable(struct clocksource *cs) { } + #endif /* CONFIG_CLOCKSOURCE_WATCHDOG */ -- 1.7.0.4 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/