diff options
43 files changed, 154 insertions, 90 deletions
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index de325f4615bd..4c428dc999ea 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig | |||
| @@ -2312,7 +2312,7 @@ menu "Power management options" | |||
| 2312 | source "kernel/power/Kconfig" | 2312 | source "kernel/power/Kconfig" |
| 2313 | 2313 | ||
| 2314 | config ARCH_SUSPEND_POSSIBLE | 2314 | config ARCH_SUSPEND_POSSIBLE |
| 2315 | depends on !ARCH_S5PC100 && !ARCH_TEGRA | 2315 | depends on !ARCH_S5PC100 |
| 2316 | depends on CPU_ARM920T || CPU_ARM926T || CPU_SA1100 || \ | 2316 | depends on CPU_ARM920T || CPU_ARM926T || CPU_SA1100 || \ |
| 2317 | CPU_V6 || CPU_V6K || CPU_V7 || CPU_XSC3 || CPU_XSCALE || CPU_MOHAWK | 2317 | CPU_V6 || CPU_V6K || CPU_V7 || CPU_XSC3 || CPU_XSCALE || CPU_MOHAWK |
| 2318 | def_bool y | 2318 | def_bool y |
diff --git a/arch/arm/mach-ep93xx/adssphere.c b/arch/arm/mach-ep93xx/adssphere.c index a472777e9eba..41383bf03d4b 100644 --- a/arch/arm/mach-ep93xx/adssphere.c +++ b/arch/arm/mach-ep93xx/adssphere.c | |||
| @@ -13,6 +13,7 @@ | |||
| 13 | #include <linux/kernel.h> | 13 | #include <linux/kernel.h> |
| 14 | #include <linux/init.h> | 14 | #include <linux/init.h> |
| 15 | #include <linux/platform_device.h> | 15 | #include <linux/platform_device.h> |
| 16 | #include <linux/sizes.h> | ||
| 16 | 17 | ||
| 17 | #include <mach/hardware.h> | 18 | #include <mach/hardware.h> |
| 18 | 19 | ||
diff --git a/arch/arm/mach-ep93xx/gesbc9312.c b/arch/arm/mach-ep93xx/gesbc9312.c index 437c34111155..7fd705b5efe4 100644 --- a/arch/arm/mach-ep93xx/gesbc9312.c +++ b/arch/arm/mach-ep93xx/gesbc9312.c | |||
| @@ -13,6 +13,7 @@ | |||
| 13 | #include <linux/kernel.h> | 13 | #include <linux/kernel.h> |
| 14 | #include <linux/init.h> | 14 | #include <linux/init.h> |
| 15 | #include <linux/platform_device.h> | 15 | #include <linux/platform_device.h> |
| 16 | #include <linux/sizes.h> | ||
| 16 | 17 | ||
| 17 | #include <mach/hardware.h> | 18 | #include <mach/hardware.h> |
| 18 | 19 | ||
diff --git a/arch/arm/mach-ep93xx/ts72xx.c b/arch/arm/mach-ep93xx/ts72xx.c index 75cab2d7ec73..3c4c233391dc 100644 --- a/arch/arm/mach-ep93xx/ts72xx.c +++ b/arch/arm/mach-ep93xx/ts72xx.c | |||
| @@ -21,7 +21,6 @@ | |||
| 21 | #include <linux/mtd/partitions.h> | 21 | #include <linux/mtd/partitions.h> |
| 22 | 22 | ||
| 23 | #include <mach/hardware.h> | 23 | #include <mach/hardware.h> |
| 24 | #include <mach/ts72xx.h> | ||
| 25 | 24 | ||
| 26 | #include <asm/hardware/vic.h> | 25 | #include <asm/hardware/vic.h> |
| 27 | #include <asm/mach-types.h> | 26 | #include <asm/mach-types.h> |
| @@ -29,30 +28,31 @@ | |||
| 29 | #include <asm/mach/arch.h> | 28 | #include <asm/mach/arch.h> |
| 30 | 29 | ||
| 31 | #include "soc.h" | 30 | #include "soc.h" |
| 31 | #include "ts72xx.h" | ||
| 32 | 32 | ||
| 33 | static struct map_desc ts72xx_io_desc[] __initdata = { | 33 | static struct map_desc ts72xx_io_desc[] __initdata = { |
| 34 | { | 34 | { |
| 35 | .virtual = TS72XX_MODEL_VIRT_BASE, | 35 | .virtual = (unsigned long)TS72XX_MODEL_VIRT_BASE, |
| 36 | .pfn = __phys_to_pfn(TS72XX_MODEL_PHYS_BASE), | 36 | .pfn = __phys_to_pfn(TS72XX_MODEL_PHYS_BASE), |
| 37 | .length = TS72XX_MODEL_SIZE, | 37 | .length = TS72XX_MODEL_SIZE, |
| 38 | .type = MT_DEVICE, | 38 | .type = MT_DEVICE, |
| 39 | }, { | 39 | }, { |
| 40 | .virtual = TS72XX_OPTIONS_VIRT_BASE, | 40 | .virtual = (unsigned long)TS72XX_OPTIONS_VIRT_BASE, |
| 41 | .pfn = __phys_to_pfn(TS72XX_OPTIONS_PHYS_BASE), | 41 | .pfn = __phys_to_pfn(TS72XX_OPTIONS_PHYS_BASE), |
| 42 | .length = TS72XX_OPTIONS_SIZE, | 42 | .length = TS72XX_OPTIONS_SIZE, |
| 43 | .type = MT_DEVICE, | 43 | .type = MT_DEVICE, |
| 44 | }, { | 44 | }, { |
| 45 | .virtual = TS72XX_OPTIONS2_VIRT_BASE, | 45 | .virtual = (unsigned long)TS72XX_OPTIONS2_VIRT_BASE, |
| 46 | .pfn = __phys_to_pfn(TS72XX_OPTIONS2_PHYS_BASE), | 46 | .pfn = __phys_to_pfn(TS72XX_OPTIONS2_PHYS_BASE), |
| 47 | .length = TS72XX_OPTIONS2_SIZE, | 47 | .length = TS72XX_OPTIONS2_SIZE, |
| 48 | .type = MT_DEVICE, | 48 | .type = MT_DEVICE, |
| 49 | }, { | 49 | }, { |
| 50 | .virtual = TS72XX_RTC_INDEX_VIRT_BASE, | 50 | .virtual = (unsigned long)TS72XX_RTC_INDEX_VIRT_BASE, |
| 51 | .pfn = __phys_to_pfn(TS72XX_RTC_INDEX_PHYS_BASE), | 51 | .pfn = __phys_to_pfn(TS72XX_RTC_INDEX_PHYS_BASE), |
| 52 | .length = TS72XX_RTC_INDEX_SIZE, | 52 | .length = TS72XX_RTC_INDEX_SIZE, |
| 53 | .type = MT_DEVICE, | 53 | .type = MT_DEVICE, |
| 54 | }, { | 54 | }, { |
| 55 | .virtual = TS72XX_RTC_DATA_VIRT_BASE, | 55 | .virtual = (unsigned long)TS72XX_RTC_DATA_VIRT_BASE, |
| 56 | .pfn = __phys_to_pfn(TS72XX_RTC_DATA_PHYS_BASE), | 56 | .pfn = __phys_to_pfn(TS72XX_RTC_DATA_PHYS_BASE), |
| 57 | .length = TS72XX_RTC_DATA_SIZE, | 57 | .length = TS72XX_RTC_DATA_SIZE, |
| 58 | .type = MT_DEVICE, | 58 | .type = MT_DEVICE, |
diff --git a/arch/arm/mach-ep93xx/include/mach/ts72xx.h b/arch/arm/mach-ep93xx/ts72xx.h index f1397a13e76b..071feaa30adc 100644 --- a/arch/arm/mach-ep93xx/include/mach/ts72xx.h +++ b/arch/arm/mach-ep93xx/ts72xx.h | |||
| @@ -14,7 +14,7 @@ | |||
| 14 | */ | 14 | */ |
| 15 | 15 | ||
| 16 | #define TS72XX_MODEL_PHYS_BASE 0x22000000 | 16 | #define TS72XX_MODEL_PHYS_BASE 0x22000000 |
| 17 | #define TS72XX_MODEL_VIRT_BASE 0xfebff000 | 17 | #define TS72XX_MODEL_VIRT_BASE IOMEM(0xfebff000) |
| 18 | #define TS72XX_MODEL_SIZE 0x00001000 | 18 | #define TS72XX_MODEL_SIZE 0x00001000 |
| 19 | 19 | ||
| 20 | #define TS72XX_MODEL_TS7200 0x00 | 20 | #define TS72XX_MODEL_TS7200 0x00 |
| @@ -26,7 +26,7 @@ | |||
| 26 | 26 | ||
| 27 | 27 | ||
| 28 | #define TS72XX_OPTIONS_PHYS_BASE 0x22400000 | 28 | #define TS72XX_OPTIONS_PHYS_BASE 0x22400000 |
| 29 | #define TS72XX_OPTIONS_VIRT_BASE 0xfebfe000 | 29 | #define TS72XX_OPTIONS_VIRT_BASE IOMEM(0xfebfe000) |
| 30 | #define TS72XX_OPTIONS_SIZE 0x00001000 | 30 | #define TS72XX_OPTIONS_SIZE 0x00001000 |
| 31 | 31 | ||
| 32 | #define TS72XX_OPTIONS_COM2_RS485 0x02 | 32 | #define TS72XX_OPTIONS_COM2_RS485 0x02 |
| @@ -34,18 +34,18 @@ | |||
| 34 | 34 | ||
| 35 | 35 | ||
| 36 | #define TS72XX_OPTIONS2_PHYS_BASE 0x22800000 | 36 | #define TS72XX_OPTIONS2_PHYS_BASE 0x22800000 |
| 37 | #define TS72XX_OPTIONS2_VIRT_BASE 0xfebfd000 | 37 | #define TS72XX_OPTIONS2_VIRT_BASE IOMEM(0xfebfd000) |
| 38 | #define TS72XX_OPTIONS2_SIZE 0x00001000 | 38 | #define TS72XX_OPTIONS2_SIZE 0x00001000 |
| 39 | 39 | ||
| 40 | #define TS72XX_OPTIONS2_TS9420 0x04 | 40 | #define TS72XX_OPTIONS2_TS9420 0x04 |
| 41 | #define TS72XX_OPTIONS2_TS9420_BOOT 0x02 | 41 | #define TS72XX_OPTIONS2_TS9420_BOOT 0x02 |
| 42 | 42 | ||
| 43 | 43 | ||
| 44 | #define TS72XX_RTC_INDEX_VIRT_BASE 0xfebf9000 | 44 | #define TS72XX_RTC_INDEX_VIRT_BASE IOMEM(0xfebf9000) |
| 45 | #define TS72XX_RTC_INDEX_PHYS_BASE 0x10800000 | 45 | #define TS72XX_RTC_INDEX_PHYS_BASE 0x10800000 |
| 46 | #define TS72XX_RTC_INDEX_SIZE 0x00001000 | 46 | #define TS72XX_RTC_INDEX_SIZE 0x00001000 |
| 47 | 47 | ||
| 48 | #define TS72XX_RTC_DATA_VIRT_BASE 0xfebf8000 | 48 | #define TS72XX_RTC_DATA_VIRT_BASE IOMEM(0xfebf8000) |
| 49 | #define TS72XX_RTC_DATA_PHYS_BASE 0x11700000 | 49 | #define TS72XX_RTC_DATA_PHYS_BASE 0x11700000 |
| 50 | #define TS72XX_RTC_DATA_SIZE 0x00001000 | 50 | #define TS72XX_RTC_DATA_SIZE 0x00001000 |
| 51 | 51 | ||
diff --git a/arch/arm/mach-exynos/include/mach/map.h b/arch/arm/mach-exynos/include/mach/map.h index c72b675b3e4b..c941053dd5a1 100644 --- a/arch/arm/mach-exynos/include/mach/map.h +++ b/arch/arm/mach-exynos/include/mach/map.h | |||
| @@ -89,7 +89,7 @@ | |||
| 89 | #define EXYNOS4_PA_L2CC 0x10502000 | 89 | #define EXYNOS4_PA_L2CC 0x10502000 |
| 90 | 90 | ||
| 91 | #define EXYNOS4_PA_MDMA0 0x10810000 | 91 | #define EXYNOS4_PA_MDMA0 0x10810000 |
| 92 | #define EXYNOS4_PA_MDMA1 0x12840000 | 92 | #define EXYNOS4_PA_MDMA1 0x12850000 |
| 93 | #define EXYNOS4_PA_PDMA0 0x12680000 | 93 | #define EXYNOS4_PA_PDMA0 0x12680000 |
| 94 | #define EXYNOS4_PA_PDMA1 0x12690000 | 94 | #define EXYNOS4_PA_PDMA1 0x12690000 |
| 95 | #define EXYNOS5_PA_MDMA0 0x10800000 | 95 | #define EXYNOS5_PA_MDMA0 0x10800000 |
diff --git a/arch/arm/mach-exynos/include/mach/sysmmu.h b/arch/arm/mach-exynos/include/mach/sysmmu.h index 998daf2add92..88a4543b0001 100644 --- a/arch/arm/mach-exynos/include/mach/sysmmu.h +++ b/arch/arm/mach-exynos/include/mach/sysmmu.h | |||
| @@ -58,7 +58,7 @@ static inline void platform_set_sysmmu( | |||
| 58 | #endif | 58 | #endif |
| 59 | 59 | ||
| 60 | #else /* !CONFIG_EXYNOS_DEV_SYSMMU */ | 60 | #else /* !CONFIG_EXYNOS_DEV_SYSMMU */ |
| 61 | #define platform_set_sysmmu(dev, sysmmu) do { } while (0) | 61 | #define platform_set_sysmmu(sysmmu, dev) do { } while (0) |
| 62 | #endif | 62 | #endif |
| 63 | 63 | ||
| 64 | #define SYSMMU_CLOCK_DEVNAME(ipname, id) (SYSMMU_DEVNAME_BASE "." #id) | 64 | #define SYSMMU_CLOCK_DEVNAME(ipname, id) (SYSMMU_DEVNAME_BASE "." #id) |
diff --git a/arch/arm/mach-msm/board-msm8x60.c b/arch/arm/mach-msm/board-msm8x60.c index e37a724cd1eb..06003b4ccb10 100644 --- a/arch/arm/mach-msm/board-msm8x60.c +++ b/arch/arm/mach-msm/board-msm8x60.c | |||
| @@ -93,11 +93,6 @@ static struct of_dev_auxdata msm_auxdata_lookup[] __initdata = { | |||
| 93 | 93 | ||
| 94 | static void __init msm8x60_dt_init(void) | 94 | static void __init msm8x60_dt_init(void) |
| 95 | { | 95 | { |
| 96 | if (of_machine_is_compatible("qcom,msm8660-surf")) { | ||
| 97 | printk(KERN_INFO "Init surf UART registers\n"); | ||
| 98 | msm8x60_init_uart12dm(); | ||
| 99 | } | ||
| 100 | |||
| 101 | of_platform_populate(NULL, of_default_bus_match_table, | 96 | of_platform_populate(NULL, of_default_bus_match_table, |
| 102 | msm_auxdata_lookup, NULL); | 97 | msm_auxdata_lookup, NULL); |
| 103 | } | 98 | } |
diff --git a/arch/arm/mach-msm/include/mach/msm_iomap-8960.h b/arch/arm/mach-msm/include/mach/msm_iomap-8960.h index a1752c0284fc..facf434d09be 100644 --- a/arch/arm/mach-msm/include/mach/msm_iomap-8960.h +++ b/arch/arm/mach-msm/include/mach/msm_iomap-8960.h | |||
| @@ -46,7 +46,7 @@ | |||
| 46 | #define MSM8960_TMR0_SIZE SZ_4K | 46 | #define MSM8960_TMR0_SIZE SZ_4K |
| 47 | 47 | ||
| 48 | #ifdef CONFIG_DEBUG_MSM8960_UART | 48 | #ifdef CONFIG_DEBUG_MSM8960_UART |
| 49 | #define MSM_DEBUG_UART_BASE 0xE1040000 | 49 | #define MSM_DEBUG_UART_BASE 0xF0040000 |
| 50 | #define MSM_DEBUG_UART_PHYS 0x16440000 | 50 | #define MSM_DEBUG_UART_PHYS 0x16440000 |
| 51 | #endif | 51 | #endif |
| 52 | 52 | ||
diff --git a/arch/arm/mach-msm/include/mach/msm_iomap-8x60.h b/arch/arm/mach-msm/include/mach/msm_iomap-8x60.h index 5aed57dc808c..21a2a8859a9a 100644 --- a/arch/arm/mach-msm/include/mach/msm_iomap-8x60.h +++ b/arch/arm/mach-msm/include/mach/msm_iomap-8x60.h | |||
| @@ -63,7 +63,7 @@ | |||
| 63 | #define MSM8X60_TMR0_SIZE SZ_4K | 63 | #define MSM8X60_TMR0_SIZE SZ_4K |
| 64 | 64 | ||
| 65 | #ifdef CONFIG_DEBUG_MSM8660_UART | 65 | #ifdef CONFIG_DEBUG_MSM8660_UART |
| 66 | #define MSM_DEBUG_UART_BASE 0xE1040000 | 66 | #define MSM_DEBUG_UART_BASE 0xF0040000 |
| 67 | #define MSM_DEBUG_UART_PHYS 0x19C40000 | 67 | #define MSM_DEBUG_UART_PHYS 0x19C40000 |
| 68 | #endif | 68 | #endif |
| 69 | 69 | ||
diff --git a/arch/arm/mach-msm/io.c b/arch/arm/mach-msm/io.c index a1e7b1168850..af43f6acd7fc 100644 --- a/arch/arm/mach-msm/io.c +++ b/arch/arm/mach-msm/io.c | |||
| @@ -29,30 +29,31 @@ | |||
| 29 | 29 | ||
| 30 | #include <mach/board.h> | 30 | #include <mach/board.h> |
| 31 | 31 | ||
| 32 | #define MSM_CHIP_DEVICE(name, chip) { \ | 32 | #define MSM_CHIP_DEVICE_TYPE(name, chip, mem_type) { \ |
| 33 | .virtual = (unsigned long) MSM_##name##_BASE, \ | 33 | .virtual = (unsigned long) MSM_##name##_BASE, \ |
| 34 | .pfn = __phys_to_pfn(chip##_##name##_PHYS), \ | 34 | .pfn = __phys_to_pfn(chip##_##name##_PHYS), \ |
| 35 | .length = chip##_##name##_SIZE, \ | 35 | .length = chip##_##name##_SIZE, \ |
| 36 | .type = MT_DEVICE_NONSHARED, \ | 36 | .type = mem_type, \ |
| 37 | } | 37 | } |
| 38 | 38 | ||
| 39 | #define MSM_DEVICE_TYPE(name, mem_type) \ | ||
| 40 | MSM_CHIP_DEVICE_TYPE(name, MSM, mem_type) | ||
| 41 | #define MSM_CHIP_DEVICE(name, chip) \ | ||
| 42 | MSM_CHIP_DEVICE_TYPE(name, chip, MT_DEVICE) | ||
| 39 | #define MSM_DEVICE(name) MSM_CHIP_DEVICE(name, MSM) | 43 | #define MSM_DEVICE(name) MSM_CHIP_DEVICE(name, MSM) |
| 40 | 44 | ||
| 41 | #if defined(CONFIG_ARCH_MSM7X00A) || defined(CONFIG_ARCH_MSM7X27) \ | 45 | #if defined(CONFIG_ARCH_MSM7X00A) || defined(CONFIG_ARCH_MSM7X27) \ |
| 42 | || defined(CONFIG_ARCH_MSM7X25) | 46 | || defined(CONFIG_ARCH_MSM7X25) |
| 43 | static struct map_desc msm_io_desc[] __initdata = { | 47 | static struct map_desc msm_io_desc[] __initdata = { |
| 44 | MSM_DEVICE(VIC), | 48 | MSM_DEVICE_TYPE(VIC, MT_DEVICE_NONSHARED), |
| 45 | MSM_CHIP_DEVICE(CSR, MSM7X00), | 49 | MSM_CHIP_DEVICE_TYPE(CSR, MSM7X00, MT_DEVICE_NONSHARED), |
| 46 | MSM_DEVICE(DMOV), | 50 | MSM_DEVICE_TYPE(DMOV, MT_DEVICE_NONSHARED), |
| 47 | MSM_CHIP_DEVICE(GPIO1, MSM7X00), | 51 | MSM_CHIP_DEVICE_TYPE(GPIO1, MSM7X00, MT_DEVICE_NONSHARED), |
| 48 | MSM_CHIP_DEVICE(GPIO2, MSM7X00), | 52 | MSM_CHIP_DEVICE_TYPE(GPIO2, MSM7X00, MT_DEVICE_NONSHARED), |
| 49 | MSM_DEVICE(CLK_CTL), | 53 | MSM_DEVICE_TYPE(CLK_CTL, MT_DEVICE_NONSHARED), |
| 50 | #if defined(CONFIG_DEBUG_MSM_UART1) || defined(CONFIG_DEBUG_MSM_UART2) || \ | 54 | #if defined(CONFIG_DEBUG_MSM_UART1) || defined(CONFIG_DEBUG_MSM_UART2) || \ |
| 51 | defined(CONFIG_DEBUG_MSM_UART3) | 55 | defined(CONFIG_DEBUG_MSM_UART3) |
| 52 | MSM_DEVICE(DEBUG_UART), | 56 | MSM_DEVICE_TYPE(DEBUG_UART, MT_DEVICE_NONSHARED), |
| 53 | #endif | ||
| 54 | #ifdef CONFIG_ARCH_MSM7X30 | ||
| 55 | MSM_DEVICE(GCC), | ||
| 56 | #endif | 57 | #endif |
| 57 | { | 58 | { |
| 58 | .virtual = (unsigned long) MSM_SHARED_RAM_BASE, | 59 | .virtual = (unsigned long) MSM_SHARED_RAM_BASE, |
diff --git a/arch/arm/mach-nomadik/board-nhk8815.c b/arch/arm/mach-nomadik/board-nhk8815.c index f4535a7dadf5..c3841a9a8fa8 100644 --- a/arch/arm/mach-nomadik/board-nhk8815.c +++ b/arch/arm/mach-nomadik/board-nhk8815.c | |||
| @@ -112,8 +112,7 @@ static struct mtd_partition nhk8815_partitions[] = { | |||
| 112 | static struct nomadik_nand_platform_data nhk8815_nand_data = { | 112 | static struct nomadik_nand_platform_data nhk8815_nand_data = { |
| 113 | .parts = nhk8815_partitions, | 113 | .parts = nhk8815_partitions, |
| 114 | .nparts = ARRAY_SIZE(nhk8815_partitions), | 114 | .nparts = ARRAY_SIZE(nhk8815_partitions), |
| 115 | .options = NAND_COPYBACK | NAND_CACHEPRG | NAND_NO_PADDING \ | 115 | .options = NAND_COPYBACK | NAND_CACHEPRG | NAND_NO_PADDING, |
| 116 | | NAND_NO_READRDY, | ||
| 117 | .init = nhk8815_nand_init, | 116 | .init = nhk8815_nand_init, |
| 118 | }; | 117 | }; |
| 119 | 118 | ||
diff --git a/arch/arm/mach-omap2/gpio.c b/arch/arm/mach-omap2/gpio.c index 9ad7d489b0de..fe626e903dea 100644 --- a/arch/arm/mach-omap2/gpio.c +++ b/arch/arm/mach-omap2/gpio.c | |||
| @@ -60,6 +60,7 @@ static int __init omap2_gpio_dev_init(struct omap_hwmod *oh, void *unused) | |||
| 60 | pdata->regs = kzalloc(sizeof(struct omap_gpio_reg_offs), GFP_KERNEL); | 60 | pdata->regs = kzalloc(sizeof(struct omap_gpio_reg_offs), GFP_KERNEL); |
| 61 | if (!pdata->regs) { | 61 | if (!pdata->regs) { |
| 62 | pr_err("gpio%d: Memory allocation failed\n", id); | 62 | pr_err("gpio%d: Memory allocation failed\n", id); |
| 63 | kfree(pdata); | ||
| 63 | return -ENOMEM; | 64 | return -ENOMEM; |
| 64 | } | 65 | } |
| 65 | 66 | ||
| @@ -121,6 +122,7 @@ static int __init omap2_gpio_dev_init(struct omap_hwmod *oh, void *unused) | |||
| 121 | break; | 122 | break; |
| 122 | default: | 123 | default: |
| 123 | WARN(1, "Invalid gpio bank_type\n"); | 124 | WARN(1, "Invalid gpio bank_type\n"); |
| 125 | kfree(pdata->regs); | ||
| 124 | kfree(pdata); | 126 | kfree(pdata); |
| 125 | return -EINVAL; | 127 | return -EINVAL; |
| 126 | } | 128 | } |
diff --git a/arch/arm/mach-omap2/omap-wakeupgen.c b/arch/arm/mach-omap2/omap-wakeupgen.c index 330d4c6e746b..c4bee21f4210 100644 --- a/arch/arm/mach-omap2/omap-wakeupgen.c +++ b/arch/arm/mach-omap2/omap-wakeupgen.c | |||
| @@ -229,13 +229,7 @@ static inline void omap4_irq_save_context(void) | |||
| 229 | /* Save AuxBoot* registers */ | 229 | /* Save AuxBoot* registers */ |
| 230 | val = __raw_readl(wakeupgen_base + OMAP_AUX_CORE_BOOT_0); | 230 | val = __raw_readl(wakeupgen_base + OMAP_AUX_CORE_BOOT_0); |
| 231 | __raw_writel(val, sar_base + AUXCOREBOOT0_OFFSET); | 231 | __raw_writel(val, sar_base + AUXCOREBOOT0_OFFSET); |
| 232 | val = __raw_readl(wakeupgen_base + OMAP_AUX_CORE_BOOT_0); | 232 | val = __raw_readl(wakeupgen_base + OMAP_AUX_CORE_BOOT_1); |
| 233 | __raw_writel(val, sar_base + AUXCOREBOOT1_OFFSET); | ||
| 234 | |||
| 235 | /* Save SyncReq generation logic */ | ||
| 236 | val = __raw_readl(wakeupgen_base + OMAP_AUX_CORE_BOOT_0); | ||
| 237 | __raw_writel(val, sar_base + AUXCOREBOOT0_OFFSET); | ||
| 238 | val = __raw_readl(wakeupgen_base + OMAP_AUX_CORE_BOOT_0); | ||
| 239 | __raw_writel(val, sar_base + AUXCOREBOOT1_OFFSET); | 233 | __raw_writel(val, sar_base + AUXCOREBOOT1_OFFSET); |
| 240 | 234 | ||
| 241 | /* Save SyncReq generation logic */ | 235 | /* Save SyncReq generation logic */ |
diff --git a/arch/arm/mach-s3c24xx/mach-h1940.c b/arch/arm/mach-s3c24xx/mach-h1940.c index bb8d008d5a5c..7e15cc430688 100644 --- a/arch/arm/mach-s3c24xx/mach-h1940.c +++ b/arch/arm/mach-s3c24xx/mach-h1940.c | |||
| @@ -380,7 +380,7 @@ int h1940_led_blink_set(unsigned gpio, int state, | |||
| 380 | default: | 380 | default: |
| 381 | blink_gpio = S3C2410_GPA(3); | 381 | blink_gpio = S3C2410_GPA(3); |
| 382 | check_gpio1 = S3C2410_GPA(1); | 382 | check_gpio1 = S3C2410_GPA(1); |
| 383 | check_gpio1 = S3C2410_GPA(7); | 383 | check_gpio2 = S3C2410_GPA(7); |
| 384 | break; | 384 | break; |
| 385 | } | 385 | } |
| 386 | 386 | ||
| @@ -460,7 +460,7 @@ static void h1940_set_mmc_power(unsigned char power_mode, unsigned short vdd) | |||
| 460 | break; | 460 | break; |
| 461 | default: | 461 | default: |
| 462 | break; | 462 | break; |
| 463 | }; | 463 | } |
| 464 | } | 464 | } |
| 465 | 465 | ||
| 466 | static struct s3c24xx_mci_pdata h1940_mmc_cfg __initdata = { | 466 | static struct s3c24xx_mci_pdata h1940_mmc_cfg __initdata = { |
diff --git a/arch/arm/mach-tegra/powergate.c b/arch/arm/mach-tegra/powergate.c index 15d506501ccc..de0662de28a0 100644 --- a/arch/arm/mach-tegra/powergate.c +++ b/arch/arm/mach-tegra/powergate.c | |||
| @@ -199,7 +199,9 @@ int __init tegra_powergate_init(void) | |||
| 199 | 199 | ||
| 200 | #ifdef CONFIG_DEBUG_FS | 200 | #ifdef CONFIG_DEBUG_FS |
| 201 | 201 | ||
| 202 | static const char * const powergate_name[] = { | 202 | static const char * const *powergate_name; |
| 203 | |||
| 204 | static const char * const powergate_name_t20[] = { | ||
| 203 | [TEGRA_POWERGATE_CPU] = "cpu", | 205 | [TEGRA_POWERGATE_CPU] = "cpu", |
| 204 | [TEGRA_POWERGATE_3D] = "3d", | 206 | [TEGRA_POWERGATE_3D] = "3d", |
| 205 | [TEGRA_POWERGATE_VENC] = "venc", | 207 | [TEGRA_POWERGATE_VENC] = "venc", |
| @@ -209,6 +211,23 @@ static const char * const powergate_name[] = { | |||
| 209 | [TEGRA_POWERGATE_MPE] = "mpe", | 211 | [TEGRA_POWERGATE_MPE] = "mpe", |
| 210 | }; | 212 | }; |
| 211 | 213 | ||
| 214 | static const char * const powergate_name_t30[] = { | ||
| 215 | [TEGRA_POWERGATE_CPU] = "cpu0", | ||
| 216 | [TEGRA_POWERGATE_3D] = "3d0", | ||
| 217 | [TEGRA_POWERGATE_VENC] = "venc", | ||
| 218 | [TEGRA_POWERGATE_VDEC] = "vdec", | ||
| 219 | [TEGRA_POWERGATE_PCIE] = "pcie", | ||
| 220 | [TEGRA_POWERGATE_L2] = "l2", | ||
| 221 | [TEGRA_POWERGATE_MPE] = "mpe", | ||
| 222 | [TEGRA_POWERGATE_HEG] = "heg", | ||
| 223 | [TEGRA_POWERGATE_SATA] = "sata", | ||
| 224 | [TEGRA_POWERGATE_CPU1] = "cpu1", | ||
| 225 | [TEGRA_POWERGATE_CPU2] = "cpu2", | ||
| 226 | [TEGRA_POWERGATE_CPU3] = "cpu3", | ||
| 227 | [TEGRA_POWERGATE_CELP] = "celp", | ||
| 228 | [TEGRA_POWERGATE_3D1] = "3d1", | ||
| 229 | }; | ||
| 230 | |||
| 212 | static int powergate_show(struct seq_file *s, void *data) | 231 | static int powergate_show(struct seq_file *s, void *data) |
| 213 | { | 232 | { |
| 214 | int i; | 233 | int i; |
| @@ -237,14 +256,24 @@ static const struct file_operations powergate_fops = { | |||
| 237 | int __init tegra_powergate_debugfs_init(void) | 256 | int __init tegra_powergate_debugfs_init(void) |
| 238 | { | 257 | { |
| 239 | struct dentry *d; | 258 | struct dentry *d; |
| 240 | int err = -ENOMEM; | ||
| 241 | 259 | ||
| 242 | d = debugfs_create_file("powergate", S_IRUGO, NULL, NULL, | 260 | switch (tegra_chip_id) { |
| 243 | &powergate_fops); | 261 | case TEGRA20: |
| 244 | if (!d) | 262 | powergate_name = powergate_name_t20; |
| 245 | return -ENOMEM; | 263 | break; |
| 264 | case TEGRA30: | ||
| 265 | powergate_name = powergate_name_t30; | ||
| 266 | break; | ||
| 267 | } | ||
| 268 | |||
| 269 | if (powergate_name) { | ||
| 270 | d = debugfs_create_file("powergate", S_IRUGO, NULL, NULL, | ||
| 271 | &powergate_fops); | ||
| 272 | if (!d) | ||
| 273 | return -ENOMEM; | ||
| 274 | } | ||
| 246 | 275 | ||
| 247 | return err; | 276 | return 0; |
| 248 | } | 277 | } |
| 249 | 278 | ||
| 250 | #endif | 279 | #endif |
diff --git a/arch/arm/mach-ux500/Kconfig b/arch/arm/mach-ux500/Kconfig index a258996d954b..c77c86c47369 100644 --- a/arch/arm/mach-ux500/Kconfig +++ b/arch/arm/mach-ux500/Kconfig | |||
| @@ -29,6 +29,7 @@ config MACH_MOP500 | |||
| 29 | select I2C | 29 | select I2C |
| 30 | select I2C_NOMADIK | 30 | select I2C_NOMADIK |
| 31 | select SOC_BUS | 31 | select SOC_BUS |
| 32 | select REGULATOR_FIXED_VOLTAGE | ||
| 32 | help | 33 | help |
| 33 | Include support for the MOP500 development platform. | 34 | Include support for the MOP500 development platform. |
| 34 | 35 | ||
diff --git a/arch/arm/mach-ux500/board-mop500-regulators.c b/arch/arm/mach-ux500/board-mop500-regulators.c index 52426a425787..2a17bc506cff 100644 --- a/arch/arm/mach-ux500/board-mop500-regulators.c +++ b/arch/arm/mach-ux500/board-mop500-regulators.c | |||
| @@ -13,6 +13,21 @@ | |||
| 13 | #include <linux/regulator/ab8500.h> | 13 | #include <linux/regulator/ab8500.h> |
| 14 | #include "board-mop500-regulators.h" | 14 | #include "board-mop500-regulators.h" |
| 15 | 15 | ||
| 16 | static struct regulator_consumer_supply gpio_en_3v3_consumers[] = { | ||
| 17 | REGULATOR_SUPPLY("vdd33a", "smsc911x.0"), | ||
| 18 | }; | ||
| 19 | |||
| 20 | struct regulator_init_data gpio_en_3v3_regulator = { | ||
| 21 | .constraints = { | ||
| 22 | .name = "EN-3V3", | ||
| 23 | .min_uV = 3300000, | ||
| 24 | .max_uV = 3300000, | ||
| 25 | .valid_ops_mask = REGULATOR_CHANGE_STATUS, | ||
| 26 | }, | ||
| 27 | .num_consumer_supplies = ARRAY_SIZE(gpio_en_3v3_consumers), | ||
| 28 | .consumer_supplies = gpio_en_3v3_consumers, | ||
| 29 | }; | ||
| 30 | |||
| 16 | /* | 31 | /* |
| 17 | * TPS61052 regulator | 32 | * TPS61052 regulator |
| 18 | */ | 33 | */ |
diff --git a/arch/arm/mach-ux500/board-mop500-regulators.h b/arch/arm/mach-ux500/board-mop500-regulators.h index 94992158d962..78a0642a2206 100644 --- a/arch/arm/mach-ux500/board-mop500-regulators.h +++ b/arch/arm/mach-ux500/board-mop500-regulators.h | |||
| @@ -18,5 +18,6 @@ extern struct ab8500_regulator_reg_init | |||
| 18 | ab8500_regulator_reg_init[AB8500_NUM_REGULATOR_REGISTERS]; | 18 | ab8500_regulator_reg_init[AB8500_NUM_REGULATOR_REGISTERS]; |
| 19 | extern struct regulator_init_data ab8500_regulators[AB8500_NUM_REGULATORS]; | 19 | extern struct regulator_init_data ab8500_regulators[AB8500_NUM_REGULATORS]; |
| 20 | extern struct regulator_init_data tps61052_regulator; | 20 | extern struct regulator_init_data tps61052_regulator; |
| 21 | extern struct regulator_init_data gpio_en_3v3_regulator; | ||
| 21 | 22 | ||
| 22 | #endif | 23 | #endif |
diff --git a/arch/arm/mach-ux500/board-mop500.c b/arch/arm/mach-ux500/board-mop500.c index 1d2e3c6f8b59..c8922bca68a4 100644 --- a/arch/arm/mach-ux500/board-mop500.c +++ b/arch/arm/mach-ux500/board-mop500.c | |||
| @@ -23,6 +23,7 @@ | |||
| 23 | #include <linux/spi/spi.h> | 23 | #include <linux/spi/spi.h> |
| 24 | #include <linux/mfd/abx500/ab8500.h> | 24 | #include <linux/mfd/abx500/ab8500.h> |
| 25 | #include <linux/regulator/ab8500.h> | 25 | #include <linux/regulator/ab8500.h> |
| 26 | #include <linux/regulator/fixed.h> | ||
| 26 | #include <linux/mfd/tc3589x.h> | 27 | #include <linux/mfd/tc3589x.h> |
| 27 | #include <linux/mfd/tps6105x.h> | 28 | #include <linux/mfd/tps6105x.h> |
| 28 | #include <linux/mfd/abx500/ab8500-gpio.h> | 29 | #include <linux/mfd/abx500/ab8500-gpio.h> |
| @@ -76,6 +77,23 @@ static struct platform_device snowball_led_dev = { | |||
| 76 | }, | 77 | }, |
| 77 | }; | 78 | }; |
| 78 | 79 | ||
| 80 | static struct fixed_voltage_config snowball_gpio_en_3v3_data = { | ||
| 81 | .supply_name = "EN-3V3", | ||
| 82 | .gpio = SNOWBALL_EN_3V3_ETH_GPIO, | ||
| 83 | .microvolts = 3300000, | ||
| 84 | .enable_high = 1, | ||
| 85 | .init_data = &gpio_en_3v3_regulator, | ||
| 86 | .startup_delay = 5000, /* 1200us */ | ||
| 87 | }; | ||
| 88 | |||
| 89 | static struct platform_device snowball_gpio_en_3v3_regulator_dev = { | ||
| 90 | .name = "reg-fixed-voltage", | ||
| 91 | .id = 1, | ||
| 92 | .dev = { | ||
| 93 | .platform_data = &snowball_gpio_en_3v3_data, | ||
| 94 | }, | ||
| 95 | }; | ||
| 96 | |||
| 79 | static struct ab8500_gpio_platform_data ab8500_gpio_pdata = { | 97 | static struct ab8500_gpio_platform_data ab8500_gpio_pdata = { |
| 80 | .gpio_base = MOP500_AB8500_PIN_GPIO(1), | 98 | .gpio_base = MOP500_AB8500_PIN_GPIO(1), |
| 81 | .irq_base = MOP500_AB8500_VIR_GPIO_IRQ_BASE, | 99 | .irq_base = MOP500_AB8500_VIR_GPIO_IRQ_BASE, |
| @@ -565,6 +583,7 @@ static struct platform_device *snowball_platform_devs[] __initdata = { | |||
| 565 | &snowball_led_dev, | 583 | &snowball_led_dev, |
| 566 | &snowball_key_dev, | 584 | &snowball_key_dev, |
| 567 | &snowball_sbnet_dev, | 585 | &snowball_sbnet_dev, |
| 586 | &snowball_gpio_en_3v3_regulator_dev, | ||
| 568 | }; | 587 | }; |
| 569 | 588 | ||
| 570 | static void __init mop500_init_machine(void) | 589 | static void __init mop500_init_machine(void) |
diff --git a/arch/arm/mach-ux500/cpu-db8500.c b/arch/arm/mach-ux500/cpu-db8500.c index db3c52d56ca4..4e59746bcff4 100644 --- a/arch/arm/mach-ux500/cpu-db8500.c +++ b/arch/arm/mach-ux500/cpu-db8500.c | |||
| @@ -18,6 +18,7 @@ | |||
| 18 | #include <linux/io.h> | 18 | #include <linux/io.h> |
| 19 | #include <linux/mfd/abx500/ab8500.h> | 19 | #include <linux/mfd/abx500/ab8500.h> |
| 20 | 20 | ||
| 21 | #include <asm/pmu.h> | ||
| 21 | #include <asm/mach/map.h> | 22 | #include <asm/mach/map.h> |
| 22 | #include <asm/pmu.h> | 23 | #include <asm/pmu.h> |
| 23 | #include <plat/gpio-nomadik.h> | 24 | #include <plat/gpio-nomadik.h> |
diff --git a/arch/arm/mach-ux500/cpu.c b/arch/arm/mach-ux500/cpu.c index 17a78ec516ff..8e755638aa76 100644 --- a/arch/arm/mach-ux500/cpu.c +++ b/arch/arm/mach-ux500/cpu.c | |||
| @@ -49,6 +49,8 @@ void __init ux500_init_irq(void) | |||
| 49 | void __iomem *dist_base; | 49 | void __iomem *dist_base; |
| 50 | void __iomem *cpu_base; | 50 | void __iomem *cpu_base; |
| 51 | 51 | ||
| 52 | gic_arch_extn.flags = IRQCHIP_SKIP_SET_WAKE | IRQCHIP_MASK_ON_SUSPEND; | ||
| 53 | |||
| 52 | if (cpu_is_u8500_family()) { | 54 | if (cpu_is_u8500_family()) { |
| 53 | dist_base = __io_address(U8500_GIC_DIST_BASE); | 55 | dist_base = __io_address(U8500_GIC_DIST_BASE); |
| 54 | cpu_base = __io_address(U8500_GIC_CPU_BASE); | 56 | cpu_base = __io_address(U8500_GIC_CPU_BASE); |
diff --git a/arch/arm/mm/cache-l2x0.c b/arch/arm/mm/cache-l2x0.c index 2a8e380501e8..577baf7d0a8d 100644 --- a/arch/arm/mm/cache-l2x0.c +++ b/arch/arm/mm/cache-l2x0.c | |||
| @@ -554,7 +554,7 @@ static const struct of_device_id l2x0_ids[] __initconst = { | |||
| 554 | int __init l2x0_of_init(u32 aux_val, u32 aux_mask) | 554 | int __init l2x0_of_init(u32 aux_val, u32 aux_mask) |
| 555 | { | 555 | { |
| 556 | struct device_node *np; | 556 | struct device_node *np; |
| 557 | struct l2x0_of_data *data; | 557 | const struct l2x0_of_data *data; |
| 558 | struct resource res; | 558 | struct resource res; |
| 559 | 559 | ||
| 560 | np = of_find_matching_node(NULL, l2x0_ids); | 560 | np = of_find_matching_node(NULL, l2x0_ids); |
diff --git a/arch/arm/plat-samsung/devs.c b/arch/arm/plat-samsung/devs.c index fc49f3dabd76..2195209aa543 100644 --- a/arch/arm/plat-samsung/devs.c +++ b/arch/arm/plat-samsung/devs.c | |||
| @@ -1591,6 +1591,8 @@ struct platform_device s3c64xx_device_spi1 = { | |||
| 1591 | void __init s3c64xx_spi1_set_platdata(int (*cfg_gpio)(void), int src_clk_nr, | 1591 | void __init s3c64xx_spi1_set_platdata(int (*cfg_gpio)(void), int src_clk_nr, |
| 1592 | int num_cs) | 1592 | int num_cs) |
| 1593 | { | 1593 | { |
| 1594 | struct s3c64xx_spi_info pd; | ||
| 1595 | |||
| 1594 | /* Reject invalid configuration */ | 1596 | /* Reject invalid configuration */ |
| 1595 | if (!num_cs || src_clk_nr < 0) { | 1597 | if (!num_cs || src_clk_nr < 0) { |
| 1596 | pr_err("%s: Invalid SPI configuration\n", __func__); | 1598 | pr_err("%s: Invalid SPI configuration\n", __func__); |
diff --git a/arch/powerpc/platforms/83xx/suspend.c b/arch/powerpc/platforms/83xx/suspend.c index 1a046715e461..1d769a29249f 100644 --- a/arch/powerpc/platforms/83xx/suspend.c +++ b/arch/powerpc/platforms/83xx/suspend.c | |||
| @@ -326,7 +326,7 @@ static int pmc_probe(struct platform_device *ofdev) | |||
| 326 | const struct of_device_id *match; | 326 | const struct of_device_id *match; |
| 327 | struct device_node *np = ofdev->dev.of_node; | 327 | struct device_node *np = ofdev->dev.of_node; |
| 328 | struct resource res; | 328 | struct resource res; |
| 329 | struct pmc_type *type; | 329 | const struct pmc_type *type; |
| 330 | int ret = 0; | 330 | int ret = 0; |
| 331 | 331 | ||
| 332 | match = of_match_device(pmc_match, &ofdev->dev); | 332 | match = of_match_device(pmc_match, &ofdev->dev); |
diff --git a/arch/powerpc/platforms/cell/celleb_pci.c b/arch/powerpc/platforms/cell/celleb_pci.c index 5822141aa63f..abc8af43ea7c 100644 --- a/arch/powerpc/platforms/cell/celleb_pci.c +++ b/arch/powerpc/platforms/cell/celleb_pci.c | |||
| @@ -472,7 +472,7 @@ int __init celleb_setup_phb(struct pci_controller *phb) | |||
| 472 | { | 472 | { |
| 473 | struct device_node *dev = phb->dn; | 473 | struct device_node *dev = phb->dn; |
| 474 | const struct of_device_id *match; | 474 | const struct of_device_id *match; |
| 475 | struct celleb_phb_spec *phb_spec; | 475 | const struct celleb_phb_spec *phb_spec; |
| 476 | int rc; | 476 | int rc; |
| 477 | 477 | ||
| 478 | match = of_match_node(celleb_phb_match, dev); | 478 | match = of_match_node(celleb_phb_match, dev); |
diff --git a/arch/powerpc/sysdev/fsl_msi.c b/arch/powerpc/sysdev/fsl_msi.c index 6e097de00e09..51ffafae561e 100644 --- a/arch/powerpc/sysdev/fsl_msi.c +++ b/arch/powerpc/sysdev/fsl_msi.c | |||
| @@ -368,7 +368,7 @@ static int __devinit fsl_of_msi_probe(struct platform_device *dev) | |||
| 368 | int err, i, j, irq_index, count; | 368 | int err, i, j, irq_index, count; |
| 369 | int rc; | 369 | int rc; |
| 370 | const u32 *p; | 370 | const u32 *p; |
| 371 | struct fsl_msi_feature *features; | 371 | const struct fsl_msi_feature *features; |
| 372 | int len; | 372 | int len; |
| 373 | u32 offset; | 373 | u32 offset; |
| 374 | static const u32 all_avail[] = { 0, NR_MSI_IRQS }; | 374 | static const u32 all_avail[] = { 0, NR_MSI_IRQS }; |
| @@ -502,15 +502,15 @@ static const struct fsl_msi_feature vmpic_msi_feature = { | |||
| 502 | static const struct of_device_id fsl_of_msi_ids[] = { | 502 | static const struct of_device_id fsl_of_msi_ids[] = { |
| 503 | { | 503 | { |
| 504 | .compatible = "fsl,mpic-msi", | 504 | .compatible = "fsl,mpic-msi", |
| 505 | .data = (void *)&mpic_msi_feature, | 505 | .data = &mpic_msi_feature, |
| 506 | }, | 506 | }, |
| 507 | { | 507 | { |
| 508 | .compatible = "fsl,ipic-msi", | 508 | .compatible = "fsl,ipic-msi", |
| 509 | .data = (void *)&ipic_msi_feature, | 509 | .data = &ipic_msi_feature, |
| 510 | }, | 510 | }, |
| 511 | { | 511 | { |
| 512 | .compatible = "fsl,vmpic-msi", | 512 | .compatible = "fsl,vmpic-msi", |
| 513 | .data = (void *)&vmpic_msi_feature, | 513 | .data = &vmpic_msi_feature, |
| 514 | }, | 514 | }, |
| 515 | {} | 515 | {} |
| 516 | }; | 516 | }; |
diff --git a/drivers/dma/tegra20-apb-dma.c b/drivers/dma/tegra20-apb-dma.c index 24acd711e032..4708467e4d83 100644 --- a/drivers/dma/tegra20-apb-dma.c +++ b/drivers/dma/tegra20-apb-dma.c | |||
| @@ -201,7 +201,7 @@ struct tegra_dma { | |||
| 201 | struct clk *dma_clk; | 201 | struct clk *dma_clk; |
| 202 | spinlock_t global_lock; | 202 | spinlock_t global_lock; |
| 203 | void __iomem *base_addr; | 203 | void __iomem *base_addr; |
| 204 | struct tegra_dma_chip_data *chip_data; | 204 | const struct tegra_dma_chip_data *chip_data; |
| 205 | 205 | ||
| 206 | /* Some register need to be cache before suspend */ | 206 | /* Some register need to be cache before suspend */ |
| 207 | u32 reg_gen; | 207 | u32 reg_gen; |
| @@ -1173,14 +1173,14 @@ static void tegra_dma_free_chan_resources(struct dma_chan *dc) | |||
| 1173 | } | 1173 | } |
| 1174 | 1174 | ||
| 1175 | /* Tegra20 specific DMA controller information */ | 1175 | /* Tegra20 specific DMA controller information */ |
| 1176 | static struct tegra_dma_chip_data tegra20_dma_chip_data = { | 1176 | static const struct tegra_dma_chip_data tegra20_dma_chip_data = { |
| 1177 | .nr_channels = 16, | 1177 | .nr_channels = 16, |
| 1178 | .max_dma_count = 1024UL * 64, | 1178 | .max_dma_count = 1024UL * 64, |
| 1179 | }; | 1179 | }; |
| 1180 | 1180 | ||
| 1181 | #if defined(CONFIG_OF) | 1181 | #if defined(CONFIG_OF) |
| 1182 | /* Tegra30 specific DMA controller information */ | 1182 | /* Tegra30 specific DMA controller information */ |
| 1183 | static struct tegra_dma_chip_data tegra30_dma_chip_data = { | 1183 | static const struct tegra_dma_chip_data tegra30_dma_chip_data = { |
| 1184 | .nr_channels = 32, | 1184 | .nr_channels = 32, |
| 1185 | .max_dma_count = 1024UL * 64, | 1185 | .max_dma_count = 1024UL * 64, |
| 1186 | }; | 1186 | }; |
| @@ -1204,7 +1204,7 @@ static int __devinit tegra_dma_probe(struct platform_device *pdev) | |||
| 1204 | struct tegra_dma *tdma; | 1204 | struct tegra_dma *tdma; |
| 1205 | int ret; | 1205 | int ret; |
| 1206 | int i; | 1206 | int i; |
| 1207 | struct tegra_dma_chip_data *cdata = NULL; | 1207 | const struct tegra_dma_chip_data *cdata = NULL; |
| 1208 | 1208 | ||
| 1209 | if (pdev->dev.of_node) { | 1209 | if (pdev->dev.of_node) { |
| 1210 | const struct of_device_id *match; | 1210 | const struct of_device_id *match; |
diff --git a/drivers/gpio/gpio-mpc8xxx.c b/drivers/gpio/gpio-mpc8xxx.c index 5a1817eedd1b..9ae29cc0d17f 100644 --- a/drivers/gpio/gpio-mpc8xxx.c +++ b/drivers/gpio/gpio-mpc8xxx.c | |||
| @@ -38,7 +38,7 @@ struct mpc8xxx_gpio_chip { | |||
| 38 | */ | 38 | */ |
| 39 | u32 data; | 39 | u32 data; |
| 40 | struct irq_domain *irq; | 40 | struct irq_domain *irq; |
| 41 | void *of_dev_id_data; | 41 | const void *of_dev_id_data; |
| 42 | }; | 42 | }; |
| 43 | 43 | ||
| 44 | static inline u32 mpc8xxx_gpio2mask(unsigned int gpio) | 44 | static inline u32 mpc8xxx_gpio2mask(unsigned int gpio) |
diff --git a/drivers/gpio/gpio-omap.c b/drivers/gpio/gpio-omap.c index e6efd77668f0..0725d181581f 100644 --- a/drivers/gpio/gpio-omap.c +++ b/drivers/gpio/gpio-omap.c | |||
| @@ -1058,7 +1058,7 @@ static int __devinit omap_gpio_probe(struct platform_device *pdev) | |||
| 1058 | struct device *dev = &pdev->dev; | 1058 | struct device *dev = &pdev->dev; |
| 1059 | struct device_node *node = dev->of_node; | 1059 | struct device_node *node = dev->of_node; |
| 1060 | const struct of_device_id *match; | 1060 | const struct of_device_id *match; |
| 1061 | struct omap_gpio_platform_data *pdata; | 1061 | const struct omap_gpio_platform_data *pdata; |
| 1062 | struct resource *res; | 1062 | struct resource *res; |
| 1063 | struct gpio_bank *bank; | 1063 | struct gpio_bank *bank; |
| 1064 | int ret = 0; | 1064 | int ret = 0; |
| @@ -1440,19 +1440,19 @@ static struct omap_gpio_reg_offs omap4_gpio_regs = { | |||
| 1440 | .fallingdetect = OMAP4_GPIO_FALLINGDETECT, | 1440 | .fallingdetect = OMAP4_GPIO_FALLINGDETECT, |
| 1441 | }; | 1441 | }; |
| 1442 | 1442 | ||
| 1443 | static struct omap_gpio_platform_data omap2_pdata = { | 1443 | const static struct omap_gpio_platform_data omap2_pdata = { |
| 1444 | .regs = &omap2_gpio_regs, | 1444 | .regs = &omap2_gpio_regs, |
| 1445 | .bank_width = 32, | 1445 | .bank_width = 32, |
| 1446 | .dbck_flag = false, | 1446 | .dbck_flag = false, |
| 1447 | }; | 1447 | }; |
| 1448 | 1448 | ||
| 1449 | static struct omap_gpio_platform_data omap3_pdata = { | 1449 | const static struct omap_gpio_platform_data omap3_pdata = { |
| 1450 | .regs = &omap2_gpio_regs, | 1450 | .regs = &omap2_gpio_regs, |
| 1451 | .bank_width = 32, | 1451 | .bank_width = 32, |
| 1452 | .dbck_flag = true, | 1452 | .dbck_flag = true, |
| 1453 | }; | 1453 | }; |
| 1454 | 1454 | ||
| 1455 | static struct omap_gpio_platform_data omap4_pdata = { | 1455 | const static struct omap_gpio_platform_data omap4_pdata = { |
| 1456 | .regs = &omap4_gpio_regs, | 1456 | .regs = &omap4_gpio_regs, |
| 1457 | .bank_width = 32, | 1457 | .bank_width = 32, |
| 1458 | .dbck_flag = true, | 1458 | .dbck_flag = true, |
diff --git a/drivers/i2c/busses/i2c-mpc.c b/drivers/i2c/busses/i2c-mpc.c index b76731edbf10..57f7703ce2e8 100644 --- a/drivers/i2c/busses/i2c-mpc.c +++ b/drivers/i2c/busses/i2c-mpc.c | |||
| @@ -647,7 +647,7 @@ static int __devinit fsl_i2c_probe(struct platform_device *op) | |||
| 647 | } | 647 | } |
| 648 | 648 | ||
| 649 | if (match->data) { | 649 | if (match->data) { |
| 650 | struct mpc_i2c_data *data = match->data; | 650 | const struct mpc_i2c_data *data = match->data; |
| 651 | data->setup(op->dev.of_node, i2c, clock, data->prescaler); | 651 | data->setup(op->dev.of_node, i2c, clock, data->prescaler); |
| 652 | } else { | 652 | } else { |
| 653 | /* Backwards compatibility */ | 653 | /* Backwards compatibility */ |
| @@ -730,24 +730,24 @@ static int mpc_i2c_resume(struct device *dev) | |||
| 730 | SIMPLE_DEV_PM_OPS(mpc_i2c_pm_ops, mpc_i2c_suspend, mpc_i2c_resume); | 730 | SIMPLE_DEV_PM_OPS(mpc_i2c_pm_ops, mpc_i2c_suspend, mpc_i2c_resume); |
| 731 | #endif | 731 | #endif |
| 732 | 732 | ||
| 733 | static struct mpc_i2c_data mpc_i2c_data_512x __devinitdata = { | 733 | static const struct mpc_i2c_data mpc_i2c_data_512x __devinitdata = { |
| 734 | .setup = mpc_i2c_setup_512x, | 734 | .setup = mpc_i2c_setup_512x, |
| 735 | }; | 735 | }; |
| 736 | 736 | ||
| 737 | static struct mpc_i2c_data mpc_i2c_data_52xx __devinitdata = { | 737 | static const struct mpc_i2c_data mpc_i2c_data_52xx __devinitdata = { |
| 738 | .setup = mpc_i2c_setup_52xx, | 738 | .setup = mpc_i2c_setup_52xx, |
| 739 | }; | 739 | }; |
| 740 | 740 | ||
| 741 | static struct mpc_i2c_data mpc_i2c_data_8313 __devinitdata = { | 741 | static const struct mpc_i2c_data mpc_i2c_data_8313 __devinitdata = { |
| 742 | .setup = mpc_i2c_setup_8xxx, | 742 | .setup = mpc_i2c_setup_8xxx, |
| 743 | }; | 743 | }; |
| 744 | 744 | ||
| 745 | static struct mpc_i2c_data mpc_i2c_data_8543 __devinitdata = { | 745 | static const struct mpc_i2c_data mpc_i2c_data_8543 __devinitdata = { |
| 746 | .setup = mpc_i2c_setup_8xxx, | 746 | .setup = mpc_i2c_setup_8xxx, |
| 747 | .prescaler = 2, | 747 | .prescaler = 2, |
| 748 | }; | 748 | }; |
| 749 | 749 | ||
| 750 | static struct mpc_i2c_data mpc_i2c_data_8544 __devinitdata = { | 750 | static const struct mpc_i2c_data mpc_i2c_data_8544 __devinitdata = { |
| 751 | .setup = mpc_i2c_setup_8xxx, | 751 | .setup = mpc_i2c_setup_8xxx, |
| 752 | .prescaler = 3, | 752 | .prescaler = 3, |
| 753 | }; | 753 | }; |
diff --git a/drivers/i2c/busses/i2c-omap.c b/drivers/i2c/busses/i2c-omap.c index 5d19a49803c1..a0e49f6aaf96 100644 --- a/drivers/i2c/busses/i2c-omap.c +++ b/drivers/i2c/busses/i2c-omap.c | |||
| @@ -944,7 +944,8 @@ omap_i2c_probe(struct platform_device *pdev) | |||
| 944 | struct omap_i2c_dev *dev; | 944 | struct omap_i2c_dev *dev; |
| 945 | struct i2c_adapter *adap; | 945 | struct i2c_adapter *adap; |
| 946 | struct resource *mem, *irq, *ioarea; | 946 | struct resource *mem, *irq, *ioarea; |
| 947 | struct omap_i2c_bus_platform_data *pdata = pdev->dev.platform_data; | 947 | const struct omap_i2c_bus_platform_data *pdata = |
| 948 | pdev->dev.platform_data; | ||
| 948 | struct device_node *node = pdev->dev.of_node; | 949 | struct device_node *node = pdev->dev.of_node; |
| 949 | const struct of_device_id *match; | 950 | const struct of_device_id *match; |
| 950 | irq_handler_t isr; | 951 | irq_handler_t isr; |
diff --git a/drivers/macintosh/mediabay.c b/drivers/macintosh/mediabay.c index 831d7517c759..3f8d032f180f 100644 --- a/drivers/macintosh/mediabay.c +++ b/drivers/macintosh/mediabay.c | |||
| @@ -63,7 +63,7 @@ struct media_bay_info { | |||
| 63 | int value_count; | 63 | int value_count; |
| 64 | int timer; | 64 | int timer; |
| 65 | struct macio_dev *mdev; | 65 | struct macio_dev *mdev; |
| 66 | struct mb_ops* ops; | 66 | const struct mb_ops* ops; |
| 67 | int index; | 67 | int index; |
| 68 | int cached_gpio; | 68 | int cached_gpio; |
| 69 | int sleeping; | 69 | int sleeping; |
| @@ -669,7 +669,7 @@ static int media_bay_resume(struct macio_dev *mdev) | |||
| 669 | 669 | ||
| 670 | /* Definitions of "ops" structures. | 670 | /* Definitions of "ops" structures. |
| 671 | */ | 671 | */ |
| 672 | static struct mb_ops ohare_mb_ops = { | 672 | static const struct mb_ops ohare_mb_ops = { |
| 673 | .name = "Ohare", | 673 | .name = "Ohare", |
| 674 | .content = ohare_mb_content, | 674 | .content = ohare_mb_content, |
| 675 | .power = ohare_mb_power, | 675 | .power = ohare_mb_power, |
| @@ -678,7 +678,7 @@ static struct mb_ops ohare_mb_ops = { | |||
| 678 | .un_reset_ide = ohare_mb_un_reset_ide, | 678 | .un_reset_ide = ohare_mb_un_reset_ide, |
| 679 | }; | 679 | }; |
| 680 | 680 | ||
| 681 | static struct mb_ops heathrow_mb_ops = { | 681 | static const struct mb_ops heathrow_mb_ops = { |
| 682 | .name = "Heathrow", | 682 | .name = "Heathrow", |
| 683 | .content = heathrow_mb_content, | 683 | .content = heathrow_mb_content, |
| 684 | .power = heathrow_mb_power, | 684 | .power = heathrow_mb_power, |
| @@ -687,7 +687,7 @@ static struct mb_ops heathrow_mb_ops = { | |||
| 687 | .un_reset_ide = heathrow_mb_un_reset_ide, | 687 | .un_reset_ide = heathrow_mb_un_reset_ide, |
| 688 | }; | 688 | }; |
| 689 | 689 | ||
| 690 | static struct mb_ops keylargo_mb_ops = { | 690 | static const struct mb_ops keylargo_mb_ops = { |
| 691 | .name = "KeyLargo", | 691 | .name = "KeyLargo", |
| 692 | .init = keylargo_mb_init, | 692 | .init = keylargo_mb_init, |
| 693 | .content = keylargo_mb_content, | 693 | .content = keylargo_mb_content, |
diff --git a/drivers/mfd/da9052-i2c.c b/drivers/mfd/da9052-i2c.c index 82c9d6450286..352c58b5a90d 100644 --- a/drivers/mfd/da9052-i2c.c +++ b/drivers/mfd/da9052-i2c.c | |||
| @@ -46,7 +46,7 @@ static int da9052_i2c_enable_multiwrite(struct da9052 *da9052) | |||
| 46 | return 0; | 46 | return 0; |
| 47 | } | 47 | } |
| 48 | 48 | ||
| 49 | static struct i2c_device_id da9052_i2c_id[] = { | 49 | static const struct i2c_device_id da9052_i2c_id[] = { |
| 50 | {"da9052", DA9052}, | 50 | {"da9052", DA9052}, |
| 51 | {"da9053-aa", DA9053_AA}, | 51 | {"da9053-aa", DA9053_AA}, |
| 52 | {"da9053-ba", DA9053_BA}, | 52 | {"da9053-ba", DA9053_BA}, |
| @@ -104,7 +104,7 @@ static int __devinit da9052_i2c_probe(struct i2c_client *client, | |||
| 104 | const struct of_device_id *deviceid; | 104 | const struct of_device_id *deviceid; |
| 105 | 105 | ||
| 106 | deviceid = of_match_node(dialog_dt_ids, np); | 106 | deviceid = of_match_node(dialog_dt_ids, np); |
| 107 | id = (const struct i2c_device_id *)deviceid->data; | 107 | id = deviceid->data; |
| 108 | } | 108 | } |
| 109 | #endif | 109 | #endif |
| 110 | 110 | ||
diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c index 686e256764c8..8e2d81f1ee4b 100644 --- a/drivers/mmc/host/omap_hsmmc.c +++ b/drivers/mmc/host/omap_hsmmc.c | |||
| @@ -1782,7 +1782,7 @@ static int __devinit omap_hsmmc_probe(struct platform_device *pdev) | |||
| 1782 | if (match) { | 1782 | if (match) { |
| 1783 | pdata = of_get_hsmmc_pdata(&pdev->dev); | 1783 | pdata = of_get_hsmmc_pdata(&pdev->dev); |
| 1784 | if (match->data) { | 1784 | if (match->data) { |
| 1785 | u16 *offsetp = match->data; | 1785 | const u16 *offsetp = match->data; |
| 1786 | pdata->reg_offset = *offsetp; | 1786 | pdata->reg_offset = *offsetp; |
| 1787 | } | 1787 | } |
| 1788 | } | 1788 | } |
diff --git a/drivers/net/can/mscan/mpc5xxx_can.c b/drivers/net/can/mscan/mpc5xxx_can.c index 06adf881ea24..8a8df82988d1 100644 --- a/drivers/net/can/mscan/mpc5xxx_can.c +++ b/drivers/net/can/mscan/mpc5xxx_can.c | |||
| @@ -380,12 +380,12 @@ static int mpc5xxx_can_resume(struct platform_device *ofdev) | |||
| 380 | } | 380 | } |
| 381 | #endif | 381 | #endif |
| 382 | 382 | ||
| 383 | static struct mpc5xxx_can_data __devinitdata mpc5200_can_data = { | 383 | static const struct mpc5xxx_can_data __devinitdata mpc5200_can_data = { |
| 384 | .type = MSCAN_TYPE_MPC5200, | 384 | .type = MSCAN_TYPE_MPC5200, |
| 385 | .get_clock = mpc52xx_can_get_clock, | 385 | .get_clock = mpc52xx_can_get_clock, |
| 386 | }; | 386 | }; |
| 387 | 387 | ||
| 388 | static struct mpc5xxx_can_data __devinitdata mpc5121_can_data = { | 388 | static const struct mpc5xxx_can_data __devinitdata mpc5121_can_data = { |
| 389 | .type = MSCAN_TYPE_MPC5121, | 389 | .type = MSCAN_TYPE_MPC5121, |
| 390 | .get_clock = mpc512x_can_get_clock, | 390 | .get_clock = mpc512x_can_get_clock, |
| 391 | }; | 391 | }; |
diff --git a/drivers/pcmcia/pxa2xx_base.c b/drivers/pcmcia/pxa2xx_base.c index 490bb82b5bdb..cfec9dd18ff5 100644 --- a/drivers/pcmcia/pxa2xx_base.c +++ b/drivers/pcmcia/pxa2xx_base.c | |||
| @@ -297,7 +297,7 @@ static int pxa2xx_drv_pcmcia_probe(struct platform_device *dev) | |||
| 297 | } | 297 | } |
| 298 | 298 | ||
| 299 | clk = clk_get(&dev->dev, NULL); | 299 | clk = clk_get(&dev->dev, NULL); |
| 300 | if (!clk) | 300 | if (IS_ERR(clk)) |
| 301 | return -ENODEV; | 301 | return -ENODEV; |
| 302 | 302 | ||
| 303 | pxa2xx_drv_pcmcia_ops(ops); | 303 | pxa2xx_drv_pcmcia_ops(ops); |
diff --git a/drivers/spi/spi-imx.c b/drivers/spi/spi-imx.c index e834ff8c0188..3bd9c691b796 100644 --- a/drivers/spi/spi-imx.c +++ b/drivers/spi/spi-imx.c | |||
| @@ -97,7 +97,7 @@ struct spi_imx_data { | |||
| 97 | const void *tx_buf; | 97 | const void *tx_buf; |
| 98 | unsigned int txfifo; /* number of words pushed in tx FIFO */ | 98 | unsigned int txfifo; /* number of words pushed in tx FIFO */ |
| 99 | 99 | ||
| 100 | struct spi_imx_devtype_data *devtype_data; | 100 | const struct spi_imx_devtype_data *devtype_data; |
| 101 | int chipselect[0]; | 101 | int chipselect[0]; |
| 102 | }; | 102 | }; |
| 103 | 103 | ||
diff --git a/drivers/spi/spi-omap2-mcspi.c b/drivers/spi/spi-omap2-mcspi.c index b2fb141da375..569714ebffe0 100644 --- a/drivers/spi/spi-omap2-mcspi.c +++ b/drivers/spi/spi-omap2-mcspi.c | |||
| @@ -1116,7 +1116,7 @@ MODULE_DEVICE_TABLE(of, omap_mcspi_of_match); | |||
| 1116 | static int __devinit omap2_mcspi_probe(struct platform_device *pdev) | 1116 | static int __devinit omap2_mcspi_probe(struct platform_device *pdev) |
| 1117 | { | 1117 | { |
| 1118 | struct spi_master *master; | 1118 | struct spi_master *master; |
| 1119 | struct omap2_mcspi_platform_config *pdata; | 1119 | const struct omap2_mcspi_platform_config *pdata; |
| 1120 | struct omap2_mcspi *mcspi; | 1120 | struct omap2_mcspi *mcspi; |
| 1121 | struct resource *r; | 1121 | struct resource *r; |
| 1122 | int status = 0, i; | 1122 | int status = 0, i; |
diff --git a/drivers/tty/serial/mpc52xx_uart.c b/drivers/tty/serial/mpc52xx_uart.c index f19d04ed8586..8cf577008ad7 100644 --- a/drivers/tty/serial/mpc52xx_uart.c +++ b/drivers/tty/serial/mpc52xx_uart.c | |||
| @@ -598,7 +598,7 @@ static struct psc_ops mpc512x_psc_ops = { | |||
| 598 | }; | 598 | }; |
| 599 | #endif | 599 | #endif |
| 600 | 600 | ||
| 601 | static struct psc_ops *psc_ops; | 601 | static const struct psc_ops *psc_ops; |
| 602 | 602 | ||
| 603 | /* ======================================================================== */ | 603 | /* ======================================================================== */ |
| 604 | /* UART operations */ | 604 | /* UART operations */ |
diff --git a/drivers/watchdog/mpc8xxx_wdt.c b/drivers/watchdog/mpc8xxx_wdt.c index 40f7bf1f8654..e6a038ae8dc2 100644 --- a/drivers/watchdog/mpc8xxx_wdt.c +++ b/drivers/watchdog/mpc8xxx_wdt.c | |||
| @@ -193,7 +193,7 @@ static int __devinit mpc8xxx_wdt_probe(struct platform_device *ofdev) | |||
| 193 | int ret; | 193 | int ret; |
| 194 | const struct of_device_id *match; | 194 | const struct of_device_id *match; |
| 195 | struct device_node *np = ofdev->dev.of_node; | 195 | struct device_node *np = ofdev->dev.of_node; |
| 196 | struct mpc8xxx_wdt_type *wdt_type; | 196 | const struct mpc8xxx_wdt_type *wdt_type; |
| 197 | u32 freq = fsl_get_sys_freq(); | 197 | u32 freq = fsl_get_sys_freq(); |
| 198 | bool enabled; | 198 | bool enabled; |
| 199 | 199 | ||
diff --git a/include/linux/atmel_tc.h b/include/linux/atmel_tc.h index 1d14b1dc1aee..89a931babecf 100644 --- a/include/linux/atmel_tc.h +++ b/include/linux/atmel_tc.h | |||
| @@ -63,7 +63,7 @@ struct atmel_tc { | |||
| 63 | struct platform_device *pdev; | 63 | struct platform_device *pdev; |
| 64 | struct resource *iomem; | 64 | struct resource *iomem; |
| 65 | void __iomem *regs; | 65 | void __iomem *regs; |
| 66 | struct atmel_tcb_config *tcb_config; | 66 | const struct atmel_tcb_config *tcb_config; |
| 67 | int irq[3]; | 67 | int irq[3]; |
| 68 | struct clk *clk[3]; | 68 | struct clk *clk[3]; |
| 69 | struct list_head node; | 69 | struct list_head node; |
diff --git a/include/linux/mod_devicetable.h b/include/linux/mod_devicetable.h index 70c6a359b2f4..fed3def62818 100644 --- a/include/linux/mod_devicetable.h +++ b/include/linux/mod_devicetable.h | |||
| @@ -232,7 +232,7 @@ struct of_device_id | |||
| 232 | char type[32]; | 232 | char type[32]; |
| 233 | char compatible[128]; | 233 | char compatible[128]; |
| 234 | #ifdef __KERNEL__ | 234 | #ifdef __KERNEL__ |
| 235 | void *data; | 235 | const void *data; |
| 236 | #else | 236 | #else |
| 237 | kernel_ulong_t data; | 237 | kernel_ulong_t data; |
| 238 | #endif | 238 | #endif |
