Skip to contentSkip to conversation

ARM: S3C24XX: Define a macro to avoid compilation error

PATCH New Ben Dooks 3 participants 17 messages Oct 28, 2009 – Nov 1, 2009

Subsystems (5)
lore
Share & tools
lore

Ben Dooks

author
#0 lore raw

PATCH 1/12 ARM: S3C24XX: Define a macro to avoid compilation error

From: Ramax Lo <[email protected]>

Define a macro to avoid the following error during kernel build process for platforms other than s3c2410:

arch/arm/plat-s3c24xx/cpu.c:84: error: ?s3c2410a_init? undeclared here (not in a function)

---
 arch/arm/plat-s3c24xx/include/plat/s3c2410.h |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
arch/arm/plat-s3c24xx/include/plat/s3c2410.h +1 -0
index b6deeef..82ab4aa 100644
@@ -27,6 +27,7 @@ extern void s3c2410_init_clocks(int xtal);
 #define s3c2410_init_uarts NULL
 #define s3c2410_map_io NULL
 #define s3c2410_init NULL
+#define s3c2410a_init NULL
 #endif
 
 extern int s3c2410_baseclk_add(void);
Signature · 1 line
1.6.3.3
author
#1 lore raw

PATCH 1/12 ARM: S3C24XX: Define a macro to avoid compilation error

This series should have had the following prefix:

S3C64XX/S3C24XX fixes based on -rc5.

shortlog:

Ben Dooks (9):
ARM: S3C2410: Fix link if CONFIG_S3C2410_IOTIMING is not set
ARM: S3C: Add info for supporting circular DMA buffers Merge branch 'fixes-s3c24xx' into fixes-s3c
Merge branch 'fixes-s3c64xx-dma' into fixes-s3c
Merge branch 'fixes-s3c64xx' into fixes-s3c
ARM: S3C2440: mini2440: Fix missing CONFIG_S3C_DEV_USB_HOST
ARM: S3C24XX: Fix warnings in arch/arm/plat-s3c24xx/gpio.c
ARM: S3C2440: mini2440: Fix spare warnings
ARM: S3C2410: Fix sparse warnings in arch/arm/mach-s3c2410/gpio.c

Harald Welte (1):

      ARM: S3C24XX: Introduce S3C2442B CPU

Julia Lawall (1):
ARM: S3C24XX: arch/arm/plat-s3c24xx: Move dereference after NULL test

Kukjin Kim (1):
ARM: S3C64XX: Fix S3C64XX_CLKDIV0_ARM_MASK value

Mark Brown (1):
ARM: S3C64XX: Set rate of crystal mux

Ramax Lo (1):
ARM: S3C24XX: Define a macro to avoid compilation error

Ryan Mallon (1):
ARM: S3C: Fix adc function exports

 arch/arm/mach-s3c2410/gpio.c                       |    1 +
 arch/arm/mach-s3c2410/include/mach/dma.h           |    7 +++++++
 arch/arm/mach-s3c2440/Kconfig                      |    1 +
 arch/arm/mach-s3c2440/mach-mini2440.c              |    4 ++--
 arch/arm/mach-s3c6400/include/mach/dma.h           |    5 +++++
 arch/arm/plat-s3c24xx/adc.c                        |    2 +-
 arch/arm/plat-s3c24xx/cpu.c                        |   10 ++++++++++
 arch/arm/plat-s3c24xx/dma.c                        |    6 +++---
 arch/arm/plat-s3c24xx/gpio.c                       |    1 +
 arch/arm/plat-s3c24xx/include/plat/cpu-freq-core.h |    9 +++++++--
 arch/arm/plat-s3c24xx/include/plat/s3c2410.h       |    1 +
 arch/arm/plat-s3c64xx/include/plat/regs-clock.h    |    4 ++--
 arch/arm/plat-s3c64xx/s3c6400-clock.c              |    3 +++
 sound/soc/s3c24xx/s3c24xx-pcm.c                    |   17 +++++++++++++++--
 14 files changed, 59 insertions(+), 12 deletions(-)
Signature · 4 lines
Ben

Q:      What's a light-year?
A:      One-third less calories than a regular year.
author
#2 lore raw

PATCH 2/12 ARM: S3C24XX: Introduce S3C2442B CPU

In reply to Ben Dooks

From: Harald Welte <[email protected]>

Add the S3C2442B CPU ID to aid support the Openmoko GTA02 / Freerunner.

