From: Tomasz Figa <tomasz.figa@gmail.com>
To: linux-arm-kernel@lists.infradead.org
Cc: Daniel Lezcano <daniel.lezcano@linaro.org>,
kgene.kim@samsung.com, rjw@sisk.pl, patches@linaro.org,
linaro-kernel@lists.linaro.org, linux-pm@vger.kernel.org
Subject: Re: [PATCH 3/4] ARM: exynos: cpuidle: Move exynos4_idle_driver declaration below in the code
Date: Wed, 24 Jul 2013 10:34:36 +0200 [thread overview]
Message-ID: <1870758.9skEtZxYsB@flatron> (raw)
In-Reply-To: <1374152070-21008-3-git-send-email-daniel.lezcano@linaro.org>
On Thursday 18 of July 2013 14:54:29 Daniel Lezcano wrote:
> In order to prevent a pointless forward declaration, move the driver
> declation after the idle function callback, right before the init
> function.
>
> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
> ---
> arch/arm/mach-exynos/cpuidle.c | 40
> ++++++++++++++++++---------------------- 1 file changed, 18
> insertions(+), 22 deletions(-)
>
> diff --git a/arch/arm/mach-exynos/cpuidle.c
> b/arch/arm/mach-exynos/cpuidle.c index d8fc1a2..8d06128 100644
> --- a/arch/arm/mach-exynos/cpuidle.c
> +++ b/arch/arm/mach-exynos/cpuidle.c
> @@ -37,28 +37,6 @@
>
> #define S5P_CHECK_AFTR 0xFCBA0D10
>
> -static int exynos4_enter_lowpower(struct cpuidle_device *dev,
> - struct cpuidle_driver *drv,
> - int index);
> -
> -static struct cpuidle_driver exynos4_idle_driver = {
> - .name = "exynos4_idle",
> - .owner = THIS_MODULE,
> - .states = {
> - [0] = ARM_CPUIDLE_WFI_STATE,
> - [1] = {
> - .enter = exynos4_enter_lowpower,
> - .exit_latency = 300,
> - .target_residency = 100000,
> - .flags = CPUIDLE_FLAG_TIME_VALID,
> - .name = "C1",
> - .desc = "ARM power down",
> - },
> - },
> - .state_count = 2,
> - .safe_state_index = 0,
> -};
> -
> /* Ext-GIC nIRQ/nFIQ is the only wakeup source in AFTR */
> static void exynos4_set_wakeupmask(void)
> {
> @@ -184,6 +162,24 @@ static void __init exynos5_core_down_clk(void)
> __raw_writel(tmp, EXYNOS5_PWR_CTRL2);
> }
>
> +static struct cpuidle_driver exynos4_idle_driver = {
> + .name = "exynos4_idle",
> + .owner = THIS_MODULE,
> + .states = {
> + [0] = ARM_CPUIDLE_WFI_STATE,
> + [1] = {
> + .enter = exynos4_enter_lowpower,
> + .exit_latency = 300,
> + .target_residency = 100000,
> + .flags = CPUIDLE_FLAG_TIME_VALID,
> + .name = "C1",
> + .desc = "ARM power down",
> + },
> + },
> + .state_count = 2,
> + .safe_state_index = 0,
> +};
> +
> static int __init exynos4_init_cpuidle(void)
> {
> if (soc_is_exynos5250())
Makes sense.
Reviewed-by: Tomasz Figa <t.figa@samsung.com>
Best regards,
Tomasz
WARNING: multiple messages have this Message-ID (diff)
From: tomasz.figa@gmail.com (Tomasz Figa)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 3/4] ARM: exynos: cpuidle: Move exynos4_idle_driver declaration below in the code
Date: Wed, 24 Jul 2013 10:34:36 +0200 [thread overview]
Message-ID: <1870758.9skEtZxYsB@flatron> (raw)
In-Reply-To: <1374152070-21008-3-git-send-email-daniel.lezcano@linaro.org>
On Thursday 18 of July 2013 14:54:29 Daniel Lezcano wrote:
> In order to prevent a pointless forward declaration, move the driver
> declation after the idle function callback, right before the init
> function.
>
> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
> ---
> arch/arm/mach-exynos/cpuidle.c | 40
> ++++++++++++++++++---------------------- 1 file changed, 18
> insertions(+), 22 deletions(-)
>
> diff --git a/arch/arm/mach-exynos/cpuidle.c
> b/arch/arm/mach-exynos/cpuidle.c index d8fc1a2..8d06128 100644
> --- a/arch/arm/mach-exynos/cpuidle.c
> +++ b/arch/arm/mach-exynos/cpuidle.c
> @@ -37,28 +37,6 @@
>
> #define S5P_CHECK_AFTR 0xFCBA0D10
>
> -static int exynos4_enter_lowpower(struct cpuidle_device *dev,
> - struct cpuidle_driver *drv,
> - int index);
> -
> -static struct cpuidle_driver exynos4_idle_driver = {
> - .name = "exynos4_idle",
> - .owner = THIS_MODULE,
> - .states = {
> - [0] = ARM_CPUIDLE_WFI_STATE,
> - [1] = {
> - .enter = exynos4_enter_lowpower,
> - .exit_latency = 300,
> - .target_residency = 100000,
> - .flags = CPUIDLE_FLAG_TIME_VALID,
> - .name = "C1",
> - .desc = "ARM power down",
> - },
> - },
> - .state_count = 2,
> - .safe_state_index = 0,
> -};
> -
> /* Ext-GIC nIRQ/nFIQ is the only wakeup source in AFTR */
> static void exynos4_set_wakeupmask(void)
> {
> @@ -184,6 +162,24 @@ static void __init exynos5_core_down_clk(void)
> __raw_writel(tmp, EXYNOS5_PWR_CTRL2);
> }
>
> +static struct cpuidle_driver exynos4_idle_driver = {
> + .name = "exynos4_idle",
> + .owner = THIS_MODULE,
> + .states = {
> + [0] = ARM_CPUIDLE_WFI_STATE,
> + [1] = {
> + .enter = exynos4_enter_lowpower,
> + .exit_latency = 300,
> + .target_residency = 100000,
> + .flags = CPUIDLE_FLAG_TIME_VALID,
> + .name = "C1",
> + .desc = "ARM power down",
> + },
> + },
> + .state_count = 2,
> + .safe_state_index = 0,
> +};
> +
> static int __init exynos4_init_cpuidle(void)
> {
> if (soc_is_exynos5250())
Makes sense.
Reviewed-by: Tomasz Figa <t.figa@samsung.com>
Best regards,
Tomasz
next prev parent reply other threads:[~2013-07-24 8:34 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-18 12:54 [PATCH 1/4] ARM: exynos: cpuidle: Fallback to WFI, when AFTR is selected Daniel Lezcano
2013-07-18 12:54 ` Daniel Lezcano
2013-07-18 12:54 ` [PATCH 2/4] ARM: exynos: cpuidle: Use the common cpuidle register routine Daniel Lezcano
2013-07-18 12:54 ` Daniel Lezcano
2013-07-19 16:03 ` Bartlomiej Zolnierkiewicz
2013-07-19 16:03 ` Bartlomiej Zolnierkiewicz
2013-07-22 4:36 ` Daniel Lezcano
2013-07-22 4:36 ` Daniel Lezcano
2013-07-22 9:35 ` Bartlomiej Zolnierkiewicz
2013-07-22 9:35 ` Bartlomiej Zolnierkiewicz
2013-07-24 8:36 ` Tomasz Figa
2013-07-24 8:36 ` Tomasz Figa
2013-07-18 12:54 ` [PATCH 3/4] ARM: exynos: cpuidle: Move exynos4_idle_driver declaration below in the code Daniel Lezcano
2013-07-18 12:54 ` Daniel Lezcano
2013-07-24 8:34 ` Tomasz Figa [this message]
2013-07-24 8:34 ` Tomasz Figa
2013-07-18 12:54 ` [PATCH 4/4] ARM: exynos: cpuidle: Remove useless headers Daniel Lezcano
2013-07-18 12:54 ` Daniel Lezcano
2013-07-24 8:35 ` Tomasz Figa
2013-07-24 8:35 ` Tomasz Figa
2013-07-24 8:32 ` [PATCH 1/4] ARM: exynos: cpuidle: Fallback to WFI, when AFTR is selected Tomasz Figa
2013-07-24 8:32 ` Tomasz Figa
2013-07-24 15:16 ` Bartlomiej Zolnierkiewicz
2013-07-24 15:16 ` Bartlomiej Zolnierkiewicz
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1870758.9skEtZxYsB@flatron \
--to=tomasz.figa@gmail.com \
--cc=daniel.lezcano@linaro.org \
--cc=kgene.kim@samsung.com \
--cc=linaro-kernel@lists.linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-pm@vger.kernel.org \
--cc=patches@linaro.org \
--cc=rjw@sisk.pl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.