diff mbox

[1/4] SH: cpuidle: remove pointless initialization

Message ID 1366205577-11632-1-git-send-email-daniel.lezcano@linaro.org
State Accepted
Commit 055d752f85f18abb2ad7e2193f61afefe36fd452
Headers show

Commit Message

Daniel Lezcano April 17, 2013, 1:32 p.m. UTC
The driver is a global static variable automatically initialized to zero.

Removing the useless initialization in the init function.

Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
---
 arch/sh/kernel/cpu/shmobile/cpuidle.c |    6 ------
 1 file changed, 6 deletions(-)

Comments

Simon Horman April 18, 2013, 1:18 a.m. UTC | #1
On Wed, Apr 17, 2013 at 03:32:54PM +0200, Daniel Lezcano wrote:
> The driver is a global static variable automatically initialized to zero.
> 
> Removing the useless initialization in the init function.
> 
> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>

Hi Daniel,

All four patches in this series seem reasonable to me.

Acked-by: Simon Horman <horms+renesas@verge.net.au>

Please let me know if I should take them through my renesas tree.

> ---
>  arch/sh/kernel/cpu/shmobile/cpuidle.c |    6 ------
>  1 file changed, 6 deletions(-)
> 
> diff --git a/arch/sh/kernel/cpu/shmobile/cpuidle.c b/arch/sh/kernel/cpu/shmobile/cpuidle.c
> index 0986f21..5b44af9 100644
> --- a/arch/sh/kernel/cpu/shmobile/cpuidle.c
> +++ b/arch/sh/kernel/cpu/shmobile/cpuidle.c
> @@ -64,12 +64,6 @@ void sh_mobile_setup_cpuidle(void)
>  	struct cpuidle_state *state;
>  	int i;
>  
> -
> -	for (i = 0; i < CPUIDLE_STATE_MAX; i++) {
> -		drv->states[i].name[0] = '\0';
> -		drv->states[i].desc[0] = '\0';
> -	}
> -
>  	i = CPUIDLE_DRIVER_STATE_START;
>  
>  	state = &drv->states[i++];
> -- 
> 1.7.9.5
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-sh" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>
Daniel Lezcano April 18, 2013, 9:18 a.m. UTC | #2
On 04/18/2013 03:18 AM, Simon Horman wrote:
> On Wed, Apr 17, 2013 at 03:32:54PM +0200, Daniel Lezcano wrote:
>> The driver is a global static variable automatically initialized to zero.
>>
>> Removing the useless initialization in the init function.
>>
>> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
> 
> Hi Daniel,
> 
> All four patches in this series seem reasonable to me.
> 
> Acked-by: Simon Horman <horms+renesas@verge.net.au>
> 
> Please let me know if I should take them through my renesas tree.

If you are ok with that, is it possible to take them through the
linux-pm tree ? So the cpuidle drivers are synced and I can continue the
code consolidation ?

Thanks for the review.

  -- Daniel

>> --
>> To unsubscribe from this list: send the line "unsubscribe linux-sh" in
>> the body of a message to majordomo@vger.kernel.org
>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>>
Simon Horman April 18, 2013, 1:34 p.m. UTC | #3
On Thu, Apr 18, 2013 at 11:18:04AM +0200, Daniel Lezcano wrote:
> On 04/18/2013 03:18 AM, Simon Horman wrote:
> > On Wed, Apr 17, 2013 at 03:32:54PM +0200, Daniel Lezcano wrote:
> >> The driver is a global static variable automatically initialized to zero.
> >>
> >> Removing the useless initialization in the init function.
> >>
> >> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
> > 
> > Hi Daniel,
> > 
> > All four patches in this series seem reasonable to me.
> > 
> > Acked-by: Simon Horman <horms+renesas@verge.net.au>
> > 
> > Please let me know if I should take them through my renesas tree.
> 
> If you are ok with that, is it possible to take them through the
> linux-pm tree ? So the cpuidle drivers are synced and I can continue the
> code consolidation ?

Yes, I am ok with them going through the linux-pm tree.
Daniel Lezcano April 18, 2013, 1:35 p.m. UTC | #4
On 04/18/2013 03:34 PM, Simon Horman wrote:
> On Thu, Apr 18, 2013 at 11:18:04AM +0200, Daniel Lezcano wrote:
>> On 04/18/2013 03:18 AM, Simon Horman wrote:
>>> On Wed, Apr 17, 2013 at 03:32:54PM +0200, Daniel Lezcano wrote:
>>>> The driver is a global static variable automatically initialized to zero.
>>>>
>>>> Removing the useless initialization in the init function.
>>>>
>>>> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
>>>
>>> Hi Daniel,
>>>
>>> All four patches in this series seem reasonable to me.
>>>
>>> Acked-by: Simon Horman <horms+renesas@verge.net.au>
>>>
>>> Please let me know if I should take them through my renesas tree.
>>
>> If you are ok with that, is it possible to take them through the
>> linux-pm tree ? So the cpuidle drivers are synced and I can continue the
>> code consolidation ?
> 
> Yes, I am ok with them going through the linux-pm tree.

Thanks !
Rafael J. Wysocki April 21, 2013, 11:28 p.m. UTC | #5
On Thursday, April 18, 2013 03:35:49 PM Daniel Lezcano wrote:
> On 04/18/2013 03:34 PM, Simon Horman wrote:
> > On Thu, Apr 18, 2013 at 11:18:04AM +0200, Daniel Lezcano wrote:
> >> On 04/18/2013 03:18 AM, Simon Horman wrote:
> >>> On Wed, Apr 17, 2013 at 03:32:54PM +0200, Daniel Lezcano wrote:
> >>>> The driver is a global static variable automatically initialized to zero.
> >>>>
> >>>> Removing the useless initialization in the init function.
> >>>>
> >>>> Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
> >>>
> >>> Hi Daniel,
> >>>
> >>> All four patches in this series seem reasonable to me.
> >>>
> >>> Acked-by: Simon Horman <horms+renesas@verge.net.au>
> >>>
> >>> Please let me know if I should take them through my renesas tree.
> >>
> >> If you are ok with that, is it possible to take them through the
> >> linux-pm tree ? So the cpuidle drivers are synced and I can continue the
> >> code consolidation ?
> > 
> > Yes, I am ok with them going through the linux-pm tree.
> 
> Thanks !

OK, applied.

Patch [3/4] had a merge conflict against the current Linus' tree, so I've fixed
it up manually.  Please check the linux-next branch for the result (will
probably conflict with the shmobile tree in linux-next, but that's not a big
deal).

Thanks,
Rafael
diff mbox

Patch

diff --git a/arch/sh/kernel/cpu/shmobile/cpuidle.c b/arch/sh/kernel/cpu/shmobile/cpuidle.c
index 0986f21..5b44af9 100644
--- a/arch/sh/kernel/cpu/shmobile/cpuidle.c
+++ b/arch/sh/kernel/cpu/shmobile/cpuidle.c
@@ -64,12 +64,6 @@  void sh_mobile_setup_cpuidle(void)
 	struct cpuidle_state *state;
 	int i;
 
-
-	for (i = 0; i < CPUIDLE_STATE_MAX; i++) {
-		drv->states[i].name[0] = '\0';
-		drv->states[i].desc[0] = '\0';
-	}
-
 	i = CPUIDLE_DRIVER_STATE_START;
 
 	state = &drv->states[i++];