aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap2/board-apollon.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2010-08-08 13:01:46 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2010-08-08 13:01:46 -0400
commitd71048e22f47725a5808ea2e4e1e72fa36c1a788 (patch)
tree65debebb2964cb4cbde4d29e15730527d686a540 /arch/arm/mach-omap2/board-apollon.c
parent44d51a029f95d49c5c7ccd7808f81904c20c3abd (diff)
parentd21872b3683ff37f73c68993749a6e6aeeaed265 (diff)
Merge branch 'omap-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6
* 'omap-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6: (143 commits) omap: mailbox: reorganize headers omap: mailbox: standarize on 'omap-mailbox' omap: mailbox: only compile for configured archs omap: mailbox: simplify omap_mbox_register() omap: mailbox: reorganize registering omap: mailbox: add IRQ names omap: mailbox: remove unecessary fields omap: mailbox: don't export unecessary symbols omap: mailbox: update omap1 probing omap: mailbox: use correct config for omap1 omap: mailbox: 2420 should be detected at run-time omap: mailbox: reorganize structures omap: mailbox: trivial cleanups omap mailbox: Set a device in logical mbox instance for traceability omap: mailbox: convert block api to kfifo omap: mailbox: remove (un)likely macros from cold paths omap: mailbox cleanup: split MODULE_AUTHOR line omap: mailbox: convert rwlocks to spinlock Mailbox: disable mailbox interrupt when request queue Mailbox: new mutext lock for h/w mailbox configuration ...
Diffstat (limited to 'arch/arm/mach-omap2/board-apollon.c')
-rw-r--r--arch/arm/mach-omap2/board-apollon.c30
1 files changed, 22 insertions, 8 deletions
diff --git a/arch/arm/mach-omap2/board-apollon.c b/arch/arm/mach-omap2/board-apollon.c
index bd75642aee65..c6421a72514a 100644
--- a/arch/arm/mach-omap2/board-apollon.c
+++ b/arch/arm/mach-omap2/board-apollon.c
@@ -35,13 +35,14 @@
35 35
36#include <mach/gpio.h> 36#include <mach/gpio.h>
37#include <plat/led.h> 37#include <plat/led.h>
38#include <plat/mux.h>
39#include <plat/usb.h> 38#include <plat/usb.h>
40#include <plat/board.h> 39#include <plat/board.h>
41#include <plat/common.h> 40#include <plat/common.h>
42#include <plat/gpmc.h> 41#include <plat/gpmc.h>
43#include <plat/control.h> 42#include <plat/control.h>
44 43
44#include "mux.h"
45
45/* LED & Switch macros */ 46/* LED & Switch macros */
46#define LED0_GPIO13 13 47#define LED0_GPIO13 13
47#define LED1_GPIO14 14 48#define LED1_GPIO14 14
@@ -244,7 +245,7 @@ static inline void __init apollon_init_smc91x(void)
244 apollon_smc91x_resources[0].end = base + 0x30f; 245 apollon_smc91x_resources[0].end = base + 0x30f;
245 udelay(100); 246 udelay(100);
246 247
247 omap_cfg_reg(W4__24XX_GPIO74); 248 omap_mux_init_gpio(74, 0);
248 if (gpio_request(APOLLON_ETHR_GPIO_IRQ, "SMC91x irq") < 0) { 249 if (gpio_request(APOLLON_ETHR_GPIO_IRQ, "SMC91x irq") < 0) {
249 printk(KERN_ERR "Failed to request GPIO%d for smc91x IRQ\n", 250 printk(KERN_ERR "Failed to request GPIO%d for smc91x IRQ\n",
250 APOLLON_ETHR_GPIO_IRQ); 251 APOLLON_ETHR_GPIO_IRQ);
@@ -286,15 +287,15 @@ static void __init omap_apollon_init_irq(void)
286static void __init apollon_led_init(void) 287static void __init apollon_led_init(void)
287{ 288{
288 /* LED0 - AA10 */ 289 /* LED0 - AA10 */
289 omap_cfg_reg(AA10_242X_GPIO13); 290 omap_mux_init_signal("vlynq_clk.gpio_13", 0);
290 gpio_request(LED0_GPIO13, "LED0"); 291 gpio_request(LED0_GPIO13, "LED0");
291 gpio_direction_output(LED0_GPIO13, 0); 292 gpio_direction_output(LED0_GPIO13, 0);
292 /* LED1 - AA6 */ 293 /* LED1 - AA6 */
293 omap_cfg_reg(AA6_242X_GPIO14); 294 omap_mux_init_signal("vlynq_rx1.gpio_14", 0);
294 gpio_request(LED1_GPIO14, "LED1"); 295 gpio_request(LED1_GPIO14, "LED1");
295 gpio_direction_output(LED1_GPIO14, 0); 296 gpio_direction_output(LED1_GPIO14, 0);
296 /* LED2 - AA4 */ 297 /* LED2 - AA4 */
297 omap_cfg_reg(AA4_242X_GPIO15); 298 omap_mux_init_signal("vlynq_rx0.gpio_15", 0);
298 gpio_request(LED2_GPIO15, "LED2"); 299 gpio_request(LED2_GPIO15, "LED2");
299 gpio_direction_output(LED2_GPIO15, 0); 300 gpio_direction_output(LED2_GPIO15, 0);
300} 301}
@@ -303,22 +304,35 @@ static void __init apollon_usb_init(void)
303{ 304{
304 /* USB device */ 305 /* USB device */
305 /* DEVICE_SUSPEND */ 306 /* DEVICE_SUSPEND */
306 omap_cfg_reg(P21_242X_GPIO12); 307 omap_mux_init_signal("mcbsp2_clkx.gpio_12", 0);
307 gpio_request(12, "USB suspend"); 308 gpio_request(12, "USB suspend");
308 gpio_direction_output(12, 0); 309 gpio_direction_output(12, 0);
309 omap_usb_init(&apollon_usb_config); 310 omap2_usbfs_init(&apollon_usb_config);
310} 311}
311 312
313#ifdef CONFIG_OMAP_MUX
314static struct omap_board_mux board_mux[] __initdata = {
315 { .reg_offset = OMAP_MUX_TERMINATOR },
316};
317#else
318#define board_mux NULL
319#endif
320
312static void __init omap_apollon_init(void) 321static void __init omap_apollon_init(void)
313{ 322{
314 u32 v; 323 u32 v;
315 324
325 omap2420_mux_init(board_mux, OMAP_PACKAGE_ZAC);
326
316 apollon_led_init(); 327 apollon_led_init();
317 apollon_flash_init(); 328 apollon_flash_init();
318 apollon_usb_init(); 329 apollon_usb_init();
319 330
320 /* REVISIT: where's the correct place */ 331 /* REVISIT: where's the correct place */
321 omap_cfg_reg(W19_24XX_SYS_NIRQ); 332 omap_mux_init_signal("sys_nirq", OMAP_PULL_ENA | OMAP_PULL_UP);
333
334 /* LCD PWR_EN */
335 omap_mux_init_signal("mcbsp2_dr.gpio_11", OMAP_PULL_ENA | OMAP_PULL_UP);
322 336
323 /* Use Interal loop-back in MMC/SDIO Module Input Clock selection */ 337 /* Use Interal loop-back in MMC/SDIO Module Input Clock selection */
324 v = omap_ctrl_readl(OMAP2_CONTROL_DEVCONF0); 338 v = omap_ctrl_readl(OMAP2_CONTROL_DEVCONF0);