diff mbox

ARM: gic: Fix sparse warning

Message ID 1353322736-2747-1-git-send-email-tushar.behera@linaro.org (mailing list archive)
State New, archived
Headers show

Commit Message

Tushar Behera Nov. 19, 2012, 10:58 a.m. UTC
gic_irq_domain_ops is only used in this file, so should be marked as
static.

Fixes following compilation warning.

arch/arm/common/gic.c:638:29: warning: symbol 'gic_irq_domain_ops' was
not declared. Should it be static?

Signed-off-by: Tushar Behera <tushar.behera@linaro.org>
---
 arch/arm/common/gic.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

Comments

Sergei Shtylyov Nov. 19, 2012, 12:42 p.m. UTC | #1
Hello.

On 19-11-2012 14:58, Tushar Behera wrote:

> gic_irq_domain_ops is only used in this file, so should be marked as
> static.

> Fixes following compilation warning.

   This is sparse's warning, not compiler's, if I don't mistake.

> arch/arm/common/gic.c:638:29: warning: symbol 'gic_irq_domain_ops' was
> not declared. Should it be static?

> Signed-off-by: Tushar Behera <tushar.behera@linaro.org>

WBR, Sergei
Tushar Behera Nov. 20, 2012, 3:26 a.m. UTC | #2
On 11/19/2012 06:12 PM, Sergei Shtylyov wrote:
> Hello.
> 
> On 19-11-2012 14:58, Tushar Behera wrote:
> 
>> gic_irq_domain_ops is only used in this file, so should be marked as
>> static.
> 
>> Fixes following compilation warning.
> 
>   This is sparse's warning, not compiler's, if I don't mistake.
> 

My mistake. It is indeed sparse warning.

>> arch/arm/common/gic.c:638:29: warning: symbol 'gic_irq_domain_ops' was
>> not declared. Should it be static?
> 
>> Signed-off-by: Tushar Behera <tushar.behera@linaro.org>
> 
> WBR, Sergei
> 
>
Sergei Shtylyov Nov. 20, 2012, 1 p.m. UTC | #3
On 20-11-2012 7:26, Tushar Behera wrote:

>>> gic_irq_domain_ops is only used in this file, so should be marked as
>>> static.

>>> Fixes following compilation warning.

>>    This is sparse's warning, not compiler's, if I don't mistake.

> My mistake. It is indeed sparse warning.

    And I didn't read your subject, where it's called correctly. :-)

>>> arch/arm/common/gic.c:638:29: warning: symbol 'gic_irq_domain_ops' was
>>> not declared. Should it be static?

>>> Signed-off-by: Tushar Behera <tushar.behera@linaro.org>

WBR, Sergei
diff mbox

Patch

diff --git a/arch/arm/common/gic.c b/arch/arm/common/gic.c
index aa52699..4896dec 100644
--- a/arch/arm/common/gic.c
+++ b/arch/arm/common/gic.c
@@ -635,7 +635,7 @@  static int gic_irq_domain_xlate(struct irq_domain *d,
 	return 0;
 }
 
-const struct irq_domain_ops gic_irq_domain_ops = {
+static const struct irq_domain_ops gic_irq_domain_ops = {
 	.map = gic_irq_domain_map,
 	.xlate = gic_irq_domain_xlate,
 };