static int sx_init_CD186x(struct specialix_board  * bp){	unsigned long flags;	int scaler;	int rv = 1;	func_enter();	sx_wait_CCR_off(bp);			   /* Wait for CCR ready        */	spin_lock_irqsave(&bp->lock, flags);	sx_out_off(bp, CD186x_CCR, CCR_HARDRESET);      /* Reset CD186x chip          */	spin_unlock_irqrestore(&bp->lock, flags);	sx_long_delay(HZ/20);                      /* Delay 0.05 sec            */	spin_lock_irqsave(&bp->lock, flags);	sx_out_off(bp, CD186x_GIVR, SX_ID);             /* Set ID for this chip      */	sx_out_off(bp, CD186x_GICR, 0);                 /* Clear all bits            */	sx_out_off(bp, CD186x_PILR1, SX_ACK_MINT);      /* Prio for modem intr       */	sx_out_off(bp, CD186x_PILR2, SX_ACK_TINT);      /* Prio for transmitter intr */	sx_out_off(bp, CD186x_PILR3, SX_ACK_RINT);      /* Prio for receiver intr    */	/* Set RegAckEn */	sx_out_off(bp, CD186x_SRCR, sx_in (bp, CD186x_SRCR) | SRCR_REGACKEN);		/* Setting up prescaler. We need 4 ticks per 1 ms */	scaler =  SX_OSCFREQ/SPECIALIX_TPS;	sx_out_off(bp, CD186x_PPRH, scaler >> 8);	sx_out_off(bp, CD186x_PPRL, scaler & 0xff);	spin_unlock_irqrestore(&bp->lock, flags);	if (!sx_set_irq (bp)) {		/* Figure out how to pass this along... */		printk (KERN_ERR "Cannot set irq to %d.\n", bp->irq);		rv = 0;	}	func_exit();	return rv;}
10457	/local/tlutelli/issta_data/temp/c/2005_temp/2005/10457/d61780c0d384939ef31c46b47442854d5def4623/specialix.c/buggy/drivers/char/specialix.c