diff mbox

ARM:kernel: beautify code, using 'static const' instead of 'const static'

Message ID 513BE8FA.6080304@asianux.com (mailing list archive)
State New, archived
Headers show

Commit Message

Chen Gang March 10, 2013, 1:59 a.m. UTC
better using 'static const' instead of 'const static'

Signed-off-by: Chen Gang <gang.chen@asianux.com>
---
 arch/arm/kernel/smp_twd.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

Comments

Rob Herring March 11, 2013, 1:26 a.m. UTC | #1
On 03/09/2013 07:59 PM, Chen Gang wrote:
> 
>   better using 'static const' instead of 'const static'
> 
> Signed-off-by: Chen Gang <gang.chen@asianux.com>
> ---
>  arch/arm/kernel/smp_twd.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/arch/arm/kernel/smp_twd.c b/arch/arm/kernel/smp_twd.c
> index 3f25650..ef3e499 100644
> --- a/arch/arm/kernel/smp_twd.c
> +++ b/arch/arm/kernel/smp_twd.c
> @@ -362,7 +362,7 @@ int __init twd_local_timer_register(struct twd_local_timer *tlt)
>  }
>  
>  #ifdef CONFIG_OF
> -const static struct of_device_id twd_of_match[] __initconst = {
> +static const struct of_device_id twd_of_match[] __initconst = {

This will go away with conversion to use CLKSRC_OF.

Rob

>  	{ .compatible = "arm,cortex-a9-twd-timer",	},
>  	{ .compatible = "arm,cortex-a5-twd-timer",	},
>  	{ .compatible = "arm,arm11mp-twd-timer",	},
>
Chen Gang March 11, 2013, 5:02 a.m. UTC | #2
? 2013?03?11? 09:26, Rob Herring ??:
> On 03/09/2013 07:59 PM, Chen Gang wrote:
>> > 
>> >   better using 'static const' instead of 'const static'
>> > 
>> > Signed-off-by: Chen Gang <gang.chen@asianux.com>
>> > ---
>> >  arch/arm/kernel/smp_twd.c |    2 +-
>> >  1 files changed, 1 insertions(+), 1 deletions(-)
>> > 
>> > diff --git a/arch/arm/kernel/smp_twd.c b/arch/arm/kernel/smp_twd.c
>> > index 3f25650..ef3e499 100644
>> > --- a/arch/arm/kernel/smp_twd.c
>> > +++ b/arch/arm/kernel/smp_twd.c
>> > @@ -362,7 +362,7 @@ int __init twd_local_timer_register(struct twd_local_timer *tlt)
>> >  }
>> >  
>> >  #ifdef CONFIG_OF
>> > -const static struct of_device_id twd_of_match[] __initconst = {
>> > +static const struct of_device_id twd_of_match[] __initconst = {
> This will go away with conversion to use CLKSRC_OF.

  excuse me, I am not quite familiar with ARM, so I do not quite
understand what you said.

  could you describe it with more details ?
  and how about this patch ?
    a. do not need this patch.
    b. or this patch need improving.
    c. or this patch is ok, can be applied.

  thanks.
diff mbox

Patch

diff --git a/arch/arm/kernel/smp_twd.c b/arch/arm/kernel/smp_twd.c
index 3f25650..ef3e499 100644
--- a/arch/arm/kernel/smp_twd.c
+++ b/arch/arm/kernel/smp_twd.c
@@ -362,7 +362,7 @@  int __init twd_local_timer_register(struct twd_local_timer *tlt)
 }
 
 #ifdef CONFIG_OF
-const static struct of_device_id twd_of_match[] __initconst = {
+static const struct of_device_id twd_of_match[] __initconst = {
 	{ .compatible = "arm,cortex-a9-twd-timer",	},
 	{ .compatible = "arm,cortex-a5-twd-timer",	},
 	{ .compatible = "arm,arm11mp-twd-timer",	},