All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ARM: s3c64xx: fix pm-debug compilation
@ 2015-12-18 14:46 ` Arnd Bergmann
  0 siblings, 0 replies; 6+ messages in thread
From: Arnd Bergmann @ 2015-12-18 14:46 UTC (permalink / raw)
  To: Kukjin Kim, Krzysztof Kozlowski; +Cc: linux-arm-kernel, linux-samsung-soc

I got one randconfig build that failed to compile plat-samsung/pm-debug.c
on s3c64xx:

In file included from arch/arm/plat-samsung/pm-debug.c:27:0:
arch/arm/mach-s3c64xx/include/mach/pm-core.h: In function 's3c_pm_debug_init_uart':
arch/arm/mach-s3c64xx/include/mach/pm-core.h:25:25: error: 'S3C_VA_SYS' undeclared (first use in this function)
  u32 tmp = __raw_readl(S3C_PCLK_GATE);
arch/arm/mach-s3c64xx/include/mach/pm-core.h:25:25: note: each undeclared identifier is reported only once for each function it appears in
arch/arm/mach-s3c64xx/include/mach/pm-core.h:39:2: error: implicit declaration of function 'udelay' [-Werror=implicit-function-declaration]
  udelay(10);

I have not investigated why this does not show up much more often, I
guess the headers are usually included from elsewhere, but adding
explicit #include statements is an obvious fix.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
I suspect this has been broken for a long time, so no rush, but please
apply this to a cleanup branch.

diff --git a/arch/arm/mach-s3c64xx/include/mach/pm-core.h b/arch/arm/mach-s3c64xx/include/mach/pm-core.h
index 5be8fe368e54..4a285e97afff 100644
--- a/arch/arm/mach-s3c64xx/include/mach/pm-core.h
+++ b/arch/arm/mach-s3c64xx/include/mach/pm-core.h
@@ -16,9 +16,11 @@
 #define __MACH_S3C64XX_PM_CORE_H __FILE__
 
 #include <linux/serial_s3c.h>
+#include <linux/delay.h>
 
 #include <mach/regs-gpio.h>
 #include <mach/regs-clock.h>
+#include <mach/map.h>
 
 static inline void s3c_pm_debug_init_uart(void)
 {

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

* [PATCH] ARM: s3c64xx: fix pm-debug compilation
@ 2015-12-18 14:46 ` Arnd Bergmann
  0 siblings, 0 replies; 6+ messages in thread
From: Arnd Bergmann @ 2015-12-18 14:46 UTC (permalink / raw)
  To: linux-arm-kernel

I got one randconfig build that failed to compile plat-samsung/pm-debug.c
on s3c64xx:

In file included from arch/arm/plat-samsung/pm-debug.c:27:0:
arch/arm/mach-s3c64xx/include/mach/pm-core.h: In function 's3c_pm_debug_init_uart':
arch/arm/mach-s3c64xx/include/mach/pm-core.h:25:25: error: 'S3C_VA_SYS' undeclared (first use in this function)
  u32 tmp = __raw_readl(S3C_PCLK_GATE);
arch/arm/mach-s3c64xx/include/mach/pm-core.h:25:25: note: each undeclared identifier is reported only once for each function it appears in
arch/arm/mach-s3c64xx/include/mach/pm-core.h:39:2: error: implicit declaration of function 'udelay' [-Werror=implicit-function-declaration]
  udelay(10);

I have not investigated why this does not show up much more often, I
guess the headers are usually included from elsewhere, but adding
explicit #include statements is an obvious fix.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
I suspect this has been broken for a long time, so no rush, but please
apply this to a cleanup branch.

diff --git a/arch/arm/mach-s3c64xx/include/mach/pm-core.h b/arch/arm/mach-s3c64xx/include/mach/pm-core.h
index 5be8fe368e54..4a285e97afff 100644
--- a/arch/arm/mach-s3c64xx/include/mach/pm-core.h
+++ b/arch/arm/mach-s3c64xx/include/mach/pm-core.h
@@ -16,9 +16,11 @@
 #define __MACH_S3C64XX_PM_CORE_H __FILE__
 
 #include <linux/serial_s3c.h>
+#include <linux/delay.h>
 
 #include <mach/regs-gpio.h>
 #include <mach/regs-clock.h>
