diff options
| -rw-r--r-- | arch/arm/include/asm/elf.h | 3 | ||||
| -rw-r--r-- | arch/arm/include/asm/tlbflush.h | 3 | ||||
| -rw-r--r-- | arch/arm/kernel/entry-armv.S | 28 | ||||
| -rw-r--r-- | arch/arm/kernel/entry-header.S | 15 | ||||
| -rw-r--r-- | arch/arm/kernel/process.c | 9 | ||||
| -rw-r--r-- | arch/arm/mach-ep93xx/edb93xx.c | 2 | ||||
| -rw-r--r-- | arch/arm/mach-mx2/clock_imx27.c | 8 | ||||
| -rw-r--r-- | arch/arm/mach-mx2/pcm038.c | 96 | ||||
| -rw-r--r-- | arch/arm/mach-mx2/pcm970-baseboard.c | 2 | ||||
| -rw-r--r-- | arch/arm/mach-mx25/devices.c | 19 | ||||
| -rw-r--r-- | arch/arm/mach-mx25/mx25pdk.c | 25 | ||||
| -rw-r--r-- | arch/arm/mach-mx3/clock-imx35.c | 2 | ||||
| -rw-r--r-- | arch/arm/mach-mx3/clock.c | 2 | ||||
| -rw-r--r-- | arch/arm/mach-mx3/devices.c | 24 | ||||
| -rw-r--r-- | arch/arm/mach-mx3/devices.h | 6 | ||||
| -rw-r--r-- | arch/arm/mach-mx3/mm.c | 2 |
16 files changed, 199 insertions, 47 deletions
diff --git a/arch/arm/include/asm/elf.h b/arch/arm/include/asm/elf.h index c3b911ee9151..6aac3f5bb2f3 100644 --- a/arch/arm/include/asm/elf.h +++ b/arch/arm/include/asm/elf.h | |||
| @@ -98,6 +98,9 @@ extern int elf_check_arch(const struct elf32_hdr *); | |||
| 98 | extern int arm_elf_read_implies_exec(const struct elf32_hdr *, int); | 98 | extern int arm_elf_read_implies_exec(const struct elf32_hdr *, int); |
| 99 | #define elf_read_implies_exec(ex,stk) arm_elf_read_implies_exec(&(ex), stk) | 99 | #define elf_read_implies_exec(ex,stk) arm_elf_read_implies_exec(&(ex), stk) |
| 100 | 100 | ||
| 101 | int dump_task_regs(struct task_struct *t, elf_gregset_t *elfregs); | ||
| 102 | #define ELF_CORE_COPY_TASK_REGS dump_task_regs | ||
| 103 | |||
| 101 | #define USE_ELF_CORE_DUMP | 104 | #define USE_ELF_CORE_DUMP |
| 102 | #define ELF_EXEC_PAGESIZE 4096 | 105 | #define ELF_EXEC_PAGESIZE 4096 |
| 103 | 106 | ||
diff --git a/arch/arm/include/asm/tlbflush.h b/arch/arm/include/asm/tlbflush.h index a45ab5dd8255..c2f1605de359 100644 --- a/arch/arm/include/asm/tlbflush.h +++ b/arch/arm/include/asm/tlbflush.h | |||
| @@ -350,7 +350,7 @@ static inline void local_flush_tlb_mm(struct mm_struct *mm) | |||
| 350 | if (tlb_flag(TLB_WB)) | 350 | if (tlb_flag(TLB_WB)) |
| 351 | dsb(); | 351 | dsb(); |
| 352 | 352 | ||
| 353 | if (cpumask_test_cpu(smp_processor_id(), mm_cpumask(mm))) { | 353 | if (cpumask_test_cpu(get_cpu(), mm_cpumask(mm))) { |
| 354 | if (tlb_flag(TLB_V3_FULL)) | 354 | if (tlb_flag(TLB_V3_FULL)) |
| 355 | asm("mcr p15, 0, %0, c6, c0, 0" : : "r" (zero) : "cc"); | 355 | asm("mcr p15, 0, %0, c6, c0, 0" : : "r" (zero) : "cc"); |
| 356 | if (tlb_flag(TLB_V4_U_FULL)) | 356 | if (tlb_flag(TLB_V4_U_FULL)) |
| @@ -360,6 +360,7 @@ static inline void local_flush_tlb_mm(struct mm_struct *mm) | |||
| 360 | if (tlb_flag(TLB_V4_I_FULL)) | 360 | if (tlb_flag(TLB_V4_I_FULL)) |
| 361 | asm("mcr p15, 0, %0, c8, c5, 0" : : "r" (zero) : "cc"); | 361 | asm("mcr p15, 0, %0, c8, c5, 0" : : "r" (zero) : "cc"); |
| 362 | } | 362 | } |
| 363 | put_cpu(); | ||
| 363 | 364 | ||
| 364 | if (tlb_flag(TLB_V6_U_ASID)) | 365 | if (tlb_flag(TLB_V6_U_ASID)) |
| 365 | asm("mcr p15, 0, %0, c8, c7, 2" : : "r" (asid) : "cc"); | 366 | asm("mcr p15, 0, %0, c8, c7, 2" : : "r" (asid) : "cc"); |
diff --git a/arch/arm/kernel/entry-armv.S b/arch/arm/kernel/entry-armv.S index 322410be573c..0022b4d57f8b 100644 --- a/arch/arm/kernel/entry-armv.S +++ b/arch/arm/kernel/entry-armv.S | |||
| @@ -608,33 +608,33 @@ call_fpe: | |||
| 608 | THUMB( add pc, r8 ) | 608 | THUMB( add pc, r8 ) |
| 609 | nop | 609 | nop |
| 610 | 610 | ||
| 611 | W(mov) pc, lr @ CP#0 | 611 | movw_pc lr @ CP#0 |
| 612 | W(b) do_fpe @ CP#1 (FPE) | 612 | W(b) do_fpe @ CP#1 (FPE) |
| 613 | W(b) do_fpe @ CP#2 (FPE) | 613 | W(b) do_fpe @ CP#2 (FPE) |
| 614 | W(mov) pc, lr @ CP#3 | 614 | movw_pc lr @ CP#3 |
| 615 | #ifdef CONFIG_CRUNCH | 615 | #ifdef CONFIG_CRUNCH |
| 616 | b crunch_task_enable @ CP#4 (MaverickCrunch) | 616 | b crunch_task_enable @ CP#4 (MaverickCrunch) |
| 617 | b crunch_task_enable @ CP#5 (MaverickCrunch) | 617 | b crunch_task_enable @ CP#5 (MaverickCrunch) |
| 618 | b crunch_task_enable @ CP#6 (MaverickCrunch) | 618 | b crunch_task_enable @ CP#6 (MaverickCrunch) |
| 619 | #else | 619 | #else |
| 620 | W(mov) pc, lr @ CP#4 | 620 | movw_pc lr @ CP#4 |
| 621 | W(mov) pc, lr @ CP#5 | 621 | movw_pc lr @ CP#5 |
| 622 | W(mov) pc, lr @ CP#6 | 622 | movw_pc lr @ CP#6 |
| 623 | #endif | 623 | #endif |
| 624 | W(mov) pc, lr @ CP#7 | 624 | movw_pc lr @ CP#7 |
| 625 | W(mov) pc, lr @ CP#8 | 625 | movw_pc lr @ CP#8 |
| 626 | W(mov) pc, lr @ CP#9 | 626 | movw_pc lr @ CP#9 |
| 627 | #ifdef CONFIG_VFP | 627 | #ifdef CONFIG_VFP |
| 628 | W(b) do_vfp @ CP#10 (VFP) | 628 | W(b) do_vfp @ CP#10 (VFP) |
| 629 | W(b) do_vfp @ CP#11 (VFP) | 629 | W(b) do_vfp @ CP#11 (VFP) |
| 630 | #else | 630 | #else |
| 631 | W(mov) pc, lr @ CP#10 (VFP) | 631 | movw_pc lr @ CP#10 (VFP) |
| 632 | W(mov) pc, lr @ CP#11 (VFP) | 632 | movw_pc lr @ CP#11 (VFP) |
| 633 | #endif | 633 | #endif |
| 634 | W(mov) pc, lr @ CP#12 | 634 | movw_pc lr @ CP#12 |
| 635 | W(mov) pc, lr @ CP#13 | 635 | movw_pc lr @ CP#13 |
| 636 | W(mov) pc, lr @ CP#14 (Debug) | 636 | movw_pc lr @ CP#14 (Debug) |
| 637 | W(mov) pc, lr @ CP#15 (Control) | 637 | movw_pc lr @ CP#15 (Control) |
| 638 | 638 | ||
| 639 | #ifdef CONFIG_NEON | 639 | #ifdef CONFIG_NEON |
| 640 | .align 6 | 640 | .align 6 |
diff --git a/arch/arm/kernel/entry-header.S b/arch/arm/kernel/entry-header.S index ac34c0d9384b..7e9ed1eea40a 100644 --- a/arch/arm/kernel/entry-header.S +++ b/arch/arm/kernel/entry-header.S | |||
| @@ -110,6 +110,13 @@ | |||
| 110 | mov \rd, sp, lsr #13 | 110 | mov \rd, sp, lsr #13 |
| 111 | mov \rd, \rd, lsl #13 | 111 | mov \rd, \rd, lsl #13 |
| 112 | .endm | 112 | .endm |
| 113 | |||
| 114 | @ | ||
| 115 | @ 32-bit wide "mov pc, reg" | ||
| 116 | @ | ||
| 117 | .macro movw_pc, reg | ||
| 118 | mov pc, \reg | ||
| 119 | .endm | ||
| 113 | #else /* CONFIG_THUMB2_KERNEL */ | 120 | #else /* CONFIG_THUMB2_KERNEL */ |
| 114 | .macro svc_exit, rpsr | 121 | .macro svc_exit, rpsr |
| 115 | clrex @ clear the exclusive monitor | 122 | clrex @ clear the exclusive monitor |
| @@ -146,6 +153,14 @@ | |||
| 146 | lsr \rd, \rd, #13 | 153 | lsr \rd, \rd, #13 |
| 147 | mov \rd, \rd, lsl #13 | 154 | mov \rd, \rd, lsl #13 |
| 148 | .endm | 155 | .endm |
| 156 | |||
| 157 | @ | ||
| 158 | @ 32-bit wide "mov pc, reg" | ||
| 159 | @ | ||
| 160 | .macro movw_pc, reg | ||
| 161 | mov pc, \reg | ||
| 162 | nop | ||
| 163 | .endm | ||
| 149 | #endif /* !CONFIG_THUMB2_KERNEL */ | 164 | #endif /* !CONFIG_THUMB2_KERNEL */ |
| 150 | 165 | ||
| 151 | /* | 166 | /* |
diff --git a/arch/arm/kernel/process.c b/arch/arm/kernel/process.c index 790fbee92ec5..0d96d0171c05 100644 --- a/arch/arm/kernel/process.c +++ b/arch/arm/kernel/process.c | |||
| @@ -328,6 +328,15 @@ copy_thread(unsigned long clone_flags, unsigned long stack_start, | |||
| 328 | } | 328 | } |
| 329 | 329 | ||
| 330 | /* | 330 | /* |
| 331 | * Fill in the task's elfregs structure for a core dump. | ||
| 332 | */ | ||
| 333 | int dump_task_regs(struct task_struct *t, elf_gregset_t *elfregs) | ||
| 334 | { | ||
| 335 | elf_core_copy_regs(elfregs, task_pt_regs(t)); | ||
| 336 | return 1; | ||
| 337 | } | ||
| 338 | |||
| 339 | /* | ||
| 331 | * fill in the fpe structure for a core dump... | 340 | * fill in the fpe structure for a core dump... |
| 332 | */ | 341 | */ |
| 333 | int dump_fpu (struct pt_regs *regs, struct user_fp *fp) | 342 | int dump_fpu (struct pt_regs *regs, struct user_fp *fp) |
diff --git a/arch/arm/mach-ep93xx/edb93xx.c b/arch/arm/mach-ep93xx/edb93xx.c index ca71cf1a72a0..a4a7be308000 100644 --- a/arch/arm/mach-ep93xx/edb93xx.c +++ b/arch/arm/mach-ep93xx/edb93xx.c | |||
| @@ -112,7 +112,7 @@ static void __init edb93xx_register_i2c(void) | |||
| 112 | ARRAY_SIZE(edb93xxa_i2c_board_info)); | 112 | ARRAY_SIZE(edb93xxa_i2c_board_info)); |
| 113 | } else if (machine_is_edb9307() || machine_is_edb9312() || | 113 | } else if (machine_is_edb9307() || machine_is_edb9312() || |
| 114 | machine_is_edb9315()) { | 114 | machine_is_edb9315()) { |
| 115 | ep93xx_register_i2c(&edb93xx_i2c_gpio_data | 115 | ep93xx_register_i2c(&edb93xx_i2c_gpio_data, |
| 116 | edb93xx_i2c_board_info, | 116 | edb93xx_i2c_board_info, |
| 117 | ARRAY_SIZE(edb93xx_i2c_board_info)); | 117 | ARRAY_SIZE(edb93xx_i2c_board_info)); |
| 118 | } | 118 | } |
diff --git a/arch/arm/mach-mx2/clock_imx27.c b/arch/arm/mach-mx2/clock_imx27.c index 4089951acb47..ff5e33298914 100644 --- a/arch/arm/mach-mx2/clock_imx27.c +++ b/arch/arm/mach-mx2/clock_imx27.c | |||
| @@ -638,9 +638,9 @@ static struct clk_lookup lookups[] = { | |||
| 638 | _REGISTER_CLOCK("mxc-mmc.0", NULL, sdhc1_clk) | 638 | _REGISTER_CLOCK("mxc-mmc.0", NULL, sdhc1_clk) |
| 639 | _REGISTER_CLOCK("mxc-mmc.1", NULL, sdhc2_clk) | 639 | _REGISTER_CLOCK("mxc-mmc.1", NULL, sdhc2_clk) |
| 640 | _REGISTER_CLOCK("mxc-mmc.2", NULL, sdhc3_clk) | 640 | _REGISTER_CLOCK("mxc-mmc.2", NULL, sdhc3_clk) |
| 641 | _REGISTER_CLOCK(NULL, "cspi1", cspi1_clk) | 641 | _REGISTER_CLOCK("spi_imx.0", NULL, cspi1_clk) |
| 642 | _REGISTER_CLOCK(NULL, "cspi2", cspi2_clk) | 642 | _REGISTER_CLOCK("spi_imx.1", NULL, cspi2_clk) |
| 643 | _REGISTER_CLOCK(NULL, "cspi3", cspi3_clk) | 643 | _REGISTER_CLOCK("spi_imx.2", NULL, cspi3_clk) |
| 644 | _REGISTER_CLOCK("imx-fb.0", NULL, lcdc_clk) | 644 | _REGISTER_CLOCK("imx-fb.0", NULL, lcdc_clk) |
| 645 | _REGISTER_CLOCK(NULL, "csi", csi_clk) | 645 | _REGISTER_CLOCK(NULL, "csi", csi_clk) |
| 646 | _REGISTER_CLOCK("fsl-usb2-udc", "usb", usb_clk) | 646 | _REGISTER_CLOCK("fsl-usb2-udc", "usb", usb_clk) |
| @@ -665,7 +665,7 @@ static struct clk_lookup lookups[] = { | |||
| 665 | _REGISTER_CLOCK(NULL, "sahara2", sahara2_clk) | 665 | _REGISTER_CLOCK(NULL, "sahara2", sahara2_clk) |
| 666 | _REGISTER_CLOCK(NULL, "ata", ata_clk) | 666 | _REGISTER_CLOCK(NULL, "ata", ata_clk) |
| 667 | _REGISTER_CLOCK(NULL, "mstick", mstick_clk) | 667 | _REGISTER_CLOCK(NULL, "mstick", mstick_clk) |
| 668 | _REGISTER_CLOCK(NULL, "wdog", wdog_clk) | 668 | _REGISTER_CLOCK("imx-wdt.0", NULL, wdog_clk) |
| 669 | _REGISTER_CLOCK(NULL, "gpio", gpio_clk) | 669 | _REGISTER_CLOCK(NULL, "gpio", gpio_clk) |
| 670 | _REGISTER_CLOCK("imx-i2c.0", NULL, i2c1_clk) | 670 | _REGISTER_CLOCK("imx-i2c.0", NULL, i2c1_clk) |
| 671 | _REGISTER_CLOCK("imx-i2c.1", NULL, i2c2_clk) | 671 | _REGISTER_CLOCK("imx-i2c.1", NULL, i2c2_clk) |
diff --git a/arch/arm/mach-mx2/pcm038.c b/arch/arm/mach-mx2/pcm038.c index ee65dda584cf..906d59b0a7aa 100644 --- a/arch/arm/mach-mx2/pcm038.c +++ b/arch/arm/mach-mx2/pcm038.c | |||
| @@ -23,6 +23,10 @@ | |||
| 23 | #include <linux/mtd/plat-ram.h> | 23 | #include <linux/mtd/plat-ram.h> |
| 24 | #include <linux/mtd/physmap.h> | 24 | #include <linux/mtd/physmap.h> |
| 25 | #include <linux/platform_device.h> | 25 | #include <linux/platform_device.h> |
| 26 | #include <linux/regulator/machine.h> | ||
| 27 | #include <linux/mfd/mc13783.h> | ||
| 28 | #include <linux/spi/spi.h> | ||
| 29 | #include <linux/irq.h> | ||
| 26 | 30 | ||
| 27 | #include <asm/mach-types.h> | 31 | #include <asm/mach-types.h> |
| 28 | #include <asm/mach/arch.h> | 32 | #include <asm/mach/arch.h> |
| @@ -35,6 +39,7 @@ | |||
| 35 | #include <mach/iomux.h> | 39 | #include <mach/iomux.h> |
| 36 | #include <mach/imx-uart.h> | 40 | #include <mach/imx-uart.h> |
| 37 | #include <mach/mxc_nand.h> | 41 | #include <mach/mxc_nand.h> |
| 42 | #include <mach/spi.h> | ||
| 38 | 43 | ||
| 39 | #include "devices.h" | 44 | #include "devices.h" |
| 40 | 45 | ||
| @@ -78,8 +83,6 @@ static int pcm038_pins[] = { | |||
| 78 | PC6_PF_I2C2_SCL, | 83 | PC6_PF_I2C2_SCL, |
| 79 | /* SPI1 */ | 84 | /* SPI1 */ |
| 80 | PD25_PF_CSPI1_RDY, | 85 | PD25_PF_CSPI1_RDY, |
| 81 | PD27_PF_CSPI1_SS1, | ||
| 82 | PD28_PF_CSPI1_SS0, | ||
| 83 | PD29_PF_CSPI1_SCLK, | 86 | PD29_PF_CSPI1_SCLK, |
| 84 | PD30_PF_CSPI1_MISO, | 87 | PD30_PF_CSPI1_MISO, |
| 85 | PD31_PF_CSPI1_MOSI, | 88 | PD31_PF_CSPI1_MOSI, |
| @@ -196,6 +199,86 @@ static struct i2c_board_info pcm038_i2c_devices[] = { | |||
| 196 | } | 199 | } |
| 197 | }; | 200 | }; |
| 198 | 201 | ||
| 202 | static int pcm038_spi_cs[] = {GPIO_PORTD + 28}; | ||
| 203 | |||
| 204 | static struct spi_imx_master pcm038_spi_0_data = { | ||
| 205 | .chipselect = pcm038_spi_cs, | ||
| 206 | .num_chipselect = ARRAY_SIZE(pcm038_spi_cs), | ||
| 207 | }; | ||
| 208 | |||
| 209 | static struct regulator_consumer_supply sdhc1_consumers[] = { | ||
| 210 | { | ||
| 211 | .dev = &mxc_sdhc_device1.dev, | ||
| 212 | .supply = "sdhc_vcc", | ||
| 213 | }, | ||
| 214 | }; | ||
| 215 | |||
| 216 | static struct regulator_init_data sdhc1_data = { | ||
| 217 | .constraints = { | ||
| 218 | .min_uV = 3000000, | ||
| 219 | .max_uV = 3400000, | ||
| 220 | .valid_ops_mask = REGULATOR_CHANGE_VOLTAGE | | ||
| 221 | REGULATOR_CHANGE_MODE | REGULATOR_CHANGE_STATUS, | ||
| 222 | .valid_modes_mask = REGULATOR_MODE_NORMAL | | ||
| 223 | REGULATOR_MODE_FAST, | ||
| 224 | .always_on = 0, | ||
| 225 | .boot_on = 0, | ||
| 226 | }, | ||
| 227 | .num_consumer_supplies = ARRAY_SIZE(sdhc1_consumers), | ||
| 228 | .consumer_supplies = sdhc1_consumers, | ||
| 229 | }; | ||
| 230 | |||
| 231 | static struct regulator_consumer_supply cam_consumers[] = { | ||
| 232 | { | ||
| 233 | .dev = NULL, | ||
| 234 | .supply = "imx_cam_vcc", | ||
| 235 | }, | ||
| 236 | }; | ||
| 237 | |||
| 238 | static struct regulator_init_data cam_data = { | ||
| 239 | .constraints = { | ||
| 240 | .min_uV = 3000000, | ||
| 241 | .max_uV = 3400000, | ||
| 242 | .valid_ops_mask = REGULATOR_CHANGE_VOLTAGE | | ||
| 243 | REGULATOR_CHANGE_MODE | REGULATOR_CHANGE_STATUS, | ||
| 244 | .valid_modes_mask = REGULATOR_MODE_NORMAL | | ||
| 245 | REGULATOR_MODE_FAST, | ||
| 246 | .always_on = 0, | ||
| 247 | .boot_on = 0, | ||
| 248 | }, | ||
| 249 | .num_consumer_supplies = ARRAY_SIZE(cam_consumers), | ||
| 250 | .consumer_supplies = cam_consumers, | ||
| 251 | }; | ||
| 252 | |||
| 253 | struct mc13783_regulator_init_data pcm038_regulators[] = { | ||
| 254 | { | ||
| 255 | .id = MC13783_REGU_VCAM, | ||
| 256 | .init_data = &cam_data, | ||
| 257 | }, { | ||
| 258 | .id = MC13783_REGU_VMMC1, | ||
| 259 | .init_data = &sdhc1_data, | ||
| 260 | }, | ||
| 261 | }; | ||
| 262 | |||
| 263 | static struct mc13783_platform_data pcm038_pmic = { | ||
| 264 | .regulators = pcm038_regulators, | ||
| 265 | .num_regulators = ARRAY_SIZE(pcm038_regulators), | ||
| 266 | .flags = MC13783_USE_ADC | MC13783_USE_REGULATOR | | ||
| 267 | MC13783_USE_TOUCHSCREEN, | ||
| 268 | }; | ||
| 269 | |||
| 270 | static struct spi_board_info pcm038_spi_board_info[] __initdata = { | ||
| 271 | { | ||
| 272 | .modalias = "mc13783", | ||
| 273 | .irq = IRQ_GPIOB(23), | ||
| 274 | .max_speed_hz = 300000, | ||
| 275 | .bus_num = 0, | ||
| 276 | .chip_select = 0, | ||
| 277 | .platform_data = &pcm038_pmic, | ||
| 278 | .mode = SPI_CS_HIGH, | ||
| 279 | } | ||
| 280 | }; | ||
| 281 | |||
| 199 | static void __init pcm038_init(void) | 282 | static void __init pcm038_init(void) |
| 200 | { | 283 | { |
| 201 | mxc_gpio_setup_multiple_pins(pcm038_pins, ARRAY_SIZE(pcm038_pins), | 284 | mxc_gpio_setup_multiple_pins(pcm038_pins, ARRAY_SIZE(pcm038_pins), |
| @@ -219,6 +302,15 @@ static void __init pcm038_init(void) | |||
| 219 | /* PE18 for user-LED D40 */ | 302 | /* PE18 for user-LED D40 */ |
| 220 | mxc_gpio_mode(GPIO_PORTE | 18 | GPIO_GPIO | GPIO_OUT); | 303 | mxc_gpio_mode(GPIO_PORTE | 18 | GPIO_GPIO | GPIO_OUT); |
| 221 | 304 | ||
| 305 | mxc_gpio_mode(GPIO_PORTD | 28 | GPIO_GPIO | GPIO_OUT); | ||
| 306 | |||
| 307 | /* MC13783 IRQ */ | ||
| 308 | mxc_gpio_mode(GPIO_PORTB | 23 | GPIO_GPIO | GPIO_IN); | ||
| 309 | |||
| 310 | mxc_register_device(&mxc_spi_device0, &pcm038_spi_0_data); | ||
| 311 | spi_register_board_info(pcm038_spi_board_info, | ||
| 312 | ARRAY_SIZE(pcm038_spi_board_info)); | ||
| 313 | |||
| 222 | platform_add_devices(platform_devices, ARRAY_SIZE(platform_devices)); | 314 | platform_add_devices(platform_devices, ARRAY_SIZE(platform_devices)); |
| 223 | 315 | ||
| 224 | #ifdef CONFIG_MACH_PCM970_BASEBOARD | 316 | #ifdef CONFIG_MACH_PCM970_BASEBOARD |
diff --git a/arch/arm/mach-mx2/pcm970-baseboard.c b/arch/arm/mach-mx2/pcm970-baseboard.c index c261f59b0b4c..3cb7f457e5d0 100644 --- a/arch/arm/mach-mx2/pcm970-baseboard.c +++ b/arch/arm/mach-mx2/pcm970-baseboard.c | |||
| @@ -39,7 +39,6 @@ static int pcm970_pins[] = { | |||
| 39 | PB7_PF_SD2_D3, | 39 | PB7_PF_SD2_D3, |
| 40 | PB8_PF_SD2_CMD, | 40 | PB8_PF_SD2_CMD, |
| 41 | PB9_PF_SD2_CLK, | 41 | PB9_PF_SD2_CLK, |
| 42 | GPIO_PORTC | 28 | GPIO_GPIO | GPIO_IN, /* card detect */ | ||
| 43 | /* display */ | 42 | /* display */ |
| 44 | PA5_PF_LSCLK, | 43 | PA5_PF_LSCLK, |
| 45 | PA6_PF_LD0, | 44 | PA6_PF_LD0, |
| @@ -228,6 +227,7 @@ void __init pcm970_baseboard_init(void) | |||
| 228 | "PCM970"); | 227 | "PCM970"); |
| 229 | 228 | ||
| 230 | mxc_register_device(&mxc_fb_device, &pcm038_fb_data); | 229 | mxc_register_device(&mxc_fb_device, &pcm038_fb_data); |
| 230 | mxc_gpio_mode(GPIO_PORTC | 28 | GPIO_GPIO | GPIO_IN); | ||
| 231 | mxc_register_device(&mxc_sdhc_device1, &sdhc_pdata); | 231 | mxc_register_device(&mxc_sdhc_device1, &sdhc_pdata); |
| 232 | platform_device_register(&pcm970_sja1000); | 232 | platform_device_register(&pcm970_sja1000); |
| 233 | } | 233 | } |
diff --git a/arch/arm/mach-mx25/devices.c b/arch/arm/mach-mx25/devices.c index eb12de1da42d..63511de3a559 100644 --- a/arch/arm/mach-mx25/devices.c +++ b/arch/arm/mach-mx25/devices.c | |||
| @@ -1,4 +1,23 @@ | |||
| 1 | /* | ||
| 2 | * Copyright 2009 Sascha Hauer, <kernel@pengutronix.de> | ||
| 3 | * | ||
| 4 | * This program is free software; you can redistribute it and/or | ||
| 5 | * modify it under the terms of the GNU General Public License | ||
| 6 | * as published by the Free Software Foundation; either version 2 | ||
| 7 | * of the License, or (at your option) any later version. | ||
| 8 | * This program is distributed in the hope that it will be useful, | ||
| 9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 11 | * GNU General Public License for more details. | ||
| 12 | * | ||
| 13 | * You should have received a copy of the GNU General Public License | ||
| 14 | * along with this program; if not, write to the Free Software | ||
| 15 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, | ||
| 16 | * Boston, MA 02110-1301, USA. | ||
| 17 | */ | ||
| 18 | |||
| 1 | #include <linux/platform_device.h> | 19 | #include <linux/platform_device.h> |
| 20 | #include <linux/dma-mapping.h> | ||
| 2 | #include <linux/gpio.h> | 21 | #include <linux/gpio.h> |
| 3 | #include <mach/mx25.h> | 22 | #include <mach/mx25.h> |
| 4 | #include <mach/irqs.h> | 23 | #include <mach/irqs.h> |
diff --git a/arch/arm/mach-mx25/mx25pdk.c b/arch/arm/mach-mx25/mx25pdk.c index 92aa4fd19d99..d23ae571c03f 100644 --- a/arch/arm/mach-mx25/mx25pdk.c +++ b/arch/arm/mach-mx25/mx25pdk.c | |||
| @@ -1,3 +1,21 @@ | |||
| 1 | /* | ||
| 2 | * Copyright 2009 Sascha Hauer, <kernel@pengutronix.de> | ||
| 3 | * | ||
| 4 | * This program is free software; you can redistribute it and/or | ||
| 5 | * modify it under the terms of the GNU General Public License | ||
| 6 | * as published by the Free Software Foundation; either version 2 | ||
| 7 | * of the License, or (at your option) any later version. | ||
| 8 | * This program is distributed in the hope that it will be useful, | ||
| 9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 11 | * GNU General Public License for more details. | ||
| 12 | * | ||
| 13 | * You should have received a copy of the GNU General Public License | ||
| 14 | * along with this program; if not, write to the Free Software | ||
| 15 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, | ||
| 16 | * Boston, MA 02110-1301, USA. | ||
| 17 | */ | ||
| 18 | |||
| 1 | #include <linux/types.h> | 19 | #include <linux/types.h> |
| 2 | #include <linux/init.h> | 20 | #include <linux/init.h> |
| 3 | #include <linux/clk.h> | 21 | #include <linux/clk.h> |
| @@ -23,19 +41,12 @@ static struct imxuart_platform_data uart_pdata = { | |||
| 23 | .flags = IMXUART_HAVE_RTSCTS, | 41 | .flags = IMXUART_HAVE_RTSCTS, |
| 24 | }; | 42 | }; |
| 25 | 43 | ||
| 26 | static struct mxc_nand_platform_data nand_board_info = { | ||
| 27 | .width = 1, | ||
| 28 | .hw_ecc = 1, | ||
| 29 | }; | ||
| 30 | |||
| 31 | static void __init mx25pdk_init(void) | 44 | static void __init mx25pdk_init(void) |
| 32 | { | 45 | { |
| 33 | mxc_register_device(&mxc_uart_device0, &uart_pdata); | 46 | mxc_register_device(&mxc_uart_device0, &uart_pdata); |
| 34 | mxc_register_device(&mxc_usbh2, NULL); | 47 | mxc_register_device(&mxc_usbh2, NULL); |
| 35 | mxc_register_device(&mxc_nand_device, &nand_board_info); | ||
| 36 | } | 48 | } |
| 37 | 49 | ||
| 38 | |||
| 39 | static void __init mx25pdk_timer_init(void) | 50 | static void __init mx25pdk_timer_init(void) |
| 40 | { | 51 | { |
| 41 | mx25_clocks_init(26000000); | 52 | mx25_clocks_init(26000000); |
diff --git a/arch/arm/mach-mx3/clock-imx35.c b/arch/arm/mach-mx3/clock-imx35.c index fe5c4217322e..c595260ec1f9 100644 --- a/arch/arm/mach-mx3/clock-imx35.c +++ b/arch/arm/mach-mx3/clock-imx35.c | |||
| @@ -443,7 +443,7 @@ static struct clk_lookup lookups[] = { | |||
| 443 | _REGISTER_CLOCK("mxc-ehci.1", "usb", usbotg_clk) | 443 | _REGISTER_CLOCK("mxc-ehci.1", "usb", usbotg_clk) |
| 444 | _REGISTER_CLOCK("mxc-ehci.2", "usb", usbotg_clk) | 444 | _REGISTER_CLOCK("mxc-ehci.2", "usb", usbotg_clk) |
| 445 | _REGISTER_CLOCK("fsl-usb2-udc", "usb", usbotg_clk) | 445 | _REGISTER_CLOCK("fsl-usb2-udc", "usb", usbotg_clk) |
| 446 | _REGISTER_CLOCK("mxc_wdt.0", NULL, wdog_clk) | 446 | _REGISTER_CLOCK("imx-wdt.0", NULL, wdog_clk) |
| 447 | _REGISTER_CLOCK(NULL, "max", max_clk) | 447 | _REGISTER_CLOCK(NULL, "max", max_clk) |
| 448 | _REGISTER_CLOCK(NULL, "admux", admux_clk) | 448 | _REGISTER_CLOCK(NULL, "admux", admux_clk) |
| 449 | _REGISTER_CLOCK(NULL, "csi", csi_clk) | 449 | _REGISTER_CLOCK(NULL, "csi", csi_clk) |
diff --git a/arch/arm/mach-mx3/clock.c b/arch/arm/mach-mx3/clock.c index 06bd6180bfc3..b2a3bcf8266e 100644 --- a/arch/arm/mach-mx3/clock.c +++ b/arch/arm/mach-mx3/clock.c | |||
| @@ -530,7 +530,7 @@ static struct clk_lookup lookups[] = { | |||
| 530 | _REGISTER_CLOCK("spi_imx.2", NULL, cspi3_clk) | 530 | _REGISTER_CLOCK("spi_imx.2", NULL, cspi3_clk) |
| 531 | _REGISTER_CLOCK(NULL, "gpt", gpt_clk) | 531 | _REGISTER_CLOCK(NULL, "gpt", gpt_clk) |
| 532 | _REGISTER_CLOCK(NULL, "pwm", pwm_clk) | 532 | _REGISTER_CLOCK(NULL, "pwm", pwm_clk) |
| 533 | _REGISTER_CLOCK(NULL, "wdog", wdog_clk) | 533 | _REGISTER_CLOCK("imx-wdt.0", NULL, wdog_clk) |
| 534 | _REGISTER_CLOCK(NULL, "rtc", rtc_clk) | 534 | _REGISTER_CLOCK(NULL, "rtc", rtc_clk) |
| 535 | _REGISTER_CLOCK(NULL, "epit", epit1_clk) | 535 | _REGISTER_CLOCK(NULL, "epit", epit1_clk) |
| 536 | _REGISTER_CLOCK(NULL, "epit", epit2_clk) | 536 | _REGISTER_CLOCK(NULL, "epit", epit2_clk) |
diff --git a/arch/arm/mach-mx3/devices.c b/arch/arm/mach-mx3/devices.c index 8a577f367250..e6abe181b967 100644 --- a/arch/arm/mach-mx3/devices.c +++ b/arch/arm/mach-mx3/devices.c | |||
| @@ -459,7 +459,7 @@ struct platform_device mxc_usbh2 = { | |||
| 459 | * SPI master controller | 459 | * SPI master controller |
| 460 | * 3 channels | 460 | * 3 channels |
| 461 | */ | 461 | */ |
| 462 | static struct resource imx_spi_0_resources[] = { | 462 | static struct resource mxc_spi_0_resources[] = { |
| 463 | { | 463 | { |
| 464 | .start = CSPI1_BASE_ADDR, | 464 | .start = CSPI1_BASE_ADDR, |
| 465 | .end = CSPI1_BASE_ADDR + SZ_4K - 1, | 465 | .end = CSPI1_BASE_ADDR + SZ_4K - 1, |
| @@ -471,7 +471,7 @@ static struct resource imx_spi_0_resources[] = { | |||
| 471 | }, | 471 | }, |
| 472 | }; | 472 | }; |
| 473 | 473 | ||
| 474 | static struct resource imx_spi_1_resources[] = { | 474 | static struct resource mxc_spi_1_resources[] = { |
| 475 | { | 475 | { |
| 476 | .start = CSPI2_BASE_ADDR, | 476 | .start = CSPI2_BASE_ADDR, |
| 477 | .end = CSPI2_BASE_ADDR + SZ_4K - 1, | 477 | .end = CSPI2_BASE_ADDR + SZ_4K - 1, |
| @@ -483,7 +483,7 @@ static struct resource imx_spi_1_resources[] = { | |||
| 483 | }, | 483 | }, |
| 484 | }; | 484 | }; |
| 485 | 485 | ||
| 486 | static struct resource imx_spi_2_resources[] = { | 486 | static struct resource mxc_spi_2_resources[] = { |
| 487 | { | 487 | { |
| 488 | .start = CSPI3_BASE_ADDR, | 488 | .start = CSPI3_BASE_ADDR, |
| 489 | .end = CSPI3_BASE_ADDR + SZ_4K - 1, | 489 | .end = CSPI3_BASE_ADDR + SZ_4K - 1, |
| @@ -495,25 +495,25 @@ static struct resource imx_spi_2_resources[] = { | |||
| 495 | }, | 495 | }, |
| 496 | }; | 496 | }; |
| 497 | 497 | ||
| 498 | struct platform_device imx_spi_device0 = { | 498 | struct platform_device mxc_spi_device0 = { |
| 499 | .name = "spi_imx", | 499 | .name = "spi_imx", |
| 500 | .id = 0, | 500 | .id = 0, |
| 501 | .num_resources = ARRAY_SIZE(imx_spi_0_resources), | 501 | .num_resources = ARRAY_SIZE(mxc_spi_0_resources), |
| 502 | .resource = imx_spi_0_resources, | 502 | .resource = mxc_spi_0_resources, |
| 503 | }; | 503 | }; |
| 504 | 504 | ||
| 505 | struct platform_device imx_spi_device1 = { | 505 | struct platform_device mxc_spi_device1 = { |
| 506 | .name = "spi_imx", | 506 | .name = "spi_imx", |
| 507 | .id = 1, | 507 | .id = 1, |
| 508 | .num_resources = ARRAY_SIZE(imx_spi_1_resources), | 508 | .num_resources = ARRAY_SIZE(mxc_spi_1_resources), |
| 509 | .resource = imx_spi_1_resources, | 509 | .resource = mxc_spi_1_resources, |
| 510 | }; | 510 | }; |
| 511 | 511 | ||
| 512 | struct platform_device imx_spi_device2 = { | 512 | struct platform_device mxc_spi_device2 = { |
| 513 | .name = "spi_imx", | 513 | .name = "spi_imx", |
| 514 | .id = 2, | 514 | .id = 2, |
| 515 | .num_resources = ARRAY_SIZE(imx_spi_2_resources), | 515 | .num_resources = ARRAY_SIZE(mxc_spi_2_resources), |
| 516 | .resource = imx_spi_2_resources, | 516 | .resource = mxc_spi_2_resources, |
| 517 | }; | 517 | }; |
| 518 | 518 | ||
| 519 | #ifdef CONFIG_ARCH_MX35 | 519 | #ifdef CONFIG_ARCH_MX35 |
diff --git a/arch/arm/mach-mx3/devices.h b/arch/arm/mach-mx3/devices.h index 79f2be45d139..ab87419dc9a0 100644 --- a/arch/arm/mach-mx3/devices.h +++ b/arch/arm/mach-mx3/devices.h | |||
| @@ -20,7 +20,7 @@ extern struct platform_device mxc_otg_host; | |||
| 20 | extern struct platform_device mxc_usbh1; | 20 | extern struct platform_device mxc_usbh1; |
| 21 | extern struct platform_device mxc_usbh2; | 21 | extern struct platform_device mxc_usbh2; |
| 22 | extern struct platform_device mxc_rnga_device; | 22 | extern struct platform_device mxc_rnga_device; |
| 23 | extern struct platform_device imx_spi_device0; | 23 | extern struct platform_device mxc_spi_device0; |
| 24 | extern struct platform_device imx_spi_device1; | 24 | extern struct platform_device mxc_spi_device1; |
| 25 | extern struct platform_device imx_spi_device2; | 25 | extern struct platform_device mxc_spi_device2; |
| 26 | 26 | ||
diff --git a/arch/arm/mach-mx3/mm.c b/arch/arm/mach-mx3/mm.c index ad5a1122d765..bedf5b8d976a 100644 --- a/arch/arm/mach-mx3/mm.c +++ b/arch/arm/mach-mx3/mm.c | |||
| @@ -81,6 +81,7 @@ void __init mx31_map_io(void) | |||
| 81 | iotable_init(mxc_io_desc, ARRAY_SIZE(mxc_io_desc)); | 81 | iotable_init(mxc_io_desc, ARRAY_SIZE(mxc_io_desc)); |
| 82 | } | 82 | } |
| 83 | 83 | ||
| 84 | #ifdef CONFIG_ARCH_MX35 | ||
| 84 | void __init mx35_map_io(void) | 85 | void __init mx35_map_io(void) |
| 85 | { | 86 | { |
| 86 | mxc_set_cpu_type(MXC_CPU_MX35); | 87 | mxc_set_cpu_type(MXC_CPU_MX35); |
| @@ -89,6 +90,7 @@ void __init mx35_map_io(void) | |||
| 89 | 90 | ||
| 90 | iotable_init(mxc_io_desc, ARRAY_SIZE(mxc_io_desc)); | 91 | iotable_init(mxc_io_desc, ARRAY_SIZE(mxc_io_desc)); |
| 91 | } | 92 | } |
| 93 | #endif | ||
| 92 | 94 | ||
| 93 | void __init mx31_init_irq(void) | 95 | void __init mx31_init_irq(void) |
| 94 | { | 96 | { |
