/* This function will install a interrupt service routine to a interrupt.  */
void rt_hw_interrupt_install(int vector, rt_isr_handler_t new_handler, rt_isr_handler_t *old_handler)
/* This function will install a interrupt service routine to a interrupt.  */
void rt_hw_interrupt_install(int vector, rt_isr_handler_t new_handler, rt_isr_handler_t *old_handler)
{
	XIntc_Config           *CfgPtr;
    CfgPtr = &XIntc_ConfigTable[0];
	if(vector >= 0 && vector < MAX_HANDLERS)
	{
		if (*old_handler != RT_NULL) *old_handler = (rt_isr_handler_t)CfgPtr->HandlerTable[vector].Handler;
		if (new_handler != RT_NULL) CfgPtr->HandlerTable[vector].Handler = (XInterruptHandler)new_handler;
	}
}