+#include <mach/map.h>
 
 static inline void s3c_pm_debug_init_uart(void)
 {

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

* Re: [PATCH] ARM: s3c64xx: fix pm-debug compilation
  2015-12-18 14:46 ` Arnd Bergmann
@ 2015-12-28  1:54   ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 6+ messages in thread
From: Krzysztof Kozlowski @ 2015-12-28  1:54 UTC (permalink / raw)
  To: Arnd Bergmann, Kukjin Kim; +Cc: linux-arm-kernel, linux-samsung-soc

On 18.12.2015 23:46, Arnd Bergmann wrote:
> I got one randconfig build that failed to compile plat-samsung/pm-debug.c
> on s3c64xx:
> 
> In file included from arch/arm/plat-samsung/pm-debug.c:27:0:
> arch/arm/mach-s3c64xx/include/mach/pm-core.h: In function 's3c_pm_debug_init_uart':
> arch/arm/mach-s3c64xx/include/mach/pm-core.h:25:25: error: 'S3C_VA_SYS' undeclared (first use in this function)
>   u32 tmp = __raw_readl(S3C_PCLK_GATE);
> arch/arm/mach-s3c64xx/include/mach/pm-core.h:25:25: note: each undeclared identifier is reported only once for each function it appears in
> arch/arm/mach-s3c64xx/include/mach/pm-core.h:39:2: error: implicit declaration of function 'udelay' [-Werror=implicit-function-declaration]
>   udelay(10);
> 
> I have not investigated why this does not show up much more often, I
> guess the headers are usually included from elsewhere, but adding
> explicit #include statements is an obvious fix.
> 
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
> I suspect this has been broken for a long time, so no rush, but please
> apply this to a cleanup branch.
> 

The dependencies for plat-samsung/SAMSUNG_PM_* symbols are little bit
mixed up:
1. pm-common.o depends on PM_SLEEP,
2. pm.o and pm-debug.o depend on PM and sometimes they use stuff from
pm-common.

It is possible to create a config with PM_SLEEP=n and PM=y so this is
confusing (pm-common won't be linked).

I think this still compiles fine because of various #ifdefs but it would
be nice to clean it up.

Anyway your patch looks correct:

Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>

Best regards,
Krzysztof

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

* [PATCH] ARM: s3c64xx: fix pm-debug compilation
@ 2015-12-28  1:54   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 6+ messages in thread
From: Krzysztof Kozlowski @ 2015-12-28  1:54 UTC (permalink / raw)
  To: linux-arm-kernel

On 18.12.2015 23:46, Arnd Bergmann wrote:
> I got one randconfig build that failed to compile plat-samsung/pm-debug.c
> on s3c64xx:
> 
> In file included from arch/arm/plat-samsung/pm-debug.c:27:0:
> arch/arm/mach-s3c64xx/include/mach/pm-core.h: In function 's3c_pm_debug_init_uart':
> arch/arm/mach-s3c64xx/include/mach/pm-core.h:25:25: error: 'S3C_VA_SYS' undeclared (first use in this function)
>   u32 tmp = __raw_readl(S3C_PCLK_GATE);
> arch/arm/mach-s3c64xx/include/mach/pm-core.h:25:25: note: each undeclared identifier is reported only once for each function it appears in
> arch/arm/mach-s3c64xx/include/mach/pm-core.h:39:2: error: implicit declaration of function 'udelay' [-Werror=implicit-function-declaration]
>   udelay(10);
> 
> I have not investigated why this does not show up much more often, I
> guess the headers are usually included from elsewhere, but adding
> explicit #include statements is an obvious fix.
> 
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---
> I suspect this has been broken for a long time, so no rush, but please
> apply this to a cleanup branch.
> 

The dependencies for plat-samsung/SAMSUNG_PM_* symbols are little bit
mixed up:
1. pm-common.o depends on PM_SLEEP,
2. pm.o and pm-debug.o depend on PM and sometimes they use stuff from
pm-common.

It is possible to create a config with PM_SLEEP=n and PM=y so this is
confusing (pm-common won't be linked).

I think this still compiles fine because of various #ifdefs but it would
be nice to clean it up.

Anyway your patch looks correct:

Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>

Best regards,
Krzysztof

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

* Re: [PATCH] ARM: s3c64xx: fix pm-debug compilation
  2015-12-28  1:54   ` Krzysztof Kozlowski
@ 2015-12-31 16:27     ` Arnd Bergmann
  -1 siblings, 0 replies; 6+ messages in thread
From: Arnd Bergmann @ 2015-12-31 16:27 UTC (permalink / raw)
  To: Krzysztof Kozlowski; +Cc: Kukjin Kim, linux-arm-kernel, linux-samsung-soc

On Monday 28 December 2015 10:54:10 Krzysztof Kozlowski wrote:
> On 18.12.2015 23:46, Arnd Bergmann wrote:
> > I got one randconfig build that failed to compile plat-samsung/pm-debug.c
> > on s3c64xx:
> > 
> > In file included from arch/arm/plat-samsung/pm-debug.c:27:0:
> > arch/arm/mach-s3c64xx/include/mach/pm-core.h: In function 's3c_pm_debug_init_uart':
> > arch/arm/mach-s3c64xx/include/mach/pm-core.h:25:25: error: 'S3C_VA_SYS' undeclared (first use in this function)
> >   u32 tmp = __raw_readl(S3C_PCLK_GATE);
> > arch/arm/mach-s3c64xx/include/mach/pm-core.h:25:25: note: each undeclared identifier is reported only once for each function it appears in
> > arch/arm/mach-s3c64xx/include/mach/pm-core.h:39:2: error: implicit declaration of function 'udelay' [-Werror=implicit-function-declaration]
> >   udelay(10);
> > 
> > I have not investigated why this does not show up much more often, I
> > guess the headers are usually included from elsewhere, but adding
> > explicit #include statements is an obvious fix.
> > 
> > Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> > ---
> > I suspect this has been broken for a long time, so no rush, but please
> > apply this to a cleanup branch.
> > 
> 
> The dependencies for plat-samsung/SAMSUNG_PM_* symbols are little bit
> mixed up:
> 1. pm-common.o depends on PM_SLEEP,
> 2. pm.o and pm-debug.o depend on PM and sometimes they use stuff from
> pm-common.
> 
> It is possible to create a config with PM_SLEEP=n and PM=y so this is
> confusing (pm-common won't be linked).

Ok, thanks for taking a deeper look into this.

> I think this still compiles fine because of various #ifdefs but it would
> be nice to clean it up.
>
> Anyway your patch looks correct:
> 
> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>

I've applied both patches on top of next/multiplatform now, to avoid
conflicts with other changes in that branch.

	Arnd

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

* [PATCH] ARM: s3c64xx: fix pm-debug compilation
@ 2015-12-31 16:27     ` Arnd Bergmann
  0 siblings, 0 replies; 6+ messages in thread
From: Arnd Bergmann @ 2015-12-31 16:27 UTC (permalink / raw)
  To: linux-arm-kernel

On Monday 28 December 2015 10:54:10 Krzysztof Kozlowski wrote:
> On 18.12.2015 23:46, Arnd Bergmann wrote:
> > I got one randconfig build that failed to compile plat-samsung/pm-debug.c
> > on s3c64xx:
> > 
> > In file included from arch/arm/plat-samsung/pm-debug.c:27:0:
> > arch/arm/mach-s3c64xx/include/mach/pm-core.h: In function 's3c_pm_debug_init_uart':
> > arch/arm/mach-s3c64xx/include/mach/pm-core.h:25:25: error: 'S3C_VA_SYS' undeclared (first use in this function)
> >   u32 tmp = __raw_readl(S3C_PCLK_GATE);
> > arch/arm/mach-s3c64xx/include/mach/pm-core.h:25:25: note: each undeclared identifier is reported only once for each function it appears in
> > arch/arm/mach-s3c64xx/include/mach/pm-core.h:39:2: error: implicit declaration of function 'udelay' [-Werror=implicit-function-declaration]
> >   udelay(10);
> > 
> > I have not investigated why this does not show up much more often, I
> > guess the headers are usually included from elsewhere, but adding
> > explicit #include statements is an obvious fix.
> > 
> > Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> > ---
> > I suspect this has been broken for a long time, so no rush, but please
> > apply this to a cleanup branch.
> > 
> 
> The dependencies for plat-samsung/SAMSUNG_PM_* symbols are little bit
> mixed up:
> 1. pm-common.o depends on PM_SLEEP,
> 2. pm.o and pm-debug.o depend on PM and sometimes they use stuff from
> pm-common.
> 
> It is possible to create a config with PM_SLEEP=n and PM=y so this is
> confusing (pm-common won't be linked).

Ok, thanks for taking a deeper look into this.

> I think this still compiles fine because of various #ifdefs but it would
> be nice to clean it up.
>
> Anyway your patch looks correct:
> 
> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>

I've applied both patches on top of next/multiplatform now, to avoid
conflicts with other changes in that branch.

	Arnd

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

end of thread, other threads:[~2015-12-31 16:28 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-12-18 14:46 [PATCH] ARM: s3c64xx: fix pm-debug compilation Arnd Bergmann
2015-12-18 14:46 ` Arnd Bergmann
2015-12-28  1:54 ` Krzysztof Kozlowski
2015-12-28  1:54   ` Krzysztof Kozlowski
2015-12-31 16:27   ` Arnd Bergmann
2015-12-31 16:27     ` Arnd Bergmann

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.