* [PATCH 2/2 v3] ARM: shmobile: r8a7790: add __initdata on resource and device data
@ 2013-05-27 0:54 Kuninori Morimoto
2013-05-27 9:51 ` Simon Horman
0 siblings, 1 reply; 2+ messages in thread
From: Kuninori Morimoto @ 2013-05-27 0:54 UTC (permalink / raw)
To: linux-sh
These data will be kmemdup()'ed on
platform_device_add_resources() and platform_device_add_data()
Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
v2 -> v3
- no change, but become 1st patch
arch/arm/mach-shmobile/setup-r8a7790.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/arch/arm/mach-shmobile/setup-r8a7790.c b/arch/arm/mach-shmobile/setup-r8a7790.c
index ed7ee24..1e18152 100644
--- a/arch/arm/mach-shmobile/setup-r8a7790.c
+++ b/arch/arm/mach-shmobile/setup-r8a7790.c
@@ -29,17 +29,17 @@
#include <mach/r8a7790.h>
#include <asm/mach/arch.h>
-static const struct resource pfc_resources[] = {
+static const struct resource pfc_resources[] __initdata = {
DEFINE_RES_MEM(0xe6060000, 0x250),
};
#define R8A7790_GPIO(idx) \
-static struct resource r8a7790_gpio##idx##_resources[] = { \
+static struct resource r8a7790_gpio##idx##_resources[] __initdata = { \
DEFINE_RES_MEM(0xe6050000 + 0x1000 * (idx), 0x50), \
DEFINE_RES_IRQ(gic_spi(4 + (idx))), \
}; \
\
-static struct gpio_rcar_config r8a7790_gpio##idx##_platform_data = { \
+static struct gpio_rcar_config r8a7790_gpio##idx##_platform_data __initdata = { \
.gpio_base = 32 * (idx), \
.irq_base = 0, \
.number_of_pins = 32, \
@@ -101,7 +101,7 @@ void __init r8a7790_pinmux_init(void)
enum { SCIFA0, SCIFA1, SCIFB0, SCIFB1, SCIFB2, SCIFA2, SCIF0, SCIF1 };
-static const struct plat_sci_port scif[] = {
+static const struct plat_sci_port scif[] __initdata = {
SCIFA_DATA(SCIFA0, 0xe6c40000, gic_spi(144)), /* SCIFA0 */
SCIFA_DATA(SCIFA1, 0xe6c50000, gic_spi(145)), /* SCIFA1 */
SCIFB_DATA(SCIFB0, 0xe6c20000, gic_spi(148)), /* SCIFB0 */
@@ -118,11 +118,11 @@ static inline void r8a7790_register_scif(int idx)
sizeof(struct plat_sci_port));
}
-static struct renesas_irqc_config irqc0_data = {
+static struct renesas_irqc_config irqc0_data __initdata = {
.irq_base = irq_pin(0), /* IRQ0 -> IRQ3 */
};
-static struct resource irqc0_resources[] = {
+static struct resource irqc0_resources[] __initdata = {
DEFINE_RES_MEM(0xe61c0000, 0x200), /* IRQC Event Detector Block_0 */
DEFINE_RES_IRQ(gic_spi(0)), /* IRQ0 */
DEFINE_RES_IRQ(gic_spi(1)), /* IRQ1 */
--
1.7.9.5
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH 2/2 v3] ARM: shmobile: r8a7790: add __initdata on resource and device data
2013-05-27 0:54 [PATCH 2/2 v3] ARM: shmobile: r8a7790: add __initdata on resource and device data Kuninori Morimoto
@ 2013-05-27 9:51 ` Simon Horman
0 siblings, 0 replies; 2+ messages in thread
From: Simon Horman @ 2013-05-27 9:51 UTC (permalink / raw)
To: linux-sh
On Sun, May 26, 2013 at 05:54:04PM -0700, Kuninori Morimoto wrote:
> These data will be kmemdup()'ed on
> platform_device_add_resources() and platform_device_add_data()
>
> Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
This appears to cause a build failure.
include/linux/platform_device.h: In function ‘r8a7790_add_standard_devices’:
arch/arm/mach-shmobile/setup-r8a7790.c:125: error: irqc0_resources causes a section type conflict
arch/arm/mach-shmobile/setup-r8a7790.c:121: error: irqc0_data causes a section type conflict
include/linux/platform_device.h: In function ‘r8a7790_pinmux_init’:
arch/arm/mach-shmobile/setup-r8a7790.c:49: error: r8a7790_gpio0_resources causes a section type conflict
arch/arm/mach-shmobile/setup-r8a7790.c:49: error: r8a7790_gpio0_platform_data causes a section type conflict
arch/arm/mach-shmobile/setup-r8a7790.c:50: error: r8a7790_gpio1_resources causes a section type conflict
arch/arm/mach-shmobile/setup-r8a7790.c:50: error: r8a7790_gpio1_platform_data causes a section type conflict
arch/arm/mach-shmobile/setup-r8a7790.c:51: error: r8a7790_gpio2_resources causes a section type conflict
arch/arm/mach-shmobile/setup-r8a7790.c:51: error: r8a7790_gpio2_platform_data causes a section type conflict
arch/arm/mach-shmobile/setup-r8a7790.c:52: error: r8a7790_gpio3_resources causes a section type conflict
arch/arm/mach-shmobile/setup-r8a7790.c:52: error: r8a7790_gpio3_platform_data causes a section type conflict
arch/arm/mach-shmobile/setup-r8a7790.c:53: error: r8a7790_gpio4_resources causes a section type conflict
arch/arm/mach-shmobile/setup-r8a7790.c:53: error: r8a7790_gpio4_platform_data causes a section type conflict
arch/arm/mach-shmobile/setup-r8a7790.c:54: error: r8a7790_gpio5_resources causes a section type conflict
arch/arm/mach-shmobile/setup-r8a7790.c:54: error: r8a7790_gpio5_platform_data causes a section type conflict
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-05-27 9:51 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-05-27 0:54 [PATCH 2/2 v3] ARM: shmobile: r8a7790: add __initdata on resource and device data Kuninori Morimoto
2013-05-27 9:51 ` Simon Horman
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).