* [PATCH] cpufreq: remove the unnecessary initialization of a local variable
@ 2012-10-31 5:49 Jingoo Han
2012-11-02 12:54 ` Rafael J. Wysocki
0 siblings, 1 reply; 2+ messages in thread
From: Jingoo Han @ 2012-10-31 5:49 UTC (permalink / raw)
To: 'Rafael J. Wysocki'
Cc: cpufreq, linux-pm, linux-kernel, 'Jingoo Han'
This patch removes unnecessary initializer for the 'ret' variable.
Signed-off-by: Jingoo Han <jg1.han@samsung.com>
---
drivers/cpufreq/cpufreq.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c
index 261ef65..4e9fcc5 100644
--- a/drivers/cpufreq/cpufreq.c
+++ b/drivers/cpufreq/cpufreq.c
@@ -404,7 +404,7 @@ static int __cpufreq_set_policy(struct cpufreq_policy *data,
static ssize_t store_##file_name \
(struct cpufreq_policy *policy, const char *buf, size_t count) \
{ \
- unsigned int ret = -EINVAL; \
+ unsigned int ret; \
struct cpufreq_policy new_policy; \
\
ret = cpufreq_get_policy(&new_policy, policy->cpu); \
@@ -459,7 +459,7 @@ static ssize_t show_scaling_governor(struct cpufreq_policy *policy, char *buf)
static ssize_t store_scaling_governor(struct cpufreq_policy *policy,
const char *buf, size_t count)
{
- unsigned int ret = -EINVAL;
+ unsigned int ret;
char str_governor[16];
struct cpufreq_policy new_policy;
--
1.7.1
^ permalink raw reply related [flat|nested] 2+ messages in thread* Re: [PATCH] cpufreq: remove the unnecessary initialization of a local variable
2012-10-31 5:49 [PATCH] cpufreq: remove the unnecessary initialization of a local variable Jingoo Han
@ 2012-11-02 12:54 ` Rafael J. Wysocki
0 siblings, 0 replies; 2+ messages in thread
From: Rafael J. Wysocki @ 2012-11-02 12:54 UTC (permalink / raw)
To: Jingoo Han; +Cc: 'Rafael J. Wysocki', cpufreq, linux-pm, linux-kernel
On Wednesday, October 31, 2012 02:49:13 PM Jingoo Han wrote:
> This patch removes unnecessary initializer for the 'ret' variable.
Applied to the linux-next branch of the linux-pm.git tree as v3.8 material.
Thanks,
Rafael
> Signed-off-by: Jingoo Han <jg1.han@samsung.com>
> ---
> drivers/cpufreq/cpufreq.c | 4 ++--
> 1 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c
> index 261ef65..4e9fcc5 100644
> --- a/drivers/cpufreq/cpufreq.c
> +++ b/drivers/cpufreq/cpufreq.c
> @@ -404,7 +404,7 @@ static int __cpufreq_set_policy(struct cpufreq_policy *data,
> static ssize_t store_##file_name \
> (struct cpufreq_policy *policy, const char *buf, size_t count) \
> { \
> - unsigned int ret = -EINVAL; \
> + unsigned int ret; \
> struct cpufreq_policy new_policy; \
> \
> ret = cpufreq_get_policy(&new_policy, policy->cpu); \
> @@ -459,7 +459,7 @@ static ssize_t show_scaling_governor(struct cpufreq_policy *policy, char *buf)
> static ssize_t store_scaling_governor(struct cpufreq_policy *policy,
> const char *buf, size_t count)
> {
> - unsigned int ret = -EINVAL;
> + unsigned int ret;
> char str_governor[16];
> struct cpufreq_policy new_policy;
>
>
--
I speak only for myself.
Rafael J. Wysocki, Intel Open Source Technology Center.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2012-11-02 12:49 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-10-31 5:49 [PATCH] cpufreq: remove the unnecessary initialization of a local variable Jingoo Han
2012-11-02 12:54 ` Rafael J. Wysocki
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox