if (pci_match_device(esb_pci_tbl, dev)) { 
if (pci_match_id(esb_pci_tbl, dev)) { 
static unsigned char __init esb_getdevice (void){	u8 val1;	unsigned short val2;        struct pci_dev *dev = NULL;        /*         *      Find the PCI device         */        for_each_pci_dev(dev) {                if (pci_match_device(esb_pci_tbl, dev)) {                        esb_pci = dev;                        break;                }	}        if (esb_pci) {        	if (pci_enable_device(esb_pci)) {			printk (KERN_ERR PFX "failed to enable device\n");			goto err_devput;		}		if (pci_request_region(esb_pci, 0, ESB_MODULE_NAME)) {			printk (KERN_ERR PFX "failed to request region\n");			goto err_disable;		}		BASEADDR = ioremap(pci_resource_start(esb_pci, 0),				   pci_resource_len(esb_pci, 0));		if (BASEADDR == NULL) {                	/* Something's wrong here, BASEADDR has to be set */			printk (KERN_ERR PFX "failed to get BASEADDR\n");                        goto err_release;                }		/*		 * The watchdog has two timers, it can be setup so that the		 * expiry of timer1 results in an interrupt and the expiry of		 * timer2 results in a reboot. We set it to not generate		 * any interrupts as there is not much we can do with it		 * right now.		 *		 * We also enable reboots and set the timer frequency to		 * the PCI clock divided by 2^15 (approx 1KHz).		 */		pci_write_config_word(esb_pci, ESB_CONFIG_REG, 0x0003);		/* Check that the WDT isn't already locked */		pci_read_config_byte(esb_pci, ESB_LOCK_REG, &val1);		if (val1 & ESB_WDT_LOCK)			printk (KERN_WARNING PFX "nowayout already set\n");		/* Set the timer to watchdog mode and disable it for now */		pci_write_config_byte(esb_pci, ESB_LOCK_REG, 0x00);		/* Check if the watchdog was previously triggered */		esb_unlock_registers();		val2 = readw(ESB_RELOAD_REG);		triggered = (val2 & (0x01 << 9) >> 9);		/* Reset trigger flag and timers */		esb_unlock_registers();		writew((0x11 << 8), ESB_RELOAD_REG);		/* Done */		return 1;err_release:		pci_release_region(esb_pci, 0);err_disable:		pci_disable_device(esb_pci);err_devput:		pci_dev_put(esb_pci);	}	return 0;}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/bb5dc36644975ca5237a415fb63f59f9803d84fa/i6300esb.c/clean/drivers/char/watchdog/i6300esb.c