/* Shared IRQ handler that can call both master and slave ISRs. 
The master and slave ISRs are called through function pointers in order to decouple this code from the ISR functions. Without this, the linker would always pull in both ISRs and every function they call, even if only the functional API was used. */
static void LPI2C_CommonIRQHandler(LPI2C_Type *base, uint32_t instance)
/* Shared IRQ handler that can call both master and slave ISRs. 
The master and slave ISRs are called through function pointers in order to decouple this code from the ISR functions. Without this, the linker would always pull in both ISRs and every function they call, even if only the functional API was used. */
static void LPI2C_CommonIRQHandler(LPI2C_Type *base, uint32_t instance)
{
    if ((base->MCR & LPI2C_MCR_MEN_MASK) && s_lpi2cMasterIsr)
    {
        s_lpi2cMasterIsr(base, s_lpi2cMasterHandle[instance]);
    }
    if ((base->SCR & LPI2C_SCR_SEN_MASK) && s_lpi2cSlaveIsr)
    {
        s_lpi2cSlaveIsr(base, s_lpi2cSlaveHandle[instance]);
    }
}