ezkit.c 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678
  1. /*
  2. * Copyright 2004-2009 Analog Devices Inc.
  3. * 2005 National ICT Australia (NICTA)
  4. * Aidan Williams <aidan@nicta.com.au>
  5. *
  6. * Licensed under the GPL-2 or later.
  7. */
  8. #include <linux/device.h>
  9. #include <linux/platform_device.h>
  10. #include <linux/mtd/mtd.h>
  11. #include <linux/mtd/partitions.h>
  12. #include <linux/mtd/physmap.h>
  13. #include <linux/spi/spi.h>
  14. #include <linux/irq.h>
  15. #include <linux/interrupt.h>
  16. #include <linux/gpio.h>
  17. #include <linux/delay.h>
  18. #include <asm/dma.h>
  19. #include <asm/bfin5xx_spi.h>
  20. #include <asm/portmux.h>
  21. #include <asm/dpmc.h>
  22. /*
  23. * Name the Board for the /proc/cpuinfo
  24. */
  25. const char bfin_board_name[] = "ADI BF561-EZKIT";
  26. #if IS_ENABLED(CONFIG_USB_ISP1760_HCD)
  27. #include <linux/usb/isp1760.h>
  28. static struct resource bfin_isp1760_resources[] = {
  29. [0] = {
  30. .start = 0x2C0F0000,
  31. .end = 0x203C0000 + 0xfffff,
  32. .flags = IORESOURCE_MEM,
  33. },
  34. [1] = {
  35. .start = IRQ_PF10,
  36. .end = IRQ_PF10,
  37. .flags = IORESOURCE_IRQ,
  38. },
  39. };
  40. static struct isp1760_platform_data isp1760_priv = {
  41. .is_isp1761 = 0,
  42. .bus_width_16 = 1,
  43. .port1_otg = 0,
  44. .analog_oc = 0,
  45. .dack_polarity_high = 0,
  46. .dreq_polarity_high = 0,
  47. };
  48. static struct platform_device bfin_isp1760_device = {
  49. .name = "isp1760",
  50. .id = 0,
  51. .dev = {
  52. .platform_data = &isp1760_priv,
  53. },
  54. .num_resources = ARRAY_SIZE(bfin_isp1760_resources),
  55. .resource = bfin_isp1760_resources,
  56. };
  57. #endif
  58. #if IS_ENABLED(CONFIG_USB_ISP1362_HCD)
  59. #include <linux/usb/isp1362.h>
  60. static struct resource isp1362_hcd_resources[] = {
  61. {
  62. .start = 0x2c060000,
  63. .end = 0x2c060000,
  64. .flags = IORESOURCE_MEM,
  65. }, {
  66. .start = 0x2c060004,
  67. .end = 0x2c060004,
  68. .flags = IORESOURCE_MEM,
  69. }, {
  70. .start = IRQ_PF8,
  71. .end = IRQ_PF8,
  72. .flags = IORESOURCE_IRQ | IORESOURCE_IRQ_LOWEDGE,
  73. },
  74. };
  75. static struct isp1362_platform_data isp1362_priv = {
  76. .sel15Kres = 1,
  77. .clknotstop = 0,
  78. .oc_enable = 0,
  79. .int_act_high = 0,
  80. .int_edge_triggered = 0,
  81. .remote_wakeup_connected = 0,
  82. .no_power_switching = 1,
  83. .power_switching_mode = 0,
  84. };
  85. static struct platform_device isp1362_hcd_device = {
  86. .name = "isp1362-hcd",
  87. .id = 0,
  88. .dev = {
  89. .platform_data = &isp1362_priv,
  90. },
  91. .num_resources = ARRAY_SIZE(isp1362_hcd_resources),
  92. .resource = isp1362_hcd_resources,
  93. };
  94. #endif
  95. #if IS_ENABLED(CONFIG_USB_NET2272)
  96. static struct resource net2272_bfin_resources[] = {
  97. {
  98. .start = 0x2C000000,
  99. .end = 0x2C000000 + 0x7F,
  100. .flags = IORESOURCE_MEM,
  101. }, {
  102. .start = 1,
  103. .flags = IORESOURCE_BUS,
  104. }, {
  105. .start = IRQ_PF10,
  106. .end = IRQ_PF10,
  107. .flags = IORESOURCE_IRQ | IORESOURCE_IRQ_LOWLEVEL,
  108. },
  109. };
  110. static struct platform_device net2272_bfin_device = {
  111. .name = "net2272",
  112. .id = -1,
  113. .num_resources = ARRAY_SIZE(net2272_bfin_resources),
  114. .resource = net2272_bfin_resources,
  115. };
  116. #endif
  117. /*
  118. * USB-LAN EzExtender board
  119. * Driver needs to know address, irq and flag pin.
  120. */
  121. #if IS_ENABLED(CONFIG_SMC91X)
  122. #include <linux/smc91x.h>
  123. static struct smc91x_platdata smc91x_info = {
  124. .flags = SMC91X_USE_8BIT | SMC91X_USE_16BIT | SMC91X_USE_32BIT |
  125. SMC91X_NOWAIT,
  126. .leda = RPC_LED_100_10,
  127. .ledb = RPC_LED_TX_RX,
  128. };
  129. static struct resource smc91x_resources[] = {
  130. {
  131. .name = "smc91x-regs",
  132. .start = 0x2C010300,
  133. .end = 0x2C010300 + 16,
  134. .flags = IORESOURCE_MEM,
  135. }, {
  136. .start = IRQ_PF9,
  137. .end = IRQ_PF9,
  138. .flags = IORESOURCE_IRQ | IORESOURCE_IRQ_HIGHLEVEL,
  139. },
  140. };
  141. static struct platform_device smc91x_device = {
  142. .name = "smc91x",
  143. .id = 0,
  144. .num_resources = ARRAY_SIZE(smc91x_resources),
  145. .resource = smc91x_resources,
  146. .dev = {
  147. .platform_data = &smc91x_info,
  148. },
  149. };
  150. #endif
  151. #if IS_ENABLED(CONFIG_SERIAL_BFIN)
  152. #ifdef CONFIG_SERIAL_BFIN_UART0
  153. static struct resource bfin_uart0_resources[] = {
  154. {
  155. .start = BFIN_UART_THR,
  156. .end = BFIN_UART_GCTL+2,
  157. .flags = IORESOURCE_MEM,
  158. },
  159. {
  160. .start = IRQ_UART_TX,
  161. .end = IRQ_UART_TX,
  162. .flags = IORESOURCE_IRQ,
  163. },
  164. {
  165. .start = IRQ_UART_RX,
  166. .end = IRQ_UART_RX,
  167. .flags = IORESOURCE_IRQ,
  168. },
  169. {
  170. .start = IRQ_UART_ERROR,
  171. .end = IRQ_UART_ERROR,
  172. .flags = IORESOURCE_IRQ,
  173. },
  174. {
  175. .start = CH_UART_TX,
  176. .end = CH_UART_TX,
  177. .flags = IORESOURCE_DMA,
  178. },
  179. {
  180. .start = CH_UART_RX,
  181. .end = CH_UART_RX,
  182. .flags = IORESOURCE_DMA,
  183. },
  184. };
  185. static unsigned short bfin_uart0_peripherals[] = {
  186. P_UART0_TX, P_UART0_RX, 0
  187. };
  188. static struct platform_device bfin_uart0_device = {
  189. .name = "bfin-uart",
  190. .id = 0,
  191. .num_resources = ARRAY_SIZE(bfin_uart0_resources),
  192. .resource = bfin_uart0_resources,
  193. .dev = {
  194. .platform_data = &bfin_uart0_peripherals, /* Passed to driver */
  195. },
  196. };
  197. #endif
  198. #endif
  199. #if IS_ENABLED(CONFIG_BFIN_SIR)
  200. #ifdef CONFIG_BFIN_SIR0
  201. static struct resource bfin_sir0_resources[] = {
  202. {
  203. .start = 0xFFC00400,
  204. .end = 0xFFC004FF,
  205. .flags = IORESOURCE_MEM,
  206. },
  207. {
  208. .start = IRQ_UART0_RX,
  209. .end = IRQ_UART0_RX+1,
  210. .flags = IORESOURCE_IRQ,
  211. },
  212. {
  213. .start = CH_UART0_RX,
  214. .end = CH_UART0_RX+1,
  215. .flags = IORESOURCE_DMA,
  216. },
  217. };
  218. static struct platform_device bfin_sir0_device = {
  219. .name = "bfin_sir",
  220. .id = 0,
  221. .num_resources = ARRAY_SIZE(bfin_sir0_resources),
  222. .resource = bfin_sir0_resources,
  223. };
  224. #endif
  225. #endif
  226. #if IS_ENABLED(CONFIG_MTD_PHYSMAP)
  227. static struct mtd_partition ezkit_partitions[] = {
  228. {
  229. .name = "bootloader(nor)",
  230. .size = 0x40000,
  231. .offset = 0,
  232. }, {
  233. .name = "linux kernel(nor)",
  234. .size = 0x1C0000,
  235. .offset = MTDPART_OFS_APPEND,
  236. }, {
  237. .name = "file system(nor)",
  238. .size = 0x800000 - 0x40000 - 0x1C0000 - 0x2000 * 8,
  239. .offset = MTDPART_OFS_APPEND,
  240. }, {
  241. .name = "config(nor)",
  242. .size = 0x2000 * 7,
  243. .offset = MTDPART_OFS_APPEND,
  244. }, {
  245. .name = "u-boot env(nor)",
  246. .size = 0x2000,
  247. .offset = MTDPART_OFS_APPEND,
  248. }
  249. };
  250. static struct physmap_flash_data ezkit_flash_data = {
  251. .width = 2,
  252. .parts = ezkit_partitions,
  253. .nr_parts = ARRAY_SIZE(ezkit_partitions),
  254. };
  255. static struct resource ezkit_flash_resource = {
  256. .start = 0x20000000,
  257. .end = 0x207fffff,
  258. .flags = IORESOURCE_MEM,
  259. };
  260. static struct platform_device ezkit_flash_device = {
  261. .name = "physmap-flash",
  262. .id = 0,
  263. .dev = {
  264. .platform_data = &ezkit_flash_data,
  265. },
  266. .num_resources = 1,
  267. .resource = &ezkit_flash_resource,
  268. };
  269. #endif
  270. #if IS_ENABLED(CONFIG_SPI_BFIN5XX)
  271. /* SPI (0) */
  272. static struct resource bfin_spi0_resource[] = {
  273. [0] = {
  274. .start = SPI0_REGBASE,
  275. .end = SPI0_REGBASE + 0xFF,
  276. .flags = IORESOURCE_MEM,
  277. },
  278. [1] = {
  279. .start = CH_SPI,
  280. .end = CH_SPI,
  281. .flags = IORESOURCE_DMA,
  282. },
  283. [2] = {
  284. .start = IRQ_SPI,
  285. .end = IRQ_SPI,
  286. .flags = IORESOURCE_IRQ,
  287. }
  288. };
  289. /* SPI controller data */
  290. static struct bfin5xx_spi_master bfin_spi0_info = {
  291. .num_chipselect = 8,
  292. .enable_dma = 1, /* master has the ability to do dma transfer */
  293. .pin_req = {P_SPI0_SCK, P_SPI0_MISO, P_SPI0_MOSI, 0},
  294. };
  295. static struct platform_device bfin_spi0_device = {
  296. .name = "bfin-spi",
  297. .id = 0, /* Bus number */
  298. .num_resources = ARRAY_SIZE(bfin_spi0_resource),
  299. .resource = bfin_spi0_resource,
  300. .dev = {
  301. .platform_data = &bfin_spi0_info, /* Passed to driver */
  302. },
  303. };
  304. #endif
  305. static struct spi_board_info bfin_spi_board_info[] __initdata = {
  306. #if IS_ENABLED(CONFIG_SND_BF5XX_SOC_AD183X)
  307. {
  308. .modalias = "ad183x",
  309. .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */
  310. .bus_num = 0,
  311. .chip_select = 4,
  312. .platform_data = "ad1836", /* only includes chip name for the moment */
  313. .mode = SPI_MODE_3,
  314. },
  315. #endif
  316. #if IS_ENABLED(CONFIG_SPI_SPIDEV)
  317. {
  318. .modalias = "spidev",
  319. .max_speed_hz = 3125000, /* max spi clock (SCK) speed in HZ */
  320. .bus_num = 0,
  321. .chip_select = 1,
  322. },
  323. #endif
  324. };
  325. #if IS_ENABLED(CONFIG_KEYBOARD_GPIO)
  326. #include <linux/input.h>
  327. #include <linux/gpio_keys.h>
  328. static struct gpio_keys_button bfin_gpio_keys_table[] = {
  329. {BTN_0, GPIO_PF5, 1, "gpio-keys: BTN0"},
  330. {BTN_1, GPIO_PF6, 1, "gpio-keys: BTN1"},
  331. {BTN_2, GPIO_PF7, 1, "gpio-keys: BTN2"},
  332. {BTN_3, GPIO_PF8, 1, "gpio-keys: BTN3"},
  333. };
  334. static struct gpio_keys_platform_data bfin_gpio_keys_data = {
  335. .buttons = bfin_gpio_keys_table,
  336. .nbuttons = ARRAY_SIZE(bfin_gpio_keys_table),
  337. };
  338. static struct platform_device bfin_device_gpiokeys = {
  339. .name = "gpio-keys",
  340. .dev = {
  341. .platform_data = &bfin_gpio_keys_data,
  342. },
  343. };
  344. #endif
  345. #if IS_ENABLED(CONFIG_I2C_GPIO)
  346. #include <linux/i2c-gpio.h>
  347. static struct i2c_gpio_platform_data i2c_gpio_data = {
  348. .sda_pin = GPIO_PF1,
  349. .scl_pin = GPIO_PF0,
  350. .sda_is_open_drain = 0,
  351. .scl_is_open_drain = 0,
  352. .udelay = 10,
  353. };
  354. static struct platform_device i2c_gpio_device = {
  355. .name = "i2c-gpio",
  356. .id = 0,
  357. .dev = {
  358. .platform_data = &i2c_gpio_data,
  359. },
  360. };
  361. #endif
  362. static const unsigned int cclk_vlev_datasheet[] =
  363. {
  364. VRPAIR(VLEV_085, 250000000),
  365. VRPAIR(VLEV_090, 300000000),
  366. VRPAIR(VLEV_095, 313000000),
  367. VRPAIR(VLEV_100, 350000000),
  368. VRPAIR(VLEV_105, 400000000),
  369. VRPAIR(VLEV_110, 444000000),
  370. VRPAIR(VLEV_115, 450000000),
  371. VRPAIR(VLEV_120, 475000000),
  372. VRPAIR(VLEV_125, 500000000),
  373. VRPAIR(VLEV_130, 600000000),
  374. };
  375. static struct bfin_dpmc_platform_data bfin_dmpc_vreg_data = {
  376. .tuple_tab = cclk_vlev_datasheet,
  377. .tabsize = ARRAY_SIZE(cclk_vlev_datasheet),
  378. .vr_settling_time = 25 /* us */,
  379. };
  380. static struct platform_device bfin_dpmc = {
  381. .name = "bfin dpmc",
  382. .dev = {
  383. .platform_data = &bfin_dmpc_vreg_data,
  384. },
  385. };
  386. #if IS_ENABLED(CONFIG_VIDEO_BLACKFIN_CAPTURE)
  387. #include <linux/videodev2.h>
  388. #include <media/blackfin/bfin_capture.h>
  389. #include <media/blackfin/ppi.h>
  390. static const unsigned short ppi_req[] = {
  391. P_PPI0_D0, P_PPI0_D1, P_PPI0_D2, P_PPI0_D3,
  392. P_PPI0_D4, P_PPI0_D5, P_PPI0_D6, P_PPI0_D7,
  393. P_PPI0_CLK, P_PPI0_FS1, P_PPI0_FS2,
  394. 0,
  395. };
  396. static const struct ppi_info ppi_info = {
  397. .type = PPI_TYPE_PPI,
  398. .dma_ch = CH_PPI0,
  399. .irq_err = IRQ_PPI1_ERROR,
  400. .base = (void __iomem *)PPI0_CONTROL,
  401. .pin_req = ppi_req,
  402. };
  403. #if IS_ENABLED(CONFIG_VIDEO_ADV7183)
  404. #include <media/adv7183.h>
  405. static struct v4l2_input adv7183_inputs[] = {
  406. {
  407. .index = 0,
  408. .name = "Composite",
  409. .type = V4L2_INPUT_TYPE_CAMERA,
  410. .std = V4L2_STD_ALL,
  411. .capabilities = V4L2_IN_CAP_STD,
  412. },
  413. {
  414. .index = 1,
  415. .name = "S-Video",
  416. .type = V4L2_INPUT_TYPE_CAMERA,
  417. .std = V4L2_STD_ALL,
  418. .capabilities = V4L2_IN_CAP_STD,
  419. },
  420. {
  421. .index = 2,
  422. .name = "Component",
  423. .type = V4L2_INPUT_TYPE_CAMERA,
  424. .std = V4L2_STD_ALL,
  425. .capabilities = V4L2_IN_CAP_STD,
  426. },
  427. };
  428. static struct bcap_route adv7183_routes[] = {
  429. {
  430. .input = ADV7183_COMPOSITE4,
  431. .output = ADV7183_8BIT_OUT,
  432. },
  433. {
  434. .input = ADV7183_SVIDEO0,
  435. .output = ADV7183_8BIT_OUT,
  436. },
  437. {
  438. .input = ADV7183_COMPONENT0,
  439. .output = ADV7183_8BIT_OUT,
  440. },
  441. };
  442. static const unsigned adv7183_gpio[] = {
  443. GPIO_PF13, /* reset pin */
  444. GPIO_PF2, /* output enable pin */
  445. };
  446. static struct bfin_capture_config bfin_capture_data = {
  447. .card_name = "BF561",
  448. .inputs = adv7183_inputs,
  449. .num_inputs = ARRAY_SIZE(adv7183_inputs),
  450. .routes = adv7183_routes,
  451. .i2c_adapter_id = 0,
  452. .board_info = {
  453. .type = "adv7183",
  454. .addr = 0x20,
  455. .platform_data = (void *)adv7183_gpio,
  456. },
  457. .ppi_info = &ppi_info,
  458. .ppi_control = (PACK_EN | DLEN_8 | DMA32 | FLD_SEL),
  459. };
  460. #endif
  461. static struct platform_device bfin_capture_device = {
  462. .name = "bfin_capture",
  463. .dev = {
  464. .platform_data = &bfin_capture_data,
  465. },
  466. };
  467. #endif
  468. #if IS_ENABLED(CONFIG_SND_BF5XX_I2S)
  469. static struct platform_device bfin_i2s = {
  470. .name = "bfin-i2s",
  471. .id = CONFIG_SND_BF5XX_SPORT_NUM,
  472. /* TODO: add platform data here */
  473. };
  474. #endif
  475. #if IS_ENABLED(CONFIG_SND_BF5XX_AC97)
  476. static struct platform_device bfin_ac97 = {
  477. .name = "bfin-ac97",
  478. .id = CONFIG_SND_BF5XX_SPORT_NUM,
  479. /* TODO: add platform data here */
  480. };
  481. #endif
  482. #if IS_ENABLED(CONFIG_SND_BF5XX_SOC_AD1836)
  483. static const char * const ad1836_link[] = {
  484. "bfin-i2s.0",
  485. "spi0.4",
  486. };
  487. static struct platform_device bfin_ad1836_machine = {
  488. .name = "bfin-snd-ad1836",
  489. .id = -1,
  490. .dev = {
  491. .platform_data = (void *)ad1836_link,
  492. },
  493. };
  494. #endif
  495. static struct platform_device *ezkit_devices[] __initdata = {
  496. &bfin_dpmc,
  497. #if IS_ENABLED(CONFIG_SMC91X)
  498. &smc91x_device,
  499. #endif
  500. #if IS_ENABLED(CONFIG_USB_NET2272)
  501. &net2272_bfin_device,
  502. #endif
  503. #if IS_ENABLED(CONFIG_USB_ISP1760_HCD)
  504. &bfin_isp1760_device,
  505. #endif
  506. #if IS_ENABLED(CONFIG_SPI_BFIN5XX)
  507. &bfin_spi0_device,
  508. #endif
  509. #if IS_ENABLED(CONFIG_SERIAL_BFIN)
  510. #ifdef CONFIG_SERIAL_BFIN_UART0
  511. &bfin_uart0_device,
  512. #endif
  513. #endif
  514. #if IS_ENABLED(CONFIG_BFIN_SIR)
  515. #ifdef CONFIG_BFIN_SIR0
  516. &bfin_sir0_device,
  517. #endif
  518. #endif
  519. #if IS_ENABLED(CONFIG_KEYBOARD_GPIO)
  520. &bfin_device_gpiokeys,
  521. #endif
  522. #if IS_ENABLED(CONFIG_I2C_GPIO)
  523. &i2c_gpio_device,
  524. #endif
  525. #if IS_ENABLED(CONFIG_USB_ISP1362_HCD)
  526. &isp1362_hcd_device,
  527. #endif
  528. #if IS_ENABLED(CONFIG_MTD_PHYSMAP)
  529. &ezkit_flash_device,
  530. #endif
  531. #if IS_ENABLED(CONFIG_VIDEO_BLACKFIN_CAPTURE)
  532. &bfin_capture_device,
  533. #endif
  534. #if IS_ENABLED(CONFIG_SND_BF5XX_I2S)
  535. &bfin_i2s,
  536. #endif
  537. #if IS_ENABLED(CONFIG_SND_BF5XX_AC97)
  538. &bfin_ac97,
  539. #endif
  540. #if IS_ENABLED(CONFIG_SND_BF5XX_SOC_AD1836)
  541. &bfin_ad1836_machine,
  542. #endif
  543. };
  544. static int __init net2272_init(void)
  545. {
  546. #if IS_ENABLED(CONFIG_USB_NET2272)
  547. int ret;
  548. ret = gpio_request(GPIO_PF11, "net2272");
  549. if (ret)
  550. return ret;
  551. /* Reset the USB chip */
  552. gpio_direction_output(GPIO_PF11, 0);
  553. mdelay(2);
  554. gpio_set_value(GPIO_PF11, 1);
  555. #endif
  556. return 0;
  557. }
  558. static int __init ezkit_init(void)
  559. {
  560. int ret;
  561. printk(KERN_INFO "%s(): registering device resources\n", __func__);
  562. ret = platform_add_devices(ezkit_devices, ARRAY_SIZE(ezkit_devices));
  563. if (ret < 0)
  564. return ret;
  565. #if IS_ENABLED(CONFIG_SMC91X)
  566. bfin_write_FIO0_DIR(bfin_read_FIO0_DIR() | (1 << 12));
  567. SSYNC();
  568. #endif
  569. #if IS_ENABLED(CONFIG_SND_BF5XX_SOC_AD183X)
  570. bfin_write_FIO0_DIR(bfin_read_FIO0_DIR() | (1 << 15));
  571. bfin_write_FIO0_FLAG_S(1 << 15);
  572. SSYNC();
  573. /*
  574. * This initialization lasts for approximately 4500 MCLKs.
  575. * MCLK = 12.288MHz
  576. */
  577. udelay(400);
  578. #endif
  579. if (net2272_init())
  580. pr_warning("unable to configure net2272; it probably won't work\n");
  581. spi_register_board_info(bfin_spi_board_info, ARRAY_SIZE(bfin_spi_board_info));
  582. return 0;
  583. }
  584. arch_initcall(ezkit_init);
  585. static struct platform_device *ezkit_early_devices[] __initdata = {
  586. #if defined(CONFIG_SERIAL_BFIN_CONSOLE) || defined(CONFIG_EARLY_PRINTK)
  587. #ifdef CONFIG_SERIAL_BFIN_UART0
  588. &bfin_uart0_device,
  589. #endif
  590. #endif
  591. };
  592. void __init native_machine_early_platform_add_devices(void)
  593. {
  594. printk(KERN_INFO "register early platform devices\n");
  595. early_platform_add_devices(ezkit_early_devices,
  596. ARRAY_SIZE(ezkit_early_devices));
  597. }