Index: ni_660x.c
===================================================================
RCS file: /var/cvs/comedi/comedi/drivers/ni_660x.c,v
retrieving revision 1.8
diff -r1.8 ni_660x.c
779a780,788
> 	// Enabling the second chip:  This "hardcodes" the counter
> 	// outputs 5 to 8 to use the second TIO in case of a NI6602
> 	// board.
> 	if (thisboard->name == "PCI-6602" )
> 	  {
> 	    printk("NI6602: Setting Counterswap on second TIO\n");
> 	    enable_chip(dev);
> 	  }
> 
815d823
< 		// DPRINTK("NI_660x: Moving to chipset 1\n");
847,848d854
< 	DPRINTK("NI_660x: INSN_READ on channel %d\n", subdev_channel);
< 
891c897
< enable_chip(comedi_device *dev, int chipset)
---
> enable_chip(comedi_device *dev)
896,904c902,904
< 	if ( chipset == 1)
< 	{
< 		writel(CounterSwap,dev->iobase + GPCT_OFFSET[chipset]
< 		+ registerData[ClockConfigRegister].offset);
< 	}else
< 	{
< 		writel(0x0,dev->iobase + GPCT_OFFSET[chipset]
< 		+ registerData[ClockConfigRegister].offset);
< 	}
---
>         writel(CounterSwap,dev->iobase + GPCT_OFFSET[1]
> 	       + registerData[ClockConfigRegister].offset);
> 	return 0;
907,908d906
< 
< 
918d915
< 	enable_chip(dev, chipset);
982,984c979,981
< 		/* - Set Counting Mode into GPCT_X1 / 2 / 4 (as set by user
< 		- Take into account Z pulse (index pulse) only when both
< 		channel A and B are high (arbitrary choice)
---
> 		/* - Set Counting Mode into GPCT_X1 / 2 / 4 (as set by user)
> 		   - When to take into account index pulse (as set by user)
> 		   - Take into account index pulse (as set by user)
988c985
< 			(ni_660x_gpct_config[subdev_channel]).data[1] ),
---
> 			(ni_660x_gpct_config[subdev_channel]).data[2] ),
1125d1121
< 		//printk("NI_660x: INSN_CONFIG: Config Simple Event Counter\n");
1260d1255
<   enable_chip(dev, chipset);
