linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ARM: need to include asm/system.h in asm/processor.h
@ 2012-02-15 19:20 Olof Johansson
  2012-02-15 19:59 ` David Brown
  0 siblings, 1 reply; 4+ messages in thread
From: Olof Johansson @ 2012-02-15 19:20 UTC (permalink / raw)
  To: linux-arm-kernel

For files that include asm/processor.h but not asm/system.h:

arch/arm/mach-msm/include/mach/uncompress.h: In function 'putc':
arch/arm/mach-msm/include/mach/uncompress.h:48:3: error: implicit declaration of function 'smp_mb' [-Werror=implicit-function-declaration]

In this case, smp_mb() is from the cpu_relax() call in the msm putc().

It likely went uncaught when the uncompress.h change went in since the
defconfig didn't enable that code path, but later changes (e76f4750f4:
ARM: debug: arrange Kconfig options more logically) resulted in the
option being on for msm_defconfig and thus exposed it.

Signed-off-by: Olof Johansson <olof@lixom.net>
---
 arch/arm/include/asm/processor.h |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/arch/arm/include/asm/processor.h b/arch/arm/include/asm/processor.h
index d7038fa..d27b071 100644
--- a/arch/arm/include/asm/processor.h
+++ b/arch/arm/include/asm/processor.h
@@ -22,6 +22,7 @@
 #include <asm/hw_breakpoint.h>
 #include <asm/ptrace.h>
 #include <asm/types.h>
+#include <asm/system.h>
 
 #ifdef __KERNEL__
 #define STACK_TOP	((current->personality & ADDR_LIMIT_32BIT) ? \
-- 
1.7.9.209.gb6b3b

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH] ARM: need to include asm/system.h in asm/processor.h
  2012-02-15 19:20 [PATCH] ARM: need to include asm/system.h in asm/processor.h Olof Johansson
@ 2012-02-15 19:59 ` David Brown
  2012-02-15 20:06   ` Rob Herring
  0 siblings, 1 reply; 4+ messages in thread
From: David Brown @ 2012-02-15 19:59 UTC (permalink / raw)
  To: linux-arm-kernel

On Wed, Feb 15, 2012 at 11:20:10AM -0800, Olof Johansson wrote:
> For files that include asm/processor.h but not asm/system.h:
> 
> arch/arm/mach-msm/include/mach/uncompress.h: In function 'putc':
> arch/arm/mach-msm/include/mach/uncompress.h:48:3: error: implicit declaration of function 'smp_mb' [-Werror=implicit-function-declaration]
> 
> In this case, smp_mb() is from the cpu_relax() call in the msm putc().
> 
> It likely went uncaught when the uncompress.h change went in since the
> defconfig didn't enable that code path, but later changes (e76f4750f4:
> ARM: debug: arrange Kconfig options more logically) resulted in the
> option being on for msm_defconfig and thus exposed it.
> 
> Signed-off-by: Olof Johansson <olof@lixom.net>

BTW, Rob Herring has this same patch in his io.h cleanup patches, so
it's probably best to coordinate with him.

Author: Rob Herring <rob.herring@calxeda.com>
Date:   Mon Feb 13 15:43:15 2012 -0600

    ARM: add explicit include of system.h to processor.h
    
    cpu_relax in processor.h needs smp_mb which is defined in
    system.h.
    
    Signed-off-by: Rob Herring <rob.herring@calxeda.com>

David

-- 
Sent by an employee of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH] ARM: need to include asm/system.h in asm/processor.h
  2012-02-15 19:59 ` David Brown
@ 2012-02-15 20:06   ` Rob Herring
  2012-02-15 20:12     ` Olof Johansson
  0 siblings, 1 reply; 4+ messages in thread
From: Rob Herring @ 2012-02-15 20:06 UTC (permalink / raw)
  To: linux-arm-kernel

On 02/15/2012 01:59 PM, David Brown wrote:
> On Wed, Feb 15, 2012 at 11:20:10AM -0800, Olof Johansson wrote:
>> For files that include asm/processor.h but not asm/system.h:
>>
>> arch/arm/mach-msm/include/mach/uncompress.h: In function 'putc':
>> arch/arm/mach-msm/include/mach/uncompress.h:48:3: error: implicit declaration of function 'smp_mb' [-Werror=implicit-function-declaration]
>>
>> In this case, smp_mb() is from the cpu_relax() call in the msm putc().
>>
>> It likely went uncaught when the uncompress.h change went in since the
>> defconfig didn't enable that code path, but later changes (e76f4750f4:
>> ARM: debug: arrange Kconfig options more logically) resulted in the
>> option being on for msm_defconfig and thus exposed it.
>>
>> Signed-off-by: Olof Johansson <olof@lixom.net>
> 
> BTW, Rob Herring has this same patch in his io.h cleanup patches, so
> it's probably best to coordinate with him.

I'd just assumed that I had broken things by implicitly dropping a lot
of includes when removing mach/io.h. Go ahead and apply yours and I'll
drop mine.

Rob


> Author: Rob Herring <rob.herring@calxeda.com>
> Date:   Mon Feb 13 15:43:15 2012 -0600
> 
>     ARM: add explicit include of system.h to processor.h
>     
>     cpu_relax in processor.h needs smp_mb which is defined in
>     system.h.
>     
>     Signed-off-by: Rob Herring <rob.herring@calxeda.com>
> 
> David
> 

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH] ARM: need to include asm/system.h in asm/processor.h
  2012-02-15 20:06   ` Rob Herring
@ 2012-02-15 20:12     ` Olof Johansson
  0 siblings, 0 replies; 4+ messages in thread
From: Olof Johansson @ 2012-02-15 20:12 UTC (permalink / raw)
  To: linux-arm-kernel

On Wed, Feb 15, 2012 at 12:06 PM, Rob Herring <robherring2@gmail.com> wrote:
> On 02/15/2012 01:59 PM, David Brown wrote:
>> On Wed, Feb 15, 2012 at 11:20:10AM -0800, Olof Johansson wrote:
>>> For files that include asm/processor.h but not asm/system.h:
>>>
>>> arch/arm/mach-msm/include/mach/uncompress.h: In function 'putc':
>>> arch/arm/mach-msm/include/mach/uncompress.h:48:3: error: implicit declaration of function 'smp_mb' [-Werror=implicit-function-declaration]
>>>
>>> In this case, smp_mb() is from the cpu_relax() call in the msm putc().
>>>
>>> It likely went uncaught when the uncompress.h change went in since the
>>> defconfig didn't enable that code path, but later changes (e76f4750f4:
>>> ARM: debug: arrange Kconfig options more logically) resulted in the
>>> option being on for msm_defconfig and thus exposed it.
>>>
>>> Signed-off-by: Olof Johansson <olof@lixom.net>
>>
>> BTW, Rob Herring has this same patch in his io.h cleanup patches, so
>> it's probably best to coordinate with him.
>
> I'd just assumed that I had broken things by implicitly dropping a lot
> of includes when removing mach/io.h. Go ahead and apply yours and I'll
> drop mine.

Cool, I had missed that -- sorry for the duplicate patches.

I'll forward mine now to Russell's patch tracker and he can pick it up there.


-Olof

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2012-02-15 20:12 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-15 19:20 [PATCH] ARM: need to include asm/system.h in asm/processor.h Olof Johansson
2012-02-15 19:59 ` David Brown
2012-02-15 20:06   ` Rob Herring
2012-02-15 20:12     ` Olof Johansson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).