unsigned char target	 = SCpnt->device->id; 
unsigned char target	 = scmd_id(SCpnt); 
static int nsphw_start_selection(Scsi_Cmnd *SCpnt){	unsigned int  host_id	 = SCpnt->device->host->this_id;	unsigned int  base	 = SCpnt->device->host->io_port;	unsigned char target	 = SCpnt->device->id;	nsp_hw_data  *data = (nsp_hw_data *)SCpnt->device->host->hostdata;	int	      time_out;	unsigned char phase, arbit;	//nsp_dbg(NSP_DEBUG_RESELECTION, "in");	phase = nsp_index_read(base, SCSIBUSMON);	if(phase != BUSMON_BUS_FREE) {		//nsp_dbg(NSP_DEBUG_RESELECTION, "bus busy");		return FALSE;	}	/* start arbitration */	//nsp_dbg(NSP_DEBUG_RESELECTION, "start arbit");	SCpnt->SCp.phase = PH_ARBSTART;	nsp_index_write(base, SETARBIT, ARBIT_GO);	time_out = 1000;	do {		/* XXX: what a stupid chip! */		arbit = nsp_index_read(base, ARBITSTATUS);		//nsp_dbg(NSP_DEBUG_RESELECTION, "arbit=%d, wait_count=%d", arbit, wait_count);		udelay(1); /* hold 1.2us */	} while((arbit & (ARBIT_WIN | ARBIT_FAIL)) == 0 &&		(time_out-- != 0));	if (!(arbit & ARBIT_WIN)) {		//nsp_dbg(NSP_DEBUG_RESELECTION, "arbit fail");		nsp_index_write(base, SETARBIT, ARBIT_FLAG_CLEAR);		return FALSE;	}	/* assert select line */	//nsp_dbg(NSP_DEBUG_RESELECTION, "assert SEL line");	SCpnt->SCp.phase = PH_SELSTART;	udelay(3); /* wait 2.4us */	nsp_index_write(base, SCSIDATALATCH, BIT(host_id) | BIT(target));	nsp_index_write(base, SCSIBUSCTRL,   SCSI_SEL | SCSI_BSY                    | SCSI_ATN);	udelay(2); /* wait >1.2us */	nsp_index_write(base, SCSIBUSCTRL,   SCSI_SEL | SCSI_BSY | SCSI_DATAOUT_ENB | SCSI_ATN);	nsp_index_write(base, SETARBIT,	     ARBIT_FLAG_CLEAR);	/*udelay(1);*/ /* wait >90ns */	nsp_index_write(base, SCSIBUSCTRL,   SCSI_SEL            | SCSI_DATAOUT_ENB | SCSI_ATN);	/* check selection timeout */	nsp_start_timer(SCpnt, 1000/51);	data->SelectionTimeOut = 1;	return TRUE;}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/422c0d61d591cbfb70f029e13505fb437e169d68/nsp_cs.c/buggy/drivers/scsi/pcmcia/nsp_cs.c