XilinxProcessorIPLib/drivers/tmrctr/src/xtmrctr_sinit.c
XTmrCtr_Config *XTmrCtr_LookupConfig(u16 DeviceId)
{
	XTmrCtr_Config *CfgPtr = NULL;
	u16 Index;

	for (Index = 0; Index < XPAR_XTMRCTR_NUM_INSTANCES; Index++) {
		if (XTmrCtr_ConfigTable[Index].DeviceId == DeviceId) {
			CfgPtr = &XTmrCtr_ConfigTable[Index];
			break;
		}
	}

	return CfgPtr;
}
/*****************************************************************************/
/**
* Looks up the device configuration based on the unique device ID. The table
* TmrCtr_ConfigTable contains the configuration info for each device in the
* system.
*
* @param	DeviceId is the unique device ID to search for in the config
*		table.
*
* @return	A pointer to the configuration that matches the given device
* 		ID, or NULL if no match is found.
*
* @note		None.
*
******************************************************************************/
Looks up the device configuration based on the unique device ID. The table
TmrCtr_ConfigTable contains the configuration info for each device in the
system.
Looks up the device configuration based on the unique device ID . The table TmrCtr_ConfigTable contains the configuration info for each device in the system .
XTmrCtr_Config *XTmrCtr_LookupConfig(u16 DeviceId)
{
	XTmrCtr_Config *CfgPtr = NULL;
	u16 Index;
	for (Index = 0; Index < XPAR_XTMRCTR_NUM_INSTANCES; Index++) {
		if (XTmrCtr_ConfigTable[Index].DeviceId == DeviceId) {
			CfgPtr = &XTmrCtr_ConfigTable[Index];
			break;
		}
	}
	return CfgPtr;
}
XTmrCtr_Config * XTmrCtr_LookupConfig ( u16 DeviceId ) { XTmrCtr_Config * CfgPtr = NULL ; u16 Index ; for ( Index = 0 ; Index < XPAR_XTMRCTR_NUM_INSTANCES ; Index ++ ) { if ( XTmrCtr_ConfigTable [ Index ] . DeviceId == DeviceId ) { CfgPtr = & XTmrCtr_ConfigTable [ Index ] ; break ; } } return CfgPtr ; }
Looks up the device configuration based on the unique device ID.
Looks up the device configuration based on the unique device ID .