From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephen Warren Subject: [PATCH V3 09/11] ARM: samsung: register syscore_ops for timer resume directly Date: Mon, 19 Nov 2012 11:31:05 -0700 Message-ID: <1353349867-28494-10-git-send-email-swarren@wwwdotorg.org> References: <1353349867-28494-1-git-send-email-swarren@wwwdotorg.org> Return-path: In-Reply-To: <1353349867-28494-1-git-send-email-swarren@wwwdotorg.org> Sender: linux-kernel-owner@vger.kernel.org To: Russell King Cc: Olof Johansson , Arnd Bergmann , John Stultz , Thomas Gleixner , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, Stephen Warren , Ben Dooks , Kukjin Kim List-Id: linux-arch.vger.kernel.org From: Stephen Warren Instead of using struct sys_timer's resume function, register syscore_ops directly in s3c2410_timer_init(). This will allow the sys_timer suspend/ resume fields to be removed, and eventually lead to a complete removal of struct sys_timer. Cc: Ben Dooks Cc: Kukjin Kim Signed-off-by: Stephen Warren --- arch/arm/plat-samsung/time.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/arch/arm/plat-samsung/time.c b/arch/arm/plat-samsung/time.c index 67206df..773745a 100644 --- a/arch/arm/plat-samsung/time.c +++ b/arch/arm/plat-samsung/time.c @@ -27,6 +27,7 @@ #include #include #include +#include #include @@ -271,6 +272,10 @@ static void __init s3c2410_timer_resources(void) clk_enable(tin); } +static struct syscore_ops s3c24xx_syscore_ops = { + .resume = s3c2410_timer_setup, +}; + static void __init s3c2410_timer_init(void) { arch_gettimeoffset = s3c2410_gettimeoffset; @@ -278,9 +283,9 @@ static void __init s3c2410_timer_init(void) s3c2410_timer_resources(); s3c2410_timer_setup(); setup_irq(IRQ_TIMER4, &s3c2410_timer_irq); + register_syscore_ops(&s3c24xx_syscore_ops); } struct sys_timer s3c24xx_timer = { .init = s3c2410_timer_init, - .resume = s3c2410_timer_setup }; -- 1.7.10.4 From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from avon.wwwdotorg.org ([70.85.31.133]:46848 "EHLO avon.wwwdotorg.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754114Ab2KSSbg (ORCPT ); Mon, 19 Nov 2012 13:31:36 -0500 From: Stephen Warren Subject: [PATCH V3 09/11] ARM: samsung: register syscore_ops for timer resume directly Date: Mon, 19 Nov 2012 11:31:05 -0700 Message-ID: <1353349867-28494-10-git-send-email-swarren@wwwdotorg.org> In-Reply-To: <1353349867-28494-1-git-send-email-swarren@wwwdotorg.org> References: <1353349867-28494-1-git-send-email-swarren@wwwdotorg.org> Sender: linux-arch-owner@vger.kernel.org List-ID: To: Russell King Cc: Olof Johansson , Arnd Bergmann , John Stultz , Thomas Gleixner , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, Stephen Warren , Ben Dooks , Kukjin Kim Message-ID: <20121119183105.wifsrq9ZqG9GpLlysUxTN8Ic1dq76UBNTsXRVU4v_Z4@z> From: Stephen Warren Instead of using struct sys_timer's resume function, register syscore_ops directly in s3c2410_timer_init(). This will allow the sys_timer suspend/ resume fields to be removed, and eventually lead to a complete removal of struct sys_timer. Cc: Ben Dooks Cc: Kukjin Kim Signed-off-by: Stephen Warren --- arch/arm/plat-samsung/time.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/arch/arm/plat-samsung/time.c b/arch/arm/plat-samsung/time.c index 67206df..773745a 100644 --- a/arch/arm/plat-samsung/time.c +++ b/arch/arm/plat-samsung/time.c @@ -27,6 +27,7 @@ #include #include #include +#include #include @@ -271,6 +272,10 @@ static void __init s3c2410_timer_resources(void) clk_enable(tin); } +static struct syscore_ops s3c24xx_syscore_ops = { + .resume = s3c2410_timer_setup, +}; + static void __init s3c2410_timer_init(void) { arch_gettimeoffset = s3c2410_gettimeoffset; @@ -278,9 +283,9 @@ static void __init s3c2410_timer_init(void) s3c2410_timer_resources(); s3c2410_timer_setup(); setup_irq(IRQ_TIMER4, &s3c2410_timer_irq); + register_syscore_ops(&s3c24xx_syscore_ops); } struct sys_timer s3c24xx_timer = { .init = s3c2410_timer_init, - .resume = s3c2410_timer_setup }; -- 1.7.10.4