diff options
Diffstat (limited to 'arch/blackfin/mach-bf533')
-rw-r--r-- | arch/blackfin/mach-bf533/boards/H8606.c | 39 | ||||
-rw-r--r-- | arch/blackfin/mach-bf533/boards/blackstamp.c | 11 | ||||
-rw-r--r-- | arch/blackfin/mach-bf533/boards/cm_bf533.c | 127 | ||||
-rw-r--r-- | arch/blackfin/mach-bf533/boards/ezkit.c | 13 | ||||
-rw-r--r-- | arch/blackfin/mach-bf533/boards/stamp.c | 83 | ||||
-rw-r--r-- | arch/blackfin/mach-bf533/dma.c | 8 | ||||
-rw-r--r-- | arch/blackfin/mach-bf533/include/mach/bfin_serial_5xx.h | 8 | ||||
-rw-r--r-- | arch/blackfin/mach-bf533/include/mach/blackfin.h | 7 |
8 files changed, 220 insertions, 76 deletions
diff --git a/arch/blackfin/mach-bf533/boards/H8606.c b/arch/blackfin/mach-bf533/boards/H8606.c index 38cf8ffd6d74..6c2b47fe4fe4 100644 --- a/arch/blackfin/mach-bf533/boards/H8606.c +++ b/arch/blackfin/mach-bf533/boards/H8606.c | |||
@@ -88,6 +88,14 @@ static struct platform_device dm9000_device = { | |||
88 | #endif | 88 | #endif |
89 | 89 | ||
90 | #if defined(CONFIG_SMC91X) || defined(CONFIG_SMC91X_MODULE) | 90 | #if defined(CONFIG_SMC91X) || defined(CONFIG_SMC91X_MODULE) |
91 | #include <linux/smc91x.h> | ||
92 | |||
93 | static struct smc91x_platdata smc91x_info = { | ||
94 | .flags = SMC91X_USE_16BIT | SMC91X_NOWAIT, | ||
95 | .leda = RPC_LED_100_10, | ||
96 | .ledb = RPC_LED_TX_RX, | ||
97 | }; | ||
98 | |||
91 | static struct resource smc91x_resources[] = { | 99 | static struct resource smc91x_resources[] = { |
92 | { | 100 | { |
93 | .name = "smc91x-regs", | 101 | .name = "smc91x-regs", |
@@ -110,6 +118,9 @@ static struct platform_device smc91x_device = { | |||
110 | .id = 0, | 118 | .id = 0, |
111 | .num_resources = ARRAY_SIZE(smc91x_resources), | 119 | .num_resources = ARRAY_SIZE(smc91x_resources), |
112 | .resource = smc91x_resources, | 120 | .resource = smc91x_resources, |
121 | .dev = { | ||
122 | .platform_data = &smc91x_info, | ||
123 | }, | ||
113 | }; | 124 | }; |
114 | #endif | 125 | #endif |
115 | 126 | ||
@@ -190,15 +201,6 @@ static struct bfin5xx_spi_chip ad1836_spi_chip_info = { | |||
190 | }; | 201 | }; |
191 | #endif | 202 | #endif |
192 | 203 | ||
193 | #if defined(CONFIG_PBX) | ||
194 | static struct bfin5xx_spi_chip spi_si3xxx_chip_info = { | ||
195 | .ctl_reg = 0x1c04, | ||
196 | .enable_dma = 0, | ||
197 | .bits_per_word = 8, | ||
198 | .cs_change_per_word = 1, | ||
199 | }; | ||
200 | #endif | ||
201 | |||
202 | /* Notice: for blackfin, the speed_hz is the value of register | 204 | /* Notice: for blackfin, the speed_hz is the value of register |
203 | * SPI_BAUD, not the real baudrate */ | 205 | * SPI_BAUD, not the real baudrate */ |
204 | static struct spi_board_info bfin_spi_board_info[] __initdata = { | 206 | static struct spi_board_info bfin_spi_board_info[] __initdata = { |
@@ -229,7 +231,7 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { | |||
229 | 231 | ||
230 | #if defined(CONFIG_SND_BLACKFIN_AD1836) || defined(CONFIG_SND_BLACKFIN_AD1836_MODULE) | 232 | #if defined(CONFIG_SND_BLACKFIN_AD1836) || defined(CONFIG_SND_BLACKFIN_AD1836_MODULE) |
231 | { | 233 | { |
232 | .modalias = "ad1836-spi", | 234 | .modalias = "ad1836", |
233 | .max_speed_hz = 16, | 235 | .max_speed_hz = 16, |
234 | .bus_num = 1, | 236 | .bus_num = 1, |
235 | .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, | 237 | .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, |
@@ -237,23 +239,6 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { | |||
237 | }, | 239 | }, |
238 | #endif | 240 | #endif |
239 | 241 | ||
240 | #if defined(CONFIG_PBX) | ||
241 | { | ||
242 | .modalias = "fxs-spi", | ||
243 | .max_speed_hz = 4, | ||
244 | .bus_num = 1, | ||
245 | .chip_select = 3, | ||
246 | .controller_data = &spi_si3xxx_chip_info, | ||
247 | }, | ||
248 | |||
249 | { | ||
250 | .modalias = "fxo-spi", | ||
251 | .max_speed_hz = 4, | ||
252 | .bus_num = 1, | ||
253 | .chip_select = 2, | ||
254 | .controller_data = &spi_si3xxx_chip_info, | ||
255 | }, | ||
256 | #endif | ||
257 | }; | 242 | }; |
258 | 243 | ||
259 | /* SPI (0) */ | 244 | /* SPI (0) */ |
diff --git a/arch/blackfin/mach-bf533/boards/blackstamp.c b/arch/blackfin/mach-bf533/boards/blackstamp.c index 9ecdc361fa6d..8208d67e2c97 100644 --- a/arch/blackfin/mach-bf533/boards/blackstamp.c +++ b/arch/blackfin/mach-bf533/boards/blackstamp.c | |||
@@ -48,6 +48,14 @@ static struct platform_device rtc_device = { | |||
48 | * Driver needs to know address, irq and flag pin. | 48 | * Driver needs to know address, irq and flag pin. |
49 | */ | 49 | */ |
50 | #if defined(CONFIG_SMC91X) || defined(CONFIG_SMC91X_MODULE) | 50 | #if defined(CONFIG_SMC91X) || defined(CONFIG_SMC91X_MODULE) |
51 | #include <linux/smc91x.h> | ||
52 | |||
53 | static struct smc91x_platdata smc91x_info = { | ||
54 | .flags = SMC91X_USE_16BIT | SMC91X_NOWAIT, | ||
55 | .leda = RPC_LED_100_10, | ||
56 | .ledb = RPC_LED_TX_RX, | ||
57 | }; | ||
58 | |||
51 | static struct resource smc91x_resources[] = { | 59 | static struct resource smc91x_resources[] = { |
52 | { | 60 | { |
53 | .name = "smc91x-regs", | 61 | .name = "smc91x-regs", |
@@ -66,6 +74,9 @@ static struct platform_device smc91x_device = { | |||
66 | .id = 0, | 74 | .id = 0, |
67 | .num_resources = ARRAY_SIZE(smc91x_resources), | 75 | .num_resources = ARRAY_SIZE(smc91x_resources), |
68 | .resource = smc91x_resources, | 76 | .resource = smc91x_resources, |
77 | .dev = { | ||
78 | .platform_data = &smc91x_info, | ||
79 | }, | ||
69 | }; | 80 | }; |
70 | #endif | 81 | #endif |
71 | 82 | ||
diff --git a/arch/blackfin/mach-bf533/boards/cm_bf533.c b/arch/blackfin/mach-bf533/boards/cm_bf533.c index 1443e92d8b62..7443b26c80c5 100644 --- a/arch/blackfin/mach-bf533/boards/cm_bf533.c +++ b/arch/blackfin/mach-bf533/boards/cm_bf533.c | |||
@@ -31,8 +31,10 @@ | |||
31 | #include <linux/platform_device.h> | 31 | #include <linux/platform_device.h> |
32 | #include <linux/mtd/mtd.h> | 32 | #include <linux/mtd/mtd.h> |
33 | #include <linux/mtd/partitions.h> | 33 | #include <linux/mtd/partitions.h> |
34 | #include <linux/mtd/physmap.h> | ||
34 | #include <linux/spi/spi.h> | 35 | #include <linux/spi/spi.h> |
35 | #include <linux/spi/flash.h> | 36 | #include <linux/spi/flash.h> |
37 | #include <linux/spi/mmc_spi.h> | ||
36 | #if defined(CONFIG_USB_ISP1362_HCD) || defined(CONFIG_USB_ISP1362_HCD_MODULE) | 38 | #if defined(CONFIG_USB_ISP1362_HCD) || defined(CONFIG_USB_ISP1362_HCD_MODULE) |
37 | #include <linux/usb/isp1362.h> | 39 | #include <linux/usb/isp1362.h> |
38 | #endif | 40 | #endif |
@@ -130,7 +132,7 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { | |||
130 | 132 | ||
131 | #if defined(CONFIG_SND_BLACKFIN_AD1836) || defined(CONFIG_SND_BLACKFIN_AD1836_MODULE) | 133 | #if defined(CONFIG_SND_BLACKFIN_AD1836) || defined(CONFIG_SND_BLACKFIN_AD1836_MODULE) |
132 | { | 134 | { |
133 | .modalias = "ad1836-spi", | 135 | .modalias = "ad1836", |
134 | .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */ | 136 | .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */ |
135 | .bus_num = 0, | 137 | .bus_num = 0, |
136 | .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, | 138 | .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, |
@@ -141,9 +143,9 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { | |||
141 | #if defined(CONFIG_MMC_SPI) || defined(CONFIG_MMC_SPI_MODULE) | 143 | #if defined(CONFIG_MMC_SPI) || defined(CONFIG_MMC_SPI_MODULE) |
142 | { | 144 | { |
143 | .modalias = "mmc_spi", | 145 | .modalias = "mmc_spi", |
144 | .max_speed_hz = 25000000, /* max spi clock (SCK) speed in HZ */ | 146 | .max_speed_hz = 20000000, /* max spi clock (SCK) speed in HZ */ |
145 | .bus_num = 0, | 147 | .bus_num = 0, |
146 | .chip_select = 5, | 148 | .chip_select = 1, |
147 | .controller_data = &mmc_spi_chip_info, | 149 | .controller_data = &mmc_spi_chip_info, |
148 | .mode = SPI_MODE_3, | 150 | .mode = SPI_MODE_3, |
149 | }, | 151 | }, |
@@ -195,6 +197,14 @@ static struct platform_device rtc_device = { | |||
195 | #endif | 197 | #endif |
196 | 198 | ||
197 | #if defined(CONFIG_SMC91X) || defined(CONFIG_SMC91X_MODULE) | 199 | #if defined(CONFIG_SMC91X) || defined(CONFIG_SMC91X_MODULE) |
200 | #include <linux/smc91x.h> | ||
201 | |||
202 | static struct smc91x_platdata smc91x_info = { | ||
203 | .flags = SMC91X_USE_16BIT | SMC91X_NOWAIT, | ||
204 | .leda = RPC_LED_100_10, | ||
205 | .ledb = RPC_LED_TX_RX, | ||
206 | }; | ||
207 | |||
198 | static struct resource smc91x_resources[] = { | 208 | static struct resource smc91x_resources[] = { |
199 | { | 209 | { |
200 | .start = 0x20200300, | 210 | .start = 0x20200300, |
@@ -211,6 +221,43 @@ static struct platform_device smc91x_device = { | |||
211 | .id = 0, | 221 | .id = 0, |
212 | .num_resources = ARRAY_SIZE(smc91x_resources), | 222 | .num_resources = ARRAY_SIZE(smc91x_resources), |
213 | .resource = smc91x_resources, | 223 | .resource = smc91x_resources, |
224 | .dev = { | ||
225 | .platform_data = &smc91x_info, | ||
226 | }, | ||
227 | }; | ||
228 | #endif | ||
229 | |||
230 | #if defined(CONFIG_SMSC911X) || defined(CONFIG_SMSC911X_MODULE) | ||
231 | #include <linux/smsc911x.h> | ||
232 | |||
233 | static struct resource smsc911x_resources[] = { | ||
234 | { | ||
235 | .name = "smsc911x-memory", | ||
236 | .start = 0x20308000, | ||
237 | .end = 0x20308000 + 0xFF, | ||
238 | .flags = IORESOURCE_MEM, | ||
239 | }, { | ||
240 | .start = IRQ_PF8, | ||
241 | .end = IRQ_PF8, | ||
242 | .flags = IORESOURCE_IRQ | IORESOURCE_IRQ_LOWLEVEL, | ||
243 | }, | ||
244 | }; | ||
245 | |||
246 | static struct smsc911x_platform_config smsc911x_config = { | ||
247 | .flags = SMSC911X_USE_16BIT, | ||
248 | .irq_polarity = SMSC911X_IRQ_POLARITY_ACTIVE_LOW, | ||
249 | .irq_type = SMSC911X_IRQ_TYPE_OPEN_DRAIN, | ||
250 | .phy_interface = PHY_INTERFACE_MODE_MII, | ||
251 | }; | ||
252 | |||
253 | static struct platform_device smsc911x_device = { | ||
254 | .name = "smsc911x", | ||
255 | .id = 0, | ||
256 | .num_resources = ARRAY_SIZE(smsc911x_resources), | ||
257 | .resource = smsc911x_resources, | ||
258 | .dev = { | ||
259 | .platform_data = &smsc911x_config, | ||
260 | }, | ||
214 | }; | 261 | }; |
215 | #endif | 262 | #endif |
216 | 263 | ||
@@ -324,6 +371,68 @@ static struct platform_device isp1362_hcd_device = { | |||
324 | }; | 371 | }; |
325 | #endif | 372 | #endif |
326 | 373 | ||
374 | |||
375 | #if defined(CONFIG_USB_NET2272) || defined(CONFIG_USB_NET2272_MODULE) | ||
376 | static struct resource net2272_bfin_resources[] = { | ||
377 | { | ||
378 | .start = 0x20300000, | ||
379 | .end = 0x20300000 + 0x100, | ||
380 | .flags = IORESOURCE_MEM, | ||
381 | }, { | ||
382 | .start = IRQ_PF6, | ||
383 | .end = IRQ_PF6, | ||
384 | .flags = IORESOURCE_IRQ | IORESOURCE_IRQ_HIGHLEVEL, | ||
385 | }, | ||
386 | }; | ||
387 | |||
388 | static struct platform_device net2272_bfin_device = { | ||
389 | .name = "net2272", | ||
390 | .id = -1, | ||
391 | .num_resources = ARRAY_SIZE(net2272_bfin_resources), | ||
392 | .resource = net2272_bfin_resources, | ||
393 | }; | ||
394 | #endif | ||
395 | |||
396 | |||
397 | |||
398 | #if defined(CONFIG_MTD_PHYSMAP) || defined(CONFIG_MTD_PHYSMAP_MODULE) | ||
399 | static struct mtd_partition para_partitions[] = { | ||
400 | { | ||
401 | .name = "bootloader(nor)", | ||
402 | .size = 0x40000, | ||
403 | .offset = 0, | ||
404 | }, { | ||
405 | .name = "linux+rootfs(nor)", | ||
406 | .size = MTDPART_SIZ_FULL, | ||
407 | .offset = MTDPART_OFS_APPEND, | ||
408 | }, | ||
409 | }; | ||
410 | |||
411 | static struct physmap_flash_data para_flash_data = { | ||
412 | .width = 2, | ||
413 | .parts = para_partitions, | ||
414 | .nr_parts = ARRAY_SIZE(para_partitions), | ||
415 | }; | ||
416 | |||
417 | static struct resource para_flash_resource = { | ||
418 | .start = 0x20000000, | ||
419 | .end = 0x201fffff, | ||
420 | .flags = IORESOURCE_MEM, | ||
421 | }; | ||
422 | |||
423 | static struct platform_device para_flash_device = { | ||
424 | .name = "physmap-flash", | ||
425 | .id = 0, | ||
426 | .dev = { | ||
427 | .platform_data = ¶_flash_data, | ||
428 | }, | ||
429 | .num_resources = 1, | ||
430 | .resource = ¶_flash_resource, | ||
431 | }; | ||
432 | #endif | ||
433 | |||
434 | |||
435 | |||
327 | static const unsigned int cclk_vlev_datasheet[] = | 436 | static const unsigned int cclk_vlev_datasheet[] = |
328 | { | 437 | { |
329 | VRPAIR(VLEV_085, 250000000), | 438 | VRPAIR(VLEV_085, 250000000), |
@@ -382,10 +491,22 @@ static struct platform_device *cm_bf533_devices[] __initdata = { | |||
382 | &smc91x_device, | 491 | &smc91x_device, |
383 | #endif | 492 | #endif |
384 | 493 | ||
494 | #if defined(CONFIG_SMSC911X) || defined(CONFIG_SMSC911X_MODULE) | ||
495 | &smsc911x_device, | ||
496 | #endif | ||
497 | |||
498 | #if defined(CONFIG_USB_NET2272) || defined(CONFIG_USB_NET2272_MODULE) | ||
499 | &net2272_bfin_device, | ||
500 | #endif | ||
501 | |||
385 | #if defined(CONFIG_SPI_BFIN) || defined(CONFIG_SPI_BFIN_MODULE) | 502 | #if defined(CONFIG_SPI_BFIN) || defined(CONFIG_SPI_BFIN_MODULE) |
386 | &bfin_spi0_device, | 503 | &bfin_spi0_device, |
387 | #endif | 504 | #endif |
388 | 505 | ||
506 | #if defined(CONFIG_MTD_PHYSMAP) || defined(CONFIG_MTD_PHYSMAP_MODULE) | ||
507 | ¶_flash_device, | ||
508 | #endif | ||
509 | |||
389 | &bfin_gpios_device, | 510 | &bfin_gpios_device, |
390 | }; | 511 | }; |
391 | 512 | ||
diff --git a/arch/blackfin/mach-bf533/boards/ezkit.c b/arch/blackfin/mach-bf533/boards/ezkit.c index 4e3e511bf146..fd518e383b79 100644 --- a/arch/blackfin/mach-bf533/boards/ezkit.c +++ b/arch/blackfin/mach-bf533/boards/ezkit.c | |||
@@ -67,6 +67,14 @@ static struct platform_device bfin_fb_adv7393_device = { | |||
67 | * Driver needs to know address, irq and flag pin. | 67 | * Driver needs to know address, irq and flag pin. |
68 | */ | 68 | */ |
69 | #if defined(CONFIG_SMC91X) || defined(CONFIG_SMC91X_MODULE) | 69 | #if defined(CONFIG_SMC91X) || defined(CONFIG_SMC91X_MODULE) |
70 | #include <linux/smc91x.h> | ||
71 | |||
72 | static struct smc91x_platdata smc91x_info = { | ||
73 | .flags = SMC91X_USE_16BIT | SMC91X_NOWAIT, | ||
74 | .leda = RPC_LED_100_10, | ||
75 | .ledb = RPC_LED_TX_RX, | ||
76 | }; | ||
77 | |||
70 | static struct resource smc91x_resources[] = { | 78 | static struct resource smc91x_resources[] = { |
71 | { | 79 | { |
72 | .name = "smc91x-regs", | 80 | .name = "smc91x-regs", |
@@ -84,6 +92,9 @@ static struct platform_device smc91x_device = { | |||
84 | .id = 0, | 92 | .id = 0, |
85 | .num_resources = ARRAY_SIZE(smc91x_resources), | 93 | .num_resources = ARRAY_SIZE(smc91x_resources), |
86 | .resource = smc91x_resources, | 94 | .resource = smc91x_resources, |
95 | .dev = { | ||
96 | .platform_data = &smc91x_info, | ||
97 | }, | ||
87 | }; | 98 | }; |
88 | #endif | 99 | #endif |
89 | 100 | ||
@@ -263,7 +274,7 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { | |||
263 | 274 | ||
264 | #if defined(CONFIG_SND_BLACKFIN_AD1836) || defined(CONFIG_SND_BLACKFIN_AD1836_MODULE) | 275 | #if defined(CONFIG_SND_BLACKFIN_AD1836) || defined(CONFIG_SND_BLACKFIN_AD1836_MODULE) |
265 | { | 276 | { |
266 | .modalias = "ad1836-spi", | 277 | .modalias = "ad1836", |
267 | .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */ | 278 | .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */ |
268 | .bus_num = 0, | 279 | .bus_num = 0, |
269 | .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, | 280 | .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, |
diff --git a/arch/blackfin/mach-bf533/boards/stamp.c b/arch/blackfin/mach-bf533/boards/stamp.c index 3d743ccaff6a..729fd7c26336 100644 --- a/arch/blackfin/mach-bf533/boards/stamp.c +++ b/arch/blackfin/mach-bf533/boards/stamp.c | |||
@@ -35,6 +35,7 @@ | |||
35 | #include <linux/mtd/physmap.h> | 35 | #include <linux/mtd/physmap.h> |
36 | #include <linux/spi/spi.h> | 36 | #include <linux/spi/spi.h> |
37 | #include <linux/spi/flash.h> | 37 | #include <linux/spi/flash.h> |
38 | #include <linux/spi/mmc_spi.h> | ||
38 | #if defined(CONFIG_USB_ISP1362_HCD) || defined(CONFIG_USB_ISP1362_HCD_MODULE) | 39 | #if defined(CONFIG_USB_ISP1362_HCD) || defined(CONFIG_USB_ISP1362_HCD_MODULE) |
39 | #include <linux/usb/isp1362.h> | 40 | #include <linux/usb/isp1362.h> |
40 | #endif | 41 | #endif |
@@ -62,6 +63,14 @@ static struct platform_device rtc_device = { | |||
62 | * Driver needs to know address, irq and flag pin. | 63 | * Driver needs to know address, irq and flag pin. |
63 | */ | 64 | */ |
64 | #if defined(CONFIG_SMC91X) || defined(CONFIG_SMC91X_MODULE) | 65 | #if defined(CONFIG_SMC91X) || defined(CONFIG_SMC91X_MODULE) |
66 | #include <linux/smc91x.h> | ||
67 | |||
68 | static struct smc91x_platdata smc91x_info = { | ||
69 | .flags = SMC91X_USE_16BIT | SMC91X_NOWAIT, | ||
70 | .leda = RPC_LED_100_10, | ||
71 | .ledb = RPC_LED_TX_RX, | ||
72 | }; | ||
73 | |||
65 | static struct resource smc91x_resources[] = { | 74 | static struct resource smc91x_resources[] = { |
66 | { | 75 | { |
67 | .name = "smc91x-regs", | 76 | .name = "smc91x-regs", |
@@ -80,6 +89,9 @@ static struct platform_device smc91x_device = { | |||
80 | .id = 0, | 89 | .id = 0, |
81 | .num_resources = ARRAY_SIZE(smc91x_resources), | 90 | .num_resources = ARRAY_SIZE(smc91x_resources), |
82 | .resource = smc91x_resources, | 91 | .resource = smc91x_resources, |
92 | .dev = { | ||
93 | .platform_data = &smc91x_info, | ||
94 | }, | ||
83 | }; | 95 | }; |
84 | #endif | 96 | #endif |
85 | 97 | ||
@@ -207,19 +219,38 @@ static struct bfin5xx_spi_chip ad1836_spi_chip_info = { | |||
207 | }; | 219 | }; |
208 | #endif | 220 | #endif |
209 | 221 | ||
210 | #if defined(CONFIG_PBX) | 222 | #if defined(CONFIG_SPI_SPIDEV) || defined(CONFIG_SPI_SPIDEV_MODULE) |
211 | static struct bfin5xx_spi_chip spi_si3xxx_chip_info = { | 223 | static struct bfin5xx_spi_chip spidev_chip_info = { |
212 | .ctl_reg = 0x4, /* send zero */ | 224 | .enable_dma = 0, |
213 | .enable_dma = 0, | 225 | .bits_per_word = 8, |
214 | .bits_per_word = 8, | ||
215 | .cs_change_per_word = 1, | ||
216 | }; | 226 | }; |
217 | #endif | 227 | #endif |
218 | 228 | ||
219 | #if defined(CONFIG_SPI_SPIDEV) || defined(CONFIG_SPI_SPIDEV_MODULE) | 229 | #if defined(CONFIG_MMC_SPI) || defined(CONFIG_MMC_SPI_MODULE) |
220 | static struct bfin5xx_spi_chip spidev_chip_info = { | 230 | #define MMC_SPI_CARD_DETECT_INT IRQ_PF5 |
231 | static int bfin_mmc_spi_init(struct device *dev, | ||
232 | irqreturn_t (*detect_int)(int, void *), void *data) | ||
233 | { | ||
234 | return request_irq(MMC_SPI_CARD_DETECT_INT, detect_int, | ||
235 | IRQF_TRIGGER_FALLING | IRQF_TRIGGER_RISING, | ||
236 | "mmc-spi-detect", data); | ||
237 | } | ||
238 | |||
239 | static void bfin_mmc_spi_exit(struct device *dev, void *data) | ||
240 | { | ||
241 | free_irq(MMC_SPI_CARD_DETECT_INT, data); | ||
242 | } | ||
243 | |||
244 | static struct mmc_spi_platform_data bfin_mmc_spi_pdata = { | ||
245 | .init = bfin_mmc_spi_init, | ||
246 | .exit = bfin_mmc_spi_exit, | ||
247 | .detect_delay = 100, /* msecs */ | ||
248 | }; | ||
249 | |||
250 | static struct bfin5xx_spi_chip mmc_spi_chip_info = { | ||
221 | .enable_dma = 0, | 251 | .enable_dma = 0, |
222 | .bits_per_word = 8, | 252 | .bits_per_word = 8, |
253 | .pio_interrupt = 0, | ||
223 | }; | 254 | }; |
224 | #endif | 255 | #endif |
225 | 256 | ||
@@ -250,33 +281,14 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { | |||
250 | 281 | ||
251 | #if defined(CONFIG_SND_BLACKFIN_AD1836) || defined(CONFIG_SND_BLACKFIN_AD1836_MODULE) | 282 | #if defined(CONFIG_SND_BLACKFIN_AD1836) || defined(CONFIG_SND_BLACKFIN_AD1836_MODULE) |
252 | { | 283 | { |
253 | .modalias = "ad1836-spi", | 284 | .modalias = "ad1836", |
254 | .max_speed_hz = 31250000, /* max spi clock (SCK) speed in HZ */ | 285 | .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */ |
255 | .bus_num = 0, | 286 | .bus_num = 0, |
256 | .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, | 287 | .chip_select = CONFIG_SND_BLACKFIN_SPI_PFBIT, |
257 | .controller_data = &ad1836_spi_chip_info, | 288 | .controller_data = &ad1836_spi_chip_info, |
258 | }, | 289 | }, |
259 | #endif | 290 | #endif |
260 | 291 | ||
261 | #if defined(CONFIG_PBX) | ||
262 | { | ||
263 | .modalias = "fxs-spi", | ||
264 | .max_speed_hz = 12500000, /* max spi clock (SCK) speed in HZ */ | ||
265 | .bus_num = 0, | ||
266 | .chip_select = 8 - CONFIG_J11_JUMPER, | ||
267 | .controller_data = &spi_si3xxx_chip_info, | ||
268 | .mode = SPI_MODE_3, | ||
269 | }, | ||
270 | { | ||
271 | .modalias = "fxo-spi", | ||
272 | .max_speed_hz = 12500000, /* max spi clock (SCK) speed in HZ */ | ||
273 | .bus_num = 0, | ||
274 | .chip_select = 8 - CONFIG_J19_JUMPER, | ||
275 | .controller_data = &spi_si3xxx_chip_info, | ||
276 | .mode = SPI_MODE_3, | ||
277 | }, | ||
278 | #endif | ||
279 | |||
280 | #if defined(CONFIG_SPI_SPIDEV) || defined(CONFIG_SPI_SPIDEV_MODULE) | 292 | #if defined(CONFIG_SPI_SPIDEV) || defined(CONFIG_SPI_SPIDEV_MODULE) |
281 | { | 293 | { |
282 | .modalias = "spidev", | 294 | .modalias = "spidev", |
@@ -286,6 +298,17 @@ static struct spi_board_info bfin_spi_board_info[] __initdata = { | |||
286 | .controller_data = &spidev_chip_info, | 298 | .controller_data = &spidev_chip_info, |
287 | }, | 299 | }, |
288 | #endif | 300 | #endif |
301 | #if defined(CONFIG_MMC_SPI) || defined(CONFIG_MMC_SPI_MODULE) | ||
302 | { | ||
303 | .modalias = "mmc_spi", | ||
304 | .max_speed_hz = 20000000, /* max spi clock (SCK) speed in HZ */ | ||
305 | .bus_num = 0, | ||
306 | .chip_select = 4, | ||
307 | .platform_data = &bfin_mmc_spi_pdata, | ||
308 | .controller_data = &mmc_spi_chip_info, | ||
309 | .mode = SPI_MODE_3, | ||
310 | }, | ||
311 | #endif | ||
289 | }; | 312 | }; |
290 | 313 | ||
291 | #if defined(CONFIG_SPI_BFIN) || defined(CONFIG_SPI_BFIN_MODULE) | 314 | #if defined(CONFIG_SPI_BFIN) || defined(CONFIG_SPI_BFIN_MODULE) |
@@ -458,7 +481,7 @@ static struct i2c_board_info __initdata bfin_i2c_board_info[] = { | |||
458 | I2C_BOARD_INFO("pcf8574_lcd", 0x22), | 481 | I2C_BOARD_INFO("pcf8574_lcd", 0x22), |
459 | }, | 482 | }, |
460 | #endif | 483 | #endif |
461 | #if defined(CONFIG_TWI_KEYPAD) || defined(CONFIG_TWI_KEYPAD_MODULE) | 484 | #if defined(CONFIG_INPUT_PCF8574) || defined(CONFIG_INPUT_PCF8574_MODULE) |
462 | { | 485 | { |
463 | I2C_BOARD_INFO("pcf8574_keypad", 0x27), | 486 | I2C_BOARD_INFO("pcf8574_keypad", 0x27), |
464 | .irq = 39, | 487 | .irq = 39, |
diff --git a/arch/blackfin/mach-bf533/dma.c b/arch/blackfin/mach-bf533/dma.c index 0a6eb8f24d98..7a443c37fb9f 100644 --- a/arch/blackfin/mach-bf533/dma.c +++ b/arch/blackfin/mach-bf533/dma.c | |||
@@ -76,12 +76,12 @@ int channel2irq(unsigned int channel) | |||
76 | ret_irq = IRQ_SPI; | 76 | ret_irq = IRQ_SPI; |
77 | break; | 77 | break; |
78 | 78 | ||
79 | case CH_UART_RX: | 79 | case CH_UART0_RX: |
80 | ret_irq = IRQ_UART_RX; | 80 | ret_irq = IRQ_UART0_RX; |
81 | break; | 81 | break; |
82 | 82 | ||
83 | case CH_UART_TX: | 83 | case CH_UART0_TX: |
84 | ret_irq = IRQ_UART_TX; | 84 | ret_irq = IRQ_UART0_TX; |
85 | break; | 85 | break; |
86 | 86 | ||
87 | case CH_MEM_STREAM0_SRC: | 87 | case CH_MEM_STREAM0_SRC: |
diff --git a/arch/blackfin/mach-bf533/include/mach/bfin_serial_5xx.h b/arch/blackfin/mach-bf533/include/mach/bfin_serial_5xx.h index 4062e24e759b..6965b4088c44 100644 --- a/arch/blackfin/mach-bf533/include/mach/bfin_serial_5xx.h +++ b/arch/blackfin/mach-bf533/include/mach/bfin_serial_5xx.h | |||
@@ -131,11 +131,11 @@ struct bfin_serial_res { | |||
131 | struct bfin_serial_res bfin_serial_resource[] = { | 131 | struct bfin_serial_res bfin_serial_resource[] = { |
132 | { | 132 | { |
133 | 0xFFC00400, | 133 | 0xFFC00400, |
134 | IRQ_UART_RX, | 134 | IRQ_UART0_RX, |
135 | IRQ_UART_ERROR, | 135 | IRQ_UART0_ERROR, |
136 | #ifdef CONFIG_SERIAL_BFIN_DMA | 136 | #ifdef CONFIG_SERIAL_BFIN_DMA |
137 | CH_UART_TX, | 137 | CH_UART0_TX, |
138 | CH_UART_RX, | 138 | CH_UART0_RX, |
139 | #endif | 139 | #endif |
140 | #ifdef CONFIG_SERIAL_BFIN_CTSRTS | 140 | #ifdef CONFIG_SERIAL_BFIN_CTSRTS |
141 | CONFIG_UART0_CTS_PIN, | 141 | CONFIG_UART0_CTS_PIN, |
diff --git a/arch/blackfin/mach-bf533/include/mach/blackfin.h b/arch/blackfin/mach-bf533/include/mach/blackfin.h index 39aa175f19f5..499e897a4f4f 100644 --- a/arch/blackfin/mach-bf533/include/mach/blackfin.h +++ b/arch/blackfin/mach-bf533/include/mach/blackfin.h | |||
@@ -43,13 +43,6 @@ | |||
43 | 43 | ||
44 | #define BFIN_UART_NR_PORTS 1 | 44 | #define BFIN_UART_NR_PORTS 1 |
45 | 45 | ||
46 | #define CH_UART_RX CH_UART0_RX | ||
47 | #define CH_UART_TX CH_UART0_TX | ||
48 | |||
49 | #define IRQ_UART_ERROR IRQ_UART0_ERROR | ||
50 | #define IRQ_UART_RX IRQ_UART0_RX | ||
51 | #define IRQ_UART_TX IRQ_UART0_TX | ||
52 | |||
53 | #define OFFSET_THR 0x00 /* Transmit Holding register */ | 46 | #define OFFSET_THR 0x00 /* Transmit Holding register */ |
54 | #define OFFSET_RBR 0x00 /* Receive Buffer register */ | 47 | #define OFFSET_RBR 0x00 /* Receive Buffer register */ |
55 | #define OFFSET_DLL 0x00 /* Divisor Latch (Low-Byte) */ | 48 | #define OFFSET_DLL 0x00 /* Divisor Latch (Low-Byte) */ |