for (i = 0; i < ARRAY_SIZE(vals); i++) { 
for (i = 0; i < ARRAY_SIZE(vals); i++) { 
static void __devinit init_PXC200(struct bttv *btv){	static int vals[] __devinitdata = { 0x08, 0x09, 0x0a, 0x0b, 0x0d, 0x0d,					    0x01, 0x02, 0x03, 0x04, 0x05, 0x06,					    0x00 };	unsigned int i;	int tmp;	u32 val;	/* Initialise GPIO-connevted stuff */	gpio_inout(0xffffff, (1<<13));	gpio_write(0);	udelay(3);	gpio_write(1<<13);	/* GPIO inputs are pulled up, so no need to drive	 * reset pin any longer */	gpio_bits(0xffffff, 0);	if (bttv_gpio)		bttv_gpio_tracking(btv,"pxc200");	/*  we could/should try and reset/control the AD pots? but	    right now  we simply  turned off the crushing.  Without	    this the AGC drifts drifts	    remember the EN is reverse logic -->	    setting BT848_ADC_AGC_EN disable the AGC	    tboult@eecs.lehigh.edu	*/	btwrite(BT848_ADC_RESERVED|BT848_ADC_AGC_EN, BT848_ADC);	/*	Initialise MAX517 DAC */	printk(KERN_INFO "Setting DAC reference voltage level ...\n");	bttv_I2CWrite(btv,0x5E,0,0x80,1);	/*	Initialise 12C508 PIC */	/*	The I2CWrite and I2CRead commmands are actually to the	 *	same chips - but the R/W bit is included in the address	 *	argument so the numbers are different */	printk(KERN_INFO "Initialising 12C508 PIC chip ...\n");	/* First of all, enable the clock line. This is used in the PXC200-F */	val = btread(BT848_GPIO_DMA_CTL);	val |= BT848_GPIO_DMA_CTL_GPCLKMODE;	btwrite(val, BT848_GPIO_DMA_CTL);	/* Then, push to 0 the reset pin long enough to reset the *	 * device same as above for the reset line, but not the same	 * value sent to the GPIO-connected stuff	 * which one is the good one? */	gpio_inout(0xffffff,(1<<2));	gpio_write(0);	udelay(10);	gpio_write(1<<2);       	for (i = 0; i < ARRAY_SIZE(vals); i++) {		tmp=bttv_I2CWrite(btv,0x1E,0,vals[i],1);		if (tmp != -1) {			printk(KERN_INFO			       "I2C Write(%2.2x) = %i\nI2C Read () = %2.2x\n\n",			       vals[i],tmp,bttv_I2CRead(btv,0x1F,NULL));		}	}	printk(KERN_INFO "PXC200 Initialised.\n");}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/4ac97914c6c35f6bf132071c718e034d0846b9f5/bttv-cards.c/buggy/drivers/media/video/bttv-cards.c