| 
					
				 | 
			
			
				@@ -162,3 +162,61 @@ static struct platform_device osk5912_cf_device = { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 }; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 static struct platform_device *osk5912_devices[] __initdata = { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	&osk5912_flash_device, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	&osk5912_smc91x_device, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	&osk5912_cf_device, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+}; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+static struct gpio_led tps_leds[] = { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	/* NOTE:  D9 and D2 have hardware blink support. 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	 * Also, D9 requires non-battery power. 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	 */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	{ .gpio = OSK_TPS_GPIO_LED_D9, .name = "d9", 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+			.default_trigger = "ide-disk", }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	{ .gpio = OSK_TPS_GPIO_LED_D2, .name = "d2", }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	{ .gpio = OSK_TPS_GPIO_LED_D3, .name = "d3", .active_low = 1, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+			.default_trigger = "heartbeat", }, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+}; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+static struct gpio_led_platform_data tps_leds_data = { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	.num_leds	= 3, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	.leds		= tps_leds, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+}; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+static struct platform_device osk5912_tps_leds = { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	.name			= "leds-gpio", 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	.id			= 0, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	.dev.platform_data	= &tps_leds_data, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+}; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+static int osk_tps_setup(struct i2c_client *client, void *context) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+{ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	/* Set GPIO 1 HIGH to disable VBUS power supply; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	 * OHCI driver powers it up/down as needed. 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	 */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	gpio_request(OSK_TPS_GPIO_USB_PWR_EN, "n_vbus_en"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	gpio_direction_output(OSK_TPS_GPIO_USB_PWR_EN, 1); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	/* Set GPIO 2 high so LED D3 is off by default */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	tps65010_set_gpio_out_value(GPIO2, HIGH); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	/* Set GPIO 3 low to take ethernet out of reset */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	gpio_request(OSK_TPS_GPIO_LAN_RESET, "smc_reset"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	gpio_direction_output(OSK_TPS_GPIO_LAN_RESET, 0); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	/* GPIO4 is VDD_DSP */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	gpio_request(OSK_TPS_GPIO_DSP_PWR_EN, "dsp_power"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	gpio_direction_output(OSK_TPS_GPIO_DSP_PWR_EN, 1); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	/* REVISIT if DSP support isn't configured, power it off ... */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	/* Let LED1 (D9) blink; leds-gpio may override it */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	tps65010_set_led(LED1, BLINK); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	/* Set LED2 off by default */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	tps65010_set_led(LED2, OFF); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	/* Enable LOW_PWR handshake */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	tps65010_set_low_pwr(ON); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	/* Switch VLDO2 to 3.0V for AIC23 */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	tps65010_config_vregs1(TPS_LDO2_ENABLE | TPS_VLDO2_3_0V 
			 |