[ben-linux at fluff.org: edit description for clarity and S3C2442B as uppercase]
---
 arch/arm/plat-s3c24xx/cpu.c |   10 ++++++++++
 1 files changed, 10 insertions(+), 0 deletions(-)
arch/arm/plat-s3c24xx/cpu.c +10 -0
index 5447e60..4af9dd9 100644
@@ -61,6 +61,7 @@ static const char name_s3c2410[]  = "S3C2410";
 static const char name_s3c2412[]  = "S3C2412";
 static const char name_s3c2440[]  = "S3C2440";
 static const char name_s3c2442[]  = "S3C2442";
+static const char name_s3c2442b[]  = "S3C2442B";
 static const char name_s3c2443[]  = "S3C2443";
 static const char name_s3c2410a[] = "S3C2410A";
 static const char name_s3c2440a[] = "S3C2440A";
@@ -112,6 +113,15 @@ static struct cpu_table cpu_ids[] __initdata = {
 		.name		= name_s3c2442
 	},
 	{
+		.idcode		= 0x32440aab,
+		.idmask		= 0xffffffff,
+		.map_io		= s3c244x_map_io,
+		.init_clocks	= s3c244x_init_clocks,
+		.init_uarts	= s3c244x_init_uarts,
+		.init		= s3c2442_init,
+		.name		= name_s3c2442b
+	},
+	{
 		.idcode		= 0x32412001,
 		.idmask		= 0xffffffff,
 		.map_io		= s3c2412_map_io,
Signature · 1 line
1.6.3.3
#3 lore raw

PATCH 2/12 ARM: S3C24XX: Introduce S3C2442B CPU

Quoted 26 lines · Ben Dooks

From: Harald Welte <[email protected]>

Add the S3C2442B CPU ID to aid support the Openmoko GTA02 / Freerunner.

[ben-linux at fluff.org: edit description for clarity and S3C2442B as uppercase]
---
 arch/arm/plat-s3c24xx/cpu.c |   10 ++++++++++
 1 files changed, 10 insertions(+), 0 deletions(-)
arch/arm/plat-s3c24xx/cpu.c +1 -0
index 5447e60..4af9dd9 100644
@@ -61,6 +61,7 @@ static const char name_s3c2410[]  = "S3C2410";
 static const char name_s3c2412[]  = "S3C2412";
 static const char name_s3c2440[]  = "S3C2440";
 static const char name_s3c2442[]  = "S3C2442";
+static const char name_s3c2442b[]  = "S3C2442B";
 static const char name_s3c2443[]  = "S3C2443";
 static const char name_s3c2410a[] = "S3C2410A";
 static const char name_s3c2440a[] = "S3C2440A";

arch/arm/plat-s3c24xx/cpu.c static struct cpu_table cpu_ids[] __initdata = { · line 122

Quoted 10 lines
arch/arm/plat-s3c24xx/cpu.c +7 -0
@@ -112,6 +113,15 @@ static struct cpu_table cpu_ids[] __initdata = {
 		.name		= name_s3c2442
 	},
 	{
+		.idcode		= 0x32440aab,
+		.idmask		= 0xffffffff,
+		.map_io		= s3c244x_map_io,
+		.init_clocks	= s3c244x_init_clocks,
+		.init_uarts	= s3c244x_init_uarts,
+		.init		= s3c2442_init,
+		.name		= name_s3c2442b

Could we simply put the string here? This is unneccessary obfuscation... and it is used just once so it does not save anything...
Pavel

Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
author
#4 lore raw

PATCH 3/12 ARM: S3C2410: Fix link if CONFIG_S3C2410_IOTIMING is not set

In reply to Ben Dooks

Fix the link errors if cpu-frequency support is enabled on s3c2410 systems but there is no CONFIG_S3C2410_IOTIMING set. Fix this by ensuring the relevant symbols are defined NULL if the code is not being built in.

Fixes the following error:
arch/arm/mach-s3c2410/built-in.o: undefined reference to s3c2410_iotiming_get' arch/arm/mach-s3c2410/built-in.o: undefined reference to s3c2410_iotiming_set' arch/arm/mach-s3c2410/built-in.o: undefined reference to `s3c2410_iotiming_calc'

---
 arch/arm/plat-s3c24xx/include/plat/cpu-freq-core.h |    9 +++++++--
 1 files changed, 7 insertions(+), 2 deletions(-)
arch/arm/plat-s3c24xx/include/plat/cpu-freq-core.h +7 -2
index efeb025..c776120 100644
@@ -222,7 +222,9 @@ extern struct clk *s3c_cpufreq_clk_get(struct device *, const char *);
 /* S3C2410 and compatible exported functions */
 
 extern void s3c2410_cpufreq_setrefresh(struct s3c_cpufreq_config *cfg);
+extern void s3c2410_set_fvco(struct s3c_cpufreq_config *cfg);
 
+#ifdef CONFIG_S3C2410_IOTIMING
 extern int s3c2410_iotiming_calc(struct s3c_cpufreq_config *cfg,
 				 struct s3c_iotimings *iot);
 
@@ -231,8 +233,11 @@ extern int s3c2410_iotiming_get(struct s3c_cpufreq_config *cfg,
 
 extern void s3c2410_iotiming_set(struct s3c_cpufreq_config *cfg,
 				 struct s3c_iotimings *iot);
-
-extern void s3c2410_set_fvco(struct s3c_cpufreq_config *cfg);
+#else
+#define s3c2410_iotiming_calc NULL
+#define s3c2410_iotiming_get NULL
+#define s3c2410_iotiming_set NULL
+#endif /* CONFIG_S3C2410_IOTIMING */
 
 /* S3C2412 compatible routines */
 
Signature · 1 line
1.6.3.3
author
#5 lore raw

PATCH 4/12 ARM: S3C: Fix adc function exports

In reply to Ben Dooks

From: Ryan Mallon <[email protected]>

Fix the export of s3c_adc_read.

[ben-linux at fluff.org: remove unexport of s3c_adc_start, needed for ts]
---
 arch/arm/plat-s3c24xx/adc.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
arch/arm/plat-s3c24xx/adc.c +1 -1
index 11117a7..b18eead 100644
@@ -188,7 +188,7 @@ int s3c_adc_read(struct s3c_adc_client *client, unsigned int ch)
 err:
 	return ret;
 }
-EXPORT_SYMBOL_GPL(s3c_adc_convert);
+EXPORT_SYMBOL_GPL(s3c_adc_read);
 
 static void s3c_adc_default_select(struct s3c_adc_client *client,
 				   unsigned select)
Signature · 1 line
1.6.3.3
author
#6 lore raw

PATCH 5/12 ARM: S3C24XX: arch/arm/plat-s3c24xx: Move dereference after NULL test

In reply to Ben Dooks

From: Julia Lawall <[email protected]>

If the NULL test on buf is needed, then the dereference should be after the NULL test.

A simplified version of the semantic match that detects this problem is as follows (http://coccinelle.lip6.fr/):

// <smpl>
@match exists@
expression x, E;
identifier fld;
@@

* x->fld
... when != \(x = E\|&x\)
* x == NULL
// </smpl>

---
 arch/arm/plat-s3c24xx/dma.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)
arch/arm/plat-s3c24xx/dma.c +3 -3
index 196b191..f046f8c 100644
@@ -208,14 +208,14 @@ s3c2410_dma_loadbuffer(struct s3c2410_dma_chan *chan,
 {
 	unsigned long reload;
 
-	pr_debug("s3c2410_chan_loadbuffer: loading buff %p (0x%08lx,0x%06x)\n",
-		 buf, (unsigned long)buf->data, buf->size);
-
 	if (buf == NULL) {
 		dmawarn("buffer is NULL\n");
 		return -EINVAL;
 	}
 
+	pr_debug("s3c2410_chan_loadbuffer: loading buff %p (0x%08lx,0x%06x)\n",
+		 buf, (unsigned long)buf->data, buf->size);
+
 	/* check the state of the channel before we do anything */
 
 	if (chan->load_state == S3C2410_DMALOAD_1LOADED) {
Signature · 1 line
1.6.3.3
author
#7 lore raw

PATCH 6/12 ARM: S3C64XX: Fix S3C64XX_CLKDIV0_ARM_MASK value

In reply to Ben Dooks

From: Kukjin Kim <[email protected]>

Fix the values of S3C6400_CLKDIV0_ARM_MASK and S3C6410_CLKDIV0_ARM_MASK.

---
 arch/arm/plat-s3c64xx/include/plat/regs-clock.h |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
arch/arm/plat-s3c64xx/include/plat/regs-clock.h +2 -2
index a8777a7..ff46e7f 100644
@@ -51,8 +51,8 @@
 #define S3C6400_CLKDIV0_HCLK_SHIFT	(8)
 #define S3C6400_CLKDIV0_MPLL_MASK	(0x1 << 4)
 #define S3C6400_CLKDIV0_MPLL_SHIFT	(4)
-#define S3C6400_CLKDIV0_ARM_MASK	(0x3 << 0)
-#define S3C6410_CLKDIV0_ARM_MASK	(0x7 << 0)
+#define S3C6400_CLKDIV0_ARM_MASK	(0x7 << 0)
+#define S3C6410_CLKDIV0_ARM_MASK	(0xf << 0)
 #define S3C6400_CLKDIV0_ARM_SHIFT	(0)
 
 /* CLKDIV1 */
Signature · 1 line
1.6.3.3
author
#8 lore raw

PATCH 7/12 ARM: S3C64XX: Set rate of crystal mux

In reply to Ben Dooks

From: Mark Brown <[email protected]>

The current code assumes that the external clock mux will be set to the crystal. Set this up explicitly within the clock API.

---
 arch/arm/plat-s3c64xx/s3c6400-clock.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
arch/arm/plat-s3c64xx/s3c6400-clock.c +3 -0
index 9745852..6ffa21e 100644
@@ -677,6 +677,9 @@ void __init_or_cpufreq s3c6400_setup_clocks(void)
 
 	printk(KERN_DEBUG "%s: xtal is %ld\n", __func__, xtal);
 
+	/* For now assume the mux always selects the crystal */
+	clk_ext_xtal_mux.parent = xtal_clk;
+
 	epll = s3c6400_get_epll(xtal);
 	mpll = s3c6400_get_pll(xtal, __raw_readl(S3C_MPLL_CON));
 	apll = s3c6400_get_pll(xtal, __raw_readl(S3C_APLL_CON));
Signature · 1 line
1.6.3.3
author
#9 lore raw

PATCH 8/12 ARM: S3C: Add info for supporting circular DMA buffers

In reply to Ben Dooks

The S3C64XX DMA implementation will work a lot better with the ability to enqueue circular buffers as the hardware can do it's own linked-list management.

Add a function s3c_dma_has_circular() to show that the system can do this and a flag for the channel.

Update the s3c24xx/s3c64xx I2S DMA code to deal with this.

CC Mark Brown <broonie@@opensource.wolfsonmicro.com>
---
 arch/arm/mach-s3c2410/include/mach/dma.h |    7 +++++++
 arch/arm/mach-s3c6400/include/mach/dma.h |    5 +++++
 sound/soc/s3c24xx/s3c24xx-pcm.c          |   17 +++++++++++++++--
 3 files changed, 27 insertions(+), 2 deletions(-)
arch/arm/mach-s3c2410/include/mach/dma.h +7 -0
index c3a2629..92e2687 100644
@@ -110,6 +110,8 @@ enum s3c2410_dma_loadst {
 					    * waiting for reloads */
 #define S3C2410_DMAF_AUTOSTART    (1<<1)   /* auto-start if buffer queued */
 
+#define S3C2410_DMAF_CIRCULAR	(1 << 2)	/* no circular dma support */
+
 /* dma buffer */
 
 struct s3c2410_dma_buf;
@@ -194,4 +196,9 @@ struct s3c2410_dma_chan {
 
 typedef unsigned long dma_device_t;
 
+static inline bool s3c_dma_has_circular(void)
+{
+	return false;
+}
+
 #endif /* __ASM_ARCH_DMA_H */
arch/arm/mach-s3c6400/include/mach/dma.h +5 -0
index 1067619..004edab 100644
@@ -68,6 +68,11 @@ static __inline__ int s3c_dma_has_circular(void)
 
 #define S3C2410_DMAF_CIRCULAR		(1 << 0)
 
+static inline bool s3c_dma_has_circular(void)
+{
+	return false;
+}
+
 #include <plat/dma.h>
 
 #endif /* __ASM_ARCH_IRQ_H */
sound/soc/s3c24xx/s3c24xx-pcm.c +15 -2
index 5cbbdc8..1f35c6f 100644
@@ -75,11 +75,19 @@ static void s3c24xx_pcm_enqueue(struct snd_pcm_substream *substream)
 {
 	struct s3c24xx_runtime_data *prtd = substream->runtime->private_data;
 	dma_addr_t pos = prtd->dma_pos;
+	unsigned int limit;
 	int ret;
 
 	pr_debug("Entered %s\n", __func__);
 
-	while (prtd->dma_loaded < prtd->dma_limit) {
+	if (s3c_dma_has_circular()) {
+		limit = (prtd->dma_end - prtd->dma_start) / prtd->dma_period;
+	} else
+		limit = prtd->dma_limit;
+
+	pr_debug("%s: loaded %d, limit %d\n", __func__, prtd->dma_loaded, limit);
+
+	while (prtd->dma_loaded < limit) {
 		unsigned long len = prtd->dma_period;
 
 		pr_debug("dma_loaded: %d\n", prtd->dma_loaded);
@@ -123,7 +131,7 @@ static void s3c24xx_audio_buffdone(struct s3c2410_dma_chan *channel,
 		snd_pcm_period_elapsed(substream);
 
 	spin_lock(&prtd->lock);
-	if (prtd->state & ST_RUNNING) {
+	if (prtd->state & ST_RUNNING && !s3c_dma_has_circular()) {
 		prtd->dma_loaded--;
 		s3c24xx_pcm_enqueue(substream);
 	}
@@ -164,6 +172,11 @@ static int s3c24xx_pcm_hw_params(struct snd_pcm_substream *substream,
 			printk(KERN_ERR "failed to get dma channel\n");
 			return ret;
 		}
+
+		/* use the circular buffering if we have it available. */
+		if (s3c_dma_has_circular())
+			s3c2410_dma_setflags(prtd->params->channel,
+					     S3C2410_DMAF_CIRCULAR);
 	}
 
 	s3c2410_dma_set_buffdone_fn(prtd->params->channel,
Signature · 1 line
1.6.3.3
#10 lore raw

PATCH 8/12 ARM: S3C: Add info for supporting circular DMA buffers

Quoted 4 lines · Ben Dooks

The S3C64XX DMA implementation will work a lot better with the ability to enqueue circular buffers as the hardware can do it's own linked-list management.

Quoted 8 lines

Add a function s3c_dma_has_circular() to show that the system can do this and a flag for the channel.

Update the s3c24xx/s3c64xx I2S DMA code to deal with this.

CC Mark Brown <broonie@@opensource.wolfsonmicro.com>

If Samsung are going to be doing their upstreaming stuff it may make sense to merge this via ASoC since I anticipate some changes there, but on the other hand that seems to have ground to a halt and the merge may well go smoothly anyway. My standard answer here would be putting the patch on a branch by itself so if there are any issues it can be merged into both trees to avoid the merge issues.

author
#11 lore raw

PATCH 8/12 ARM: S3C: Add info for supporting circular DMA buffers

Quoted 5 lines · Mark Brown
Quoted 3 lines · Ben Dooks

The S3C64XX DMA implementation will work a lot better with the ability to enqueue circular buffers as the hardware can do it's own linked-list management.

Quoted 8 lines

If Samsung are going to be doing their upstreaming stuff it may make sense to merge this via ASoC since I anticipate some changes there, but on the other hand that seems to have ground to a halt and the merge may well go smoothly anyway. My standard answer here would be putting the patch on a branch by itself so if there are any issues it can be merged into both trees to avoid the merge issues.

I was pushing this up via my tree, it touches both the core and ASoC code so decided to merge myself and copy-you.

On the whole Samsung merging, there is still work in progress there so we will see what is going to happen.

Signature · 4 lines
Ben

Q:      What's a light-year?
A:      One-third less calories than a regular year.
#12 lore raw

PATCH 8/12 ARM: S3C: Add info for supporting circular DMA buffers

Quoted 2 lines · Ben Dooks

I was pushing this up via my tree, it touches both the core and ASoC code so decided to merge myself and copy-you.

Like I say, if you could put it on a branch I could pull in if need be in the case of merge conflicts that'd be ideal.

Quoted 2 lines

On the whole Samsung merging, there is still work in progress there so we will see what is going to happen.

The general trend appears to be moving away from upstream as far as I can see; public activity has certainly been dying down.

author
#13 lore raw

PATCH 9/12 ARM: S3C2440: mini2440: Fix missing CONFIG_S3C_DEV_USB_HOST

In reply to Ben Dooks

Fix missing select of S3C_DEV_USB_HOST when building for mini2440 only. Fixes the following error:

built-in.o: undefined reference to s3c_device_usb

---
 arch/arm/mach-s3c2440/Kconfig |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
arch/arm/mach-s3c2440/Kconfig +1 -0
index d7bba91..a8b69d7 100644
@@ -103,6 +103,7 @@ config MACH_MINI2440
 	select LEDS_TRIGGER_BACKLIGHT
 	select SND_S3C24XX_SOC_S3C24XX_UDA134X
 	select S3C_DEV_NAND
+	select S3C_DEV_USB_HOST
 	help
 	  Say Y here to select support for the MINI2440. Is a 10cm x 10cm board
 	  available via various sources. It can come with a 3.5" or 7" touch LCD.
Signature · 1 line
1.6.3.3
author
#14 lore raw

PATCH 10/12 ARM: S3C24XX: Fix warnings in arch/arm/plat-s3c24xx/gpio.c

In reply to Ben Dooks

Fix the following warnings from sparse in arch/arm/plat-s3c24xx/gpio. due to the missing include of <mach/gpio-fns.h>

gpio.c:36:6: warning: symbol 's3c2410_gpio_cfgpin' was not declared. Should it be static? gpio.c:84:14: warning: symbol 's3c2410_gpio_getcfg' was not declared. Should it be static? gpio.c:103:6: warning: symbol 's3c2410_gpio_pullup' was not declared. Should it be static? gpio.c:125:5: warning: symbol 's3c2410_gpio_getpull' was not declared. Should it be static? gpio.c:138:6: warning: symbol 's3c2410_gpio_setpin' was not declared. Should it be static? gpio.c:157:14: warning: symbol 's3c2410_gpio_getpin' was not declared. Should it be static? gpio.c:184:5: warning: symbol 's3c2410_gpio_getirq' was not declared. Should it be static?

---
 arch/arm/plat-s3c24xx/gpio.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
arch/arm/plat-s3c24xx/gpio.c +1 -0
index 95df059..5467470 100644
@@ -29,6 +29,7 @@
 #include <linux/io.h>
 
 #include <mach/hardware.h>
+#include <mach/gpio-fns.h>
 #include <asm/irq.h>
 
 #include <mach/regs-gpio.h>
Signature · 1 line
1.6.3.3
author
#15 lore raw

PATCH 11/12 ARM: S3C2440: mini2440: Fix spare warnings

In reply to Ben Dooks

Fix the following sparse warnings in arch/arm/mach-s3c2440/mach-mini2440.c due to missing 'static'.

warning: symbol 'mini2440_lcd_cfg' was not declared. Should it be static?
warning: symbol 'mini2440_fb_info' was not declared. Should it be static?

---
 arch/arm/mach-s3c2440/mach-mini2440.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
arch/arm/mach-s3c2440/mach-mini2440.c +2 -2
index ec71a69..1c3382f 100644
@@ -144,7 +144,7 @@ static struct s3c2410_udc_mach_info mini2440_udc_cfg __initdata = {
 	.type		= (S3C2410_LCDCON1_TFT16BPP |\
 			   S3C2410_LCDCON1_TFT)
 
-struct s3c2410fb_display mini2440_lcd_cfg[] __initdata = {
+static struct s3c2410fb_display mini2440_lcd_cfg[] __initdata = {
 	[0] = {	/* mini2440 + 3.5" TFT + touchscreen */
 		_LCD_DECLARE(
 			7,			/* The 3.5 is quite fast */
@@ -191,7 +191,7 @@ struct s3c2410fb_display mini2440_lcd_cfg[] __initdata = {
 #define S3C2410_GPCCON_MASK(x)	(3 << ((x) * 2))
 #define S3C2410_GPDCON_MASK(x)	(3 << ((x) * 2))
 
-struct s3c2410fb_mach_info mini2440_fb_info __initdata = {
+static struct s3c2410fb_mach_info mini2440_fb_info __initdata = {
 	.displays	 = &mini2440_lcd_cfg[0], /* not constant! see init */
 	.num_displays	 = 1,
 	.default_display = 0,
Signature · 1 line
1.6.3.3
author
#16 lore raw

PATCH 12/12 ARM: S3C2410: Fix sparse warnings in arch/arm/mach-s3c2410/gpio.c

In reply to Ben Dooks

Fix sparse warning in arch/arm/mach-s3c2410/gpio.c due to missing include of <mach/gpio-fns.h>. Fixes the following warning:

warning: symbol 's3c2410_gpio_irqfilter' was not declared. Should it be static?

---
 arch/arm/mach-s3c2410/gpio.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
arch/arm/mach-s3c2410/gpio.c +1 -0
index 7974afc..9664e01 100644
@@ -28,6 +28,7 @@
 #include <linux/io.h>
 
 #include <mach/hardware.h>
+#include <mach/gpio-fns.h>
 #include <asm/irq.h>
 
 #include <mach/regs-gpio.h>
Signature · 1 line
1.6.3.3