devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] clocksource: always define CLOCKSOURCE_OF_DECLARE
@ 2013-01-30 17:49 Stephen Warren
       [not found] ` <1359568170-26479-1-git-send-email-swarren-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org>
  0 siblings, 1 reply; 2+ messages in thread
From: Stephen Warren @ 2013-01-30 17:49 UTC (permalink / raw)
  To: arm
  Cc: Mark Rutland, kgene.kim, Stephen Warren, johnstul,
	devicetree-discuss, rob.herring, Thomas Abraham, tglx, chaos.youn,
	sylvester.nawrocki, linux-arm-kernel

From: Stephen Warren <swarren@nvidia.com>

This allows clocksource drivers that support both DT and non-DT to
always invoke macro CLOCKSOURCE_OF_DECLARE(), rather than wrapping
it in a #ifdef CONFIG_CLKSRC_OF, which simplifies their code.

Signed-off-by: Stephen Warren <swarren@nvidia.com>
---
Olof, Arnd, this is based on arm-soc's timer/cleanup branch, which is
probably the best place for this patch.

 include/linux/clocksource.h |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/include/linux/clocksource.h b/include/linux/clocksource.h
index 7944f14..27cfda4 100644
--- a/include/linux/clocksource.h
+++ b/include/linux/clocksource.h
@@ -339,6 +339,8 @@ extern void clocksource_of_init(void);
 	static const struct of_device_id __clksrc_of_table_##name	\
 		__used __section(__clksrc_of_table)			\
 		 = { .compatible = compat, .data = fn };
+#else
+#define CLOCKSOURCE_OF_DECLARE(name, compat, fn)
 #endif
 
 #endif /* _LINUX_CLOCKSOURCE_H */
-- 
1.7.10.4

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

* Re: [PATCH] clocksource: always define CLOCKSOURCE_OF_DECLARE
       [not found] ` <1359568170-26479-1-git-send-email-swarren-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org>
@ 2013-02-01  3:57   ` Olof Johansson
  0 siblings, 0 replies; 2+ messages in thread
From: Olof Johansson @ 2013-02-01  3:57 UTC (permalink / raw)
  To: Stephen Warren
  Cc: kgene.kim-Sze3O3UU22JBDgjK7y7TUQ, Stephen Warren,
	johnstul-r/Jw6+rmf7HQT0dZR+AlfA,
	devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ,
	rob.herring-bsGFqQB8/DxBDgjK7y7TUQ, arm-DgEjT+Ai2ygdnm+yROfE0A,
	tglx-hfZtesqFncYOwBW4kG4KsQ, chaos.youn-Sze3O3UU22JBDgjK7y7TUQ,
	sylvester.nawrocki-Re5JQEeQqe8AvxtiuMwx3w,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

On Wed, Jan 30, 2013 at 10:49:30AM -0700, Stephen Warren wrote:
> From: Stephen Warren <swarren-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
> 
> This allows clocksource drivers that support both DT and non-DT to
> always invoke macro CLOCKSOURCE_OF_DECLARE(), rather than wrapping
> it in a #ifdef CONFIG_CLKSRC_OF, which simplifies their code.
> 
> Signed-off-by: Stephen Warren <swarren-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
> ---
> Olof, Arnd, this is based on arm-soc's timer/cleanup branch, which is
> probably the best place for this patch.

Applied (to next/cleanup).


-Olof

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

end of thread, other threads:[~2013-02-01  3:57 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-01-30 17:49 [PATCH] clocksource: always define CLOCKSOURCE_OF_DECLARE Stephen Warren
     [not found] ` <1359568170-26479-1-git-send-email-swarren-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org>
2013-02-01  3:57   ` Olof Johansson

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).