omap_set_gpio_dataout(GPIO_TIMER, led_state & LED_TIMER_ON); goto done; 
 if (machine_is_omap_perseus2()) hw_led_state ^= H2P2_DBG_FPGA_P2_LED_TIMER; else { omap_set_gpio_dataout(GPIO_TIMER, led_state & LED_TIMER_ON); goto done; }  break; 
void h2p2_dbg_leds_event(led_event_t evt){	unsigned long flags;	static struct h2p2_dbg_fpga __iomem *fpga;	static u16 led_state, hw_led_state;	local_irq_save(flags);	if (!(led_state & LED_STATE_ENABLED) && evt != led_start)		goto done;	switch (evt) {	case led_start:		if (!fpga)			fpga = ioremap(H2P2_DBG_FPGA_START,						H2P2_DBG_FPGA_SIZE);		if (fpga) {			led_state |= LED_STATE_ENABLED;			__raw_writew(~0, &fpga->leds);		}		break;	case led_stop:	case led_halted:		/* all leds off during suspend or shutdown */		omap_set_gpio_dataout(GPIO_TIMER, 0);		omap_set_gpio_dataout(GPIO_IDLE, 0);		__raw_writew(~0, &fpga->leds);		led_state &= ~LED_STATE_ENABLED;		if (evt == led_halted) {			iounmap(fpga);			fpga = NULL;		}		goto done;	case led_claim:		led_state |= LED_STATE_CLAIMED;		hw_led_state = 0;		break;	case led_release:		led_state &= ~LED_STATE_CLAIMED;		break;#ifdef CONFIG_LEDS_TIMER	case led_timer:		led_state ^= LED_TIMER_ON;		omap_set_gpio_dataout(GPIO_TIMER, led_state & LED_TIMER_ON);		goto done;#endif#ifdef CONFIG_LEDS_CPU	case led_idle_start:		omap_set_gpio_dataout(GPIO_IDLE, 1);		goto done;	case led_idle_end:		omap_set_gpio_dataout(GPIO_IDLE, 0);		goto done;#endif	case led_green_on:		hw_led_state |= H2P2_DBG_FPGA_LED_GREEN;		break;	case led_green_off:		hw_led_state &= ~H2P2_DBG_FPGA_LED_GREEN;		break;	case led_amber_on:		hw_led_state |= H2P2_DBG_FPGA_LED_AMBER;		break;	case led_amber_off:		hw_led_state &= ~H2P2_DBG_FPGA_LED_AMBER;		break;	case led_red_on:		hw_led_state |= H2P2_DBG_FPGA_LED_RED;		break;	case led_red_off:		hw_led_state &= ~H2P2_DBG_FPGA_LED_RED;		break;	case led_blue_on:		hw_led_state |= H2P2_DBG_FPGA_LED_BLUE;		break;	case led_blue_off:		hw_led_state &= ~H2P2_DBG_FPGA_LED_BLUE;		break;	default:		break;	}	/*	 *  Actually burn the LEDs	 */	if (led_state & LED_STATE_CLAIMED)		__raw_writew(~hw_led_state, &fpga->leds);done:	local_irq_restore(flags);}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/3179a019391f0f8081245fd564a5f1be308ba64f/leds-h2p2-debug.c/buggy/arch/arm/mach-omap1/leds-h2p2-debug.c