10 #include <linux/device.h>
12 #include <linux/export.h>
19 #if defined(CONFIG_USB_ISP1362_HCD) || defined(CONFIG_USB_ISP1362_HCD_MODULE)
35 #if defined(CONFIG_SPI_BFIN5XX) || defined(CONFIG_SPI_BFIN5XX_MODULE)
38 #if defined(CONFIG_MTD_M25P80) || defined(CONFIG_MTD_M25P80_MODULE)
41 .
name =
"bootloader(spi)",
46 .name =
"linux kernel(spi)",
50 .name =
"file system(spi)",
58 .parts = bfin_spi_flash_partitions,
59 .nr_parts =
ARRAY_SIZE(bfin_spi_flash_partitions),
69 #if defined(CONFIG_MMC_SPI) || defined(CONFIG_MMC_SPI_MODULE)
76 #if defined(CONFIG_MTD_M25P80) || defined(CONFIG_MTD_M25P80_MODULE)
80 .max_speed_hz = 25000000,
83 .platform_data = &bfin_spi_flash_data,
84 .controller_data = &spi_flash_chip_info,
89 #if defined(CONFIG_SND_BF5XX_SOC_AD183X) || defined(CONFIG_SND_BF5XX_SOC_AD183X_MODULE)
92 .max_speed_hz = 3125000,
98 #if defined(CONFIG_MMC_SPI) || defined(CONFIG_MMC_SPI_MODULE)
100 .modalias =
"mmc_spi",
101 .max_speed_hz = 20000000,
104 .controller_data = &mmc_spi_chip_info,
111 static struct resource bfin_spi0_resource[] = {
139 .num_resources =
ARRAY_SIZE(bfin_spi0_resource),
140 .resource = bfin_spi0_resource,
142 .platform_data = &bfin_spi0_info,
147 #if defined(CONFIG_RTC_DRV_BFIN) || defined(CONFIG_RTC_DRV_BFIN_MODULE)
154 #if defined(CONFIG_FB_HITACHI_TX09) || defined(CONFIG_FB_HITACHI_TX09_MODULE)
156 .
name =
"hitachi-tx09",
160 #if defined(CONFIG_SMC91X) || defined(CONFIG_SMC91X_MODULE)
169 static struct resource smc91x_resources[] = {
172 .end = 0x20200300 + 16,
184 .num_resources =
ARRAY_SIZE(smc91x_resources),
185 .resource = smc91x_resources,
187 .platform_data = &smc91x_info,
192 #if defined(CONFIG_USB_ISP1362_HCD) || defined(CONFIG_USB_ISP1362_HCD_MODULE)
193 static struct resource isp1362_hcd_resources[] = {
214 .int_edge_triggered = 0,
215 .remote_wakeup_connected = 0,
216 .no_power_switching = 1,
217 .power_switching_mode = 0,
221 .
name =
"isp1362-hcd",
224 .platform_data = &isp1362_priv,
226 .num_resources =
ARRAY_SIZE(isp1362_hcd_resources),
227 .resource = isp1362_hcd_resources,
231 #if defined(CONFIG_USB_NET2272) || defined(CONFIG_USB_NET2272_MODULE)
232 static struct resource net2272_bfin_resources[] = {
235 .end = 0x20200000 + 0x100,
247 .num_resources =
ARRAY_SIZE(net2272_bfin_resources),
248 .resource = net2272_bfin_resources,
252 #if defined(CONFIG_MTD_GPIO_ADDR) || defined(CONFIG_MTD_GPIO_ADDR_MODULE)
255 .
name =
"bootloader(nor)",
259 .name =
"linux kernel(nor)",
263 .name =
"file system(nor)",
271 .parts = cm_partitions,
275 static unsigned cm_flash_gpios[] = {
GPIO_PH0 };
277 static struct resource cm_flash_resource[] = {
284 .start = (
unsigned long)cm_flash_gpios,
291 .
name =
"gpio-addr-flash",
294 .platform_data = &cm_flash_data,
296 .num_resources =
ARRAY_SIZE(cm_flash_resource),
297 .resource = cm_flash_resource,
301 #if defined(CONFIG_SERIAL_BFIN) || defined(CONFIG_SERIAL_BFIN_MODULE)
302 #ifdef CONFIG_SERIAL_BFIN_UART0
303 static struct resource bfin_uart0_resources[] = {
336 static unsigned short bfin_uart0_peripherals[] = {
343 .num_resources =
ARRAY_SIZE(bfin_uart0_resources),
344 .resource = bfin_uart0_resources,
346 .platform_data = &bfin_uart0_peripherals,
350 #ifdef CONFIG_SERIAL_BFIN_UART1
351 static struct resource bfin_uart1_resources[] = {
384 static unsigned short bfin_uart1_peripherals[] = {
391 .num_resources =
ARRAY_SIZE(bfin_uart1_resources),
392 .resource = bfin_uart1_resources,
394 .platform_data = &bfin_uart1_peripherals,
400 #if defined(CONFIG_BFIN_SIR) || defined(CONFIG_BFIN_SIR_MODULE)
401 #ifdef CONFIG_BFIN_SIR0
402 static struct resource bfin_sir0_resources[] = {
422 .num_resources =
ARRAY_SIZE(bfin_sir0_resources),
423 .resource = bfin_sir0_resources,
426 #ifdef CONFIG_BFIN_SIR1
427 static struct resource bfin_sir1_resources[] = {
447 .num_resources =
ARRAY_SIZE(bfin_sir1_resources),
448 .resource = bfin_sir1_resources,
453 #if defined(CONFIG_I2C_BLACKFIN_TWI) || defined(CONFIG_I2C_BLACKFIN_TWI_MODULE)
456 static struct resource bfin_twi0_resource[] = {
470 .
name =
"i2c-bfin-twi",
472 .num_resources =
ARRAY_SIZE(bfin_twi0_resource),
473 .resource = bfin_twi0_resource,
475 .platform_data = &bfin_twi0_pins,
480 #if defined(CONFIG_SERIAL_BFIN_SPORT) || defined(CONFIG_SERIAL_BFIN_SPORT_MODULE)
481 #ifdef CONFIG_SERIAL_BFIN_SPORT0_UART
482 static struct resource bfin_sport0_uart_resources[] = {
500 static unsigned short bfin_sport0_peripherals[] = {
506 .
name =
"bfin-sport-uart",
508 .num_resources =
ARRAY_SIZE(bfin_sport0_uart_resources),
509 .resource = bfin_sport0_uart_resources,
511 .platform_data = &bfin_sport0_peripherals,
515 #ifdef CONFIG_SERIAL_BFIN_SPORT1_UART
516 static struct resource bfin_sport1_uart_resources[] = {
534 static unsigned short bfin_sport1_peripherals[] = {
540 .
name =
"bfin-sport-uart",
542 .num_resources =
ARRAY_SIZE(bfin_sport1_uart_resources),
543 .resource = bfin_sport1_uart_resources,
545 .platform_data = &bfin_sport1_peripherals,
551 #if defined(CONFIG_BFIN_MAC) || defined(CONFIG_BFIN_MAC_MODULE)
553 static const unsigned short bfin_mac_peripherals[] =
P_MII0;
564 .phydev_data = bfin_phydev_data,
566 .mac_peripherals = bfin_mac_peripherals,
570 .
name =
"bfin_mii_bus",
572 .platform_data = &bfin_mii_bus_data,
579 .platform_data = &bfin_mii_bus,
584 #if defined(CONFIG_PATA_PLATFORM) || defined(CONFIG_PATA_PLATFORM_MODULE)
585 #define PATA_INT IRQ_PF14
592 static struct resource bfin_pata_resources[] = {
611 .
name =
"pata_platform",
613 .num_resources =
ARRAY_SIZE(bfin_pata_resources),
614 .resource = bfin_pata_resources,
616 .platform_data = &bfin_pata_platform_data,
621 static const unsigned int cclk_vlev_datasheet[] =
636 .tuple_tab = cclk_vlev_datasheet,
638 .vr_settling_time = 25 ,
644 .platform_data = &bfin_dmpc_vreg_data,
652 #if defined(CONFIG_FB_HITACHI_TX09) || defined(CONFIG_FB_HITACHI_TX09_MODULE)
656 #if defined(CONFIG_RTC_DRV_BFIN) || defined(CONFIG_RTC_DRV_BFIN_MODULE)
660 #if defined(CONFIG_SERIAL_BFIN) || defined(CONFIG_SERIAL_BFIN_MODULE)
661 #ifdef CONFIG_SERIAL_BFIN_UART0
664 #ifdef CONFIG_SERIAL_BFIN_UART1
669 #if defined(CONFIG_BFIN_SIR) || defined(CONFIG_BFIN_SIR_MODULE)
670 #ifdef CONFIG_BFIN_SIR0
673 #ifdef CONFIG_BFIN_SIR1
678 #if defined(CONFIG_I2C_BLACKFIN_TWI) || defined(CONFIG_I2C_BLACKFIN_TWI_MODULE)
679 &i2c_bfin_twi_device,
682 #if defined(CONFIG_SERIAL_BFIN_SPORT) || defined(CONFIG_SERIAL_BFIN_SPORT_MODULE)
683 #ifdef CONFIG_SERIAL_BFIN_SPORT0_UART
684 &bfin_sport0_uart_device,
686 #ifdef CONFIG_SERIAL_BFIN_SPORT1_UART
687 &bfin_sport1_uart_device,
691 #if defined(CONFIG_USB_ISP1362_HCD) || defined(CONFIG_USB_ISP1362_HCD_MODULE)
695 #if defined(CONFIG_SMC91X) || defined(CONFIG_SMC91X_MODULE)
699 #if defined(CONFIG_BFIN_MAC) || defined(CONFIG_BFIN_MAC_MODULE)
704 #if defined(CONFIG_USB_NET2272) || defined(CONFIG_USB_NET2272_MODULE)
705 &net2272_bfin_device,
708 #if defined(CONFIG_SPI_BFIN5XX) || defined(CONFIG_SPI_BFIN5XX_MODULE)
712 #if defined(CONFIG_PATA_PLATFORM) || defined(CONFIG_PATA_PLATFORM_MODULE)
716 #if defined(CONFIG_MTD_GPIO_ADDR) || defined(CONFIG_MTD_GPIO_ADDR_MODULE)
721 static int __init net2272_init(
void)
723 #if defined(CONFIG_USB_NET2272) || defined(CONFIG_USB_NET2272_MODULE)
751 static int __init cm_bf537u_init(
void)
755 #if defined(CONFIG_SPI_BFIN5XX) || defined(CONFIG_SPI_BFIN5XX_MODULE)
759 #if defined(CONFIG_PATA_PLATFORM) || defined(CONFIG_PATA_PLATFORM_MODULE)
764 pr_warning(
"unable to configure net2272; it probably won't work\n");
771 static struct platform_device *cm_bf537u_early_devices[] __initdata = {
772 #if defined(CONFIG_SERIAL_BFIN_CONSOLE) || defined(CONFIG_EARLY_PRINTK)
773 #ifdef CONFIG_SERIAL_BFIN_UART0
776 #ifdef CONFIG_SERIAL_BFIN_UART1
781 #if defined(CONFIG_SERIAL_BFIN_SPORT_CONSOLE)
782 #ifdef CONFIG_SERIAL_BFIN_SPORT0_UART
783 &bfin_sport0_uart_device,
785 #ifdef CONFIG_SERIAL_BFIN_SPORT1_UART
786 &bfin_sport1_uart_device,