/* Prototype: int acornscsi_getperiod(unsigned char syncxfer) Purpose : period for the synchronous transfer setting Params : syncxfer SYNCXFER register value Returns : period in ns.  */
static int acornscsi_getperiod(unsigned char syncxfer)
/* Prototype: int acornscsi_getperiod(unsigned char syncxfer) Purpose : period for the synchronous transfer setting Params : syncxfer SYNCXFER register value Returns : period in ns.  */
static int acornscsi_getperiod(unsigned char syncxfer)
{
    int i;
    syncxfer &= 0xf0;
    if (syncxfer == 0x10)
	syncxfer = 0;
    for (i = 1; sync_xfer_table[i].period_ns; i++)
	if (syncxfer == sync_xfer_table[i].reg_value)
	    return sync_xfer_table[i].period_ns;
    return 0;
}