set_current_state(TASK_UNINTERRUPTIBLE); schedule_timeout((delay2 * HZ) / 1000); 
schedule_timeout_uninterruptible(msecs_to_jiffies(delay2)); 
static void snd_m3_ac97_reset(m3_t *chip){	u16 dir;	int delay1 = 0, delay2 = 0, i;	int io = chip->iobase;	if (chip->allegro_flag) {		/*		 * the onboard codec on the allegro seems 		 * to want to wait a very long time before		 * coming back to life 		 */		delay1 = 50;		delay2 = 800;	} else {		/* maestro3 */		delay1 = 20;		delay2 = 500;	}	for (i = 0; i < 5; i++) {		dir = inw(io + GPIO_DIRECTION);		if (! chip->quirk || ! chip->quirk->irda_workaround)			dir |= 0x10; /* assuming pci bus master? */		snd_m3_remote_codec_config(io, 0);		outw(IO_SRAM_ENABLE, io + RING_BUS_CTRL_A);		udelay(20);		outw(dir & ~GPO_PRIMARY_AC97 , io + GPIO_DIRECTION);		outw(~GPO_PRIMARY_AC97 , io + GPIO_MASK);		outw(0, io + GPIO_DATA);		outw(dir | GPO_PRIMARY_AC97, io + GPIO_DIRECTION);		set_current_state(TASK_UNINTERRUPTIBLE);		schedule_timeout((delay1 * HZ) / 1000);		outw(GPO_PRIMARY_AC97, io + GPIO_DATA);		udelay(5);		/* ok, bring back the ac-link */		outw(IO_SRAM_ENABLE | SERIAL_AC_LINK_ENABLE, io + RING_BUS_CTRL_A);		outw(~0, io + GPIO_MASK);		set_current_state(TASK_UNINTERRUPTIBLE);		schedule_timeout((delay2 * HZ) / 1000);		if (! snd_m3_try_read_vendor(chip))			break;		delay1 += 10;		delay2 += 100;		snd_printd("maestro3: retrying codec reset with delays of %d and %d ms\n",			   delay1, delay2);	}#if 0	/* more gung-ho reset that doesn't	 * seem to work anywhere :)	 */	tmp = inw(io + RING_BUS_CTRL_A);	outw(RAC_SDFS_ENABLE|LAC_SDFS_ENABLE, io + RING_BUS_CTRL_A);	msleep(20);	outw(tmp, io + RING_BUS_CTRL_A);	msleep(50);#endif}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/8433a509c0eb6bb1f33ce39c82c580b8901619ee/maestro3.c/clean/sound/pci/maestro3.c