From patchwork Thu Jun 2 21:41:34 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Lezcano X-Patchwork-Id: 9151203 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id CD8D960467 for ; Thu, 2 Jun 2016 21:43:42 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C0DB62804C for ; Thu, 2 Jun 2016 21:43:42 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B4C5528330; Thu, 2 Jun 2016 21:43:42 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.1 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED, T_DKIM_INVALID autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 503D22804C for ; Thu, 2 Jun 2016 21:43:42 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1b8aNr-0004hl-UX; Thu, 02 Jun 2016 21:42:31 +0000 Received: from mail-wm0-x22b.google.com ([2a00:1450:400c:c09::22b]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1b8aNo-0004cm-2e for linux-arm-kernel@lists.infradead.org; Thu, 02 Jun 2016 21:42:28 +0000 Received: by mail-wm0-x22b.google.com with SMTP id a136so249280267wme.0 for ; Thu, 02 Jun 2016 14:42:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=IbhOIvJsMMGtt/V9+zcd97fYa9XDLL/Lh7Zgpcs637U=; b=GmBjkXnAPLd6dP3NU1Wc2pUqiT3bNdS7or1wLTh9Qq3a+8xSzYTZxLGw052acIVRFz rHTvHvQNQmJVam1TxXsiNAE9fMFlNd2YjMLSEb6Khm76EnR7pFORTbR+aV/tyNlP+qCp OpaSkFJyWJa+yqZaUsIr7rbP7/yEUAlRAD1DI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=IbhOIvJsMMGtt/V9+zcd97fYa9XDLL/Lh7Zgpcs637U=; b=aQGHuwkrImW5DMBfqWngL3W+m7pm1LzJDYRLucgwiQn8BfKkqOawxNAt/vI1iEs96y OPavIs0P5b2abnmKfBiqomCA9kfqweuqduBmIKVcKi6r7KgeZlA92Yk8jPoWKIzpY4mv y9GIizTvR5VuFsJLhPPAPUNzJ5DEB/NDhe5Y9VMfJ0DQr7uS52xhcs3Cp1jHX979xJ7Y y90T8l5oETYzEyQ5nz/pyzCb08MUxiScMh1rJT8nAlO9s5mogXrFxUan6Z0oLoB9llHN ko/1tbWCYGM8wE1ycM5616odV3q+tmucIWtkGdBM+8DMuCmJnAzPZBAT2umowqC0fe9A zVVA== X-Gm-Message-State: ALyK8tLhlrqmxLp5vTV6rFuRZG71fxVXjvPWFefAbzmCikR5zRZ3QlA2OUxHL1lVls6k4Aco X-Received: by 10.28.85.69 with SMTP id j66mr708148wmb.91.1464903726354; Thu, 02 Jun 2016 14:42:06 -0700 (PDT) Received: from localhost.localdomain (sju31-1-78-210-255-2.fbx.proxad.net. [78.210.255.2]) by smtp.gmail.com with ESMTPSA id c62sm3173705wmd.1.2016.06.02.14.42.05 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 02 Jun 2016 14:42:05 -0700 (PDT) From: Daniel Lezcano To: daniel.lezcano@linaro.org, tglx@linutronix.de Subject: [PATCH 3/6] clocksource/drivers/bcm2835: Add the COMPILE_TEST option Date: Thu, 2 Jun 2016 23:41:34 +0200 Message-Id: <1464903697-3802-3-git-send-email-daniel.lezcano@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1464903697-3802-1-git-send-email-daniel.lezcano@linaro.org> References: <1464903697-3802-1-git-send-email-daniel.lezcano@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20160602_144228_273741_7E5C806D X-CRM114-Status: GOOD ( 14.89 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Florian Fainelli , Russell King , Scott Branden , Ray Jui , linux-kernel@vger.kernel.org, "open list:BROADCOM BCM281XX..." , "moderated list:ARM SUB-ARCHITECT..." MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Change the Kconfig option logic to fullfil with the current approach. A new Kconfig option is added, CONFIG_BCM2835_TIMER and is selected by the platform. Then the clocksource's Kconfig is changed to make this option selectable by the user if the COMPILE_TEST option is set. Otherwise, it is up to the platform's Kconfig to select the timer. Signed-off-by: Daniel Lezcano --- arch/arm/mach-bcm/Kconfig | 1 + drivers/clocksource/Kconfig | 7 +++++++ drivers/clocksource/Makefile | 2 +- 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/arch/arm/mach-bcm/Kconfig b/arch/arm/mach-bcm/Kconfig index 7ef1214..b7414df 100644 --- a/arch/arm/mach-bcm/Kconfig +++ b/arch/arm/mach-bcm/Kconfig @@ -143,6 +143,7 @@ config ARCH_BCM2835 select ARM_TIMER_SP804 select HAVE_ARM_ARCH_TIMER if ARCH_MULTI_V7 select CLKSRC_OF + select BCM2835_TIMER select PINCTRL select PINCTRL_BCM2835 help diff --git a/drivers/clocksource/Kconfig b/drivers/clocksource/Kconfig index 6ff327a..34053ab 100644 --- a/drivers/clocksource/Kconfig +++ b/drivers/clocksource/Kconfig @@ -27,6 +27,13 @@ config CLKBLD_I8253 config CLKSRC_MMIO bool +config BCM2835_TIMER + bool "BCM2835 timer driver" if COMPILE_TEST + depends on GENERIC_CLOCKEVENTS + select CLKSRC_MMIO + help + Enables the support for the BCM2835 timer driver. + config DIGICOLOR_TIMER bool "Digicolor timer driver" if COMPILE_TEST depends on GENERIC_CLOCKEVENTS diff --git a/drivers/clocksource/Makefile b/drivers/clocksource/Makefile index b0a3c96..6e278d4 100644 --- a/drivers/clocksource/Makefile +++ b/drivers/clocksource/Makefile @@ -19,7 +19,7 @@ obj-$(CONFIG_CLKSRC_NOMADIK_MTU) += nomadik-mtu.o obj-$(CONFIG_CLKSRC_DBX500_PRCMU) += clksrc-dbx500-prcmu.o obj-$(CONFIG_ARMADA_370_XP_TIMER) += time-armada-370-xp.o obj-$(CONFIG_ORION_TIMER) += time-orion.o -obj-$(CONFIG_ARCH_BCM2835) += bcm2835_timer.o +obj-$(CONFIG_BCM2835_TIMER) += bcm2835_timer.o obj-$(CONFIG_ARCH_CLPS711X) += clps711x-timer.o obj-$(CONFIG_ARCH_ATLAS7) += timer-atlas7.o obj-$(CONFIG_ARCH_MOXART) += moxart_timer.o