From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Abraham Subject: Re: [PATCH] ARM: architected timers: allow dt based discovery using clocksource_of_init Date: Mon, 21 Jan 2013 10:30:47 -0800 Message-ID: References: <1358731326-2979-1-git-send-email-thomas.abraham@linaro.org> <50FD7904.1070201@wwwdotorg.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <50FD7904.1070201-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: devicetree-discuss-bounces+gldd-devicetree-discuss=m.gmane.org-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org Sender: "devicetree-discuss" To: Stephen Warren Cc: johnstul-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org, devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org, swarren-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org, rob.herring-bsGFqQB8/DxBDgjK7y7TUQ@public.gmane.org, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org List-Id: devicetree@vger.kernel.org Hi Stephen, On 21 January 2013 09:21, Stephen Warren wrote: > On 01/20/2013 06:22 PM, Thomas Abraham wrote: >> Add an entry in __clksrc_of_table so that ARMv7 architected timer is >> discoverable using call to clocksource_of_init. > >> diff --git a/arch/arm/kernel/arch_timer.c b/arch/arm/kernel/arch_timer.c > >> +#ifdef CONFIG_CLKSRC_OF >> +CLOCKSOURCE_OF_DECLARE(armv7_timer, "arm,armv7-timer", arch_timer_of_register) >> +#endif > > I wonder if we shouldn't enhance include/linux/clocksource.h to define > CLOCKSOURCE_OF_DECLARE even when !CONFIG_CLKSRC_OF; that way, drivers > wouldn't need that ifdef. Yes, it will be helpful to have a !CONFIG_CLKSRC_OF version of CLOCKSOURCE_OF_DECLARE. And can CONFIG_CLKSRC_OF be enabled by default for all ARM platforms? Thanks, Thomas.