aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>2010-08-10 17:17:19 -0400
committerRussell King <rmk+kernel@arm.linux.org.uk>2010-08-10 17:46:56 -0400
commit5f6878b0d22f9b93f9698f88c335007e2a3c3bbc (patch)
treecb5ed8d029d8b0a1d499c4431527e97438d79804
parent8436b410806d9a9a8ebfa1b924d8a96da893561a (diff)
ARM: 6323/1: cam60: don't use __init for cam60_spi_{flash_platform_data,partitions}
From: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> To: linux-arm-kernel@lists.infradead.org Subject: [PATCH 12/19] ARM: cam60: don't use __init for cam60_spi_{flash_platform_data,partitions} Date: Thu, 5 Aug 2010 16:08:46 +0200 Message-Id: <1281017333-5563-12-git-send-email-u.kleine-koenig@pengutronix.de> These two structs are referenced by cam60_spi_devices. The latter is copied at init time to kmalloced memory and so the copy isn't freed after booting. So it must not contain references to .init memory. This isn't noticed by modpost as cam60_spi_devices is in .init.data, too. Noticed-and-Acked-by: Andrew Victor <linux@maxim.org.za> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
-rw-r--r--arch/arm/mach-at91/board-cam60.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/arm/mach-at91/board-cam60.c b/arch/arm/mach-at91/board-cam60.c
index 05c70728f041..44eb9f764938 100644
--- a/arch/arm/mach-at91/board-cam60.c
+++ b/arch/arm/mach-at91/board-cam60.c
@@ -75,7 +75,7 @@ static struct at91_usbh_data __initdata cam60_usbh_data = {
75 * SPI devices. 75 * SPI devices.
76 */ 76 */
77#if defined(CONFIG_MTD_DATAFLASH) 77#if defined(CONFIG_MTD_DATAFLASH)
78static struct mtd_partition __initdata cam60_spi_partitions[] = { 78static struct mtd_partition cam60_spi_partitions[] = {
79 { 79 {
80 .name = "BOOT1", 80 .name = "BOOT1",
81 .offset = 0, 81 .offset = 0,
@@ -98,7 +98,7 @@ static struct mtd_partition __initdata cam60_spi_partitions[] = {
98 }, 98 },
99}; 99};
100 100
101static struct flash_platform_data cam60_spi_flash_platform_data __initdata = { 101static struct flash_platform_data cam60_spi_flash_platform_data = {
102 .name = "spi_flash", 102 .name = "spi_flash",
103 .parts = cam60_spi_partitions, 103 .parts = cam60_spi_partitions,
104 .nr_parts = ARRAY_SIZE(cam60_spi_partitions) 104 .nr_parts = ARRAY_SIZE(cam60_spi_partitions)