@@ -609,7 +609,7 @@ bool IRQManager::addPeripheral(Peripheral_t p, void *cfg) {
609
609
mcfg->ipl = I2C_MASTER_PRIORITY;
610
610
611
611
if (mcfg->txi_irq == FSP_INVALID_VECTOR) {
612
- if (last_interrupt_index + WIRE_MASTER_INTERRUPT_COUNT >= PROG_IRQ_NUM){
612
+ if (last_interrupt_index + WIRE_MASTER_INTERRUPT_COUNT > PROG_IRQ_NUM){
613
613
rv = false ;
614
614
goto end_config;
615
615
}
@@ -658,7 +658,7 @@ bool IRQManager::addPeripheral(Peripheral_t p, void *cfg) {
658
658
i2c_master_cfg_t *mcfg = (i2c_master_cfg_t *)p_cfg->mcfg ;
659
659
mcfg->ipl = I2C_MASTER_PRIORITY;
660
660
if (mcfg->txi_irq == FSP_INVALID_VECTOR) {
661
- if (last_interrupt_index + WIRE_SCI_MASTER_INTERRUPT_COUNT >= PROG_IRQ_NUM) {
661
+ if (last_interrupt_index + WIRE_SCI_MASTER_INTERRUPT_COUNT > PROG_IRQ_NUM) {
662
662
rv = false ;
663
663
goto end_config;
664
664
}
@@ -707,7 +707,7 @@ bool IRQManager::addPeripheral(Peripheral_t p, void *cfg) {
707
707
scfg->eri_ipl = I2C_SLAVE_PRIORITY;
708
708
709
709
if (scfg->txi_irq == FSP_INVALID_VECTOR) {
710
- if (last_interrupt_index + WIRE_SLAVE_INTERRUPT_COUNT >= PROG_IRQ_NUM) {
710
+ if (last_interrupt_index + WIRE_SLAVE_INTERRUPT_COUNT > PROG_IRQ_NUM) {
711
711
rv = false ;
712
712
goto end_config;
713
713
}
@@ -773,7 +773,7 @@ bool IRQManager::addPeripheral(Peripheral_t p, void *cfg) {
773
773
uint8_t const hw_channel = reinterpret_cast <SpiMasterIrqReq_t *>(cfg)->hw_channel ;
774
774
775
775
if (p_cfg->txi_irq == FSP_INVALID_VECTOR) {
776
- if (last_interrupt_index + SPI_INTERRUPT_COUNT >= PROG_IRQ_NUM) {
776
+ if (last_interrupt_index + SPI_INTERRUPT_COUNT > PROG_IRQ_NUM) {
777
777
rv = false ;
778
778
goto end_config;
779
779
}
@@ -825,7 +825,7 @@ bool IRQManager::addPeripheral(Peripheral_t p, void *cfg) {
825
825
uint8_t const hw_channel = reinterpret_cast <SciSpiMasterIrqReq_t *>(cfg)->hw_channel ;
826
826
827
827
if (p_cfg->txi_irq == FSP_INVALID_VECTOR) {
828
- if (last_interrupt_index + SPI_INTERRUPT_COUNT >= PROG_IRQ_NUM) {
828
+ if (last_interrupt_index + SPI_INTERRUPT_COUNT > PROG_IRQ_NUM) {
829
829
rv = false ;
830
830
goto end_config;
831
831
}
@@ -878,7 +878,7 @@ bool IRQManager::addPeripheral(Peripheral_t p, void *cfg) {
878
878
p_cfg->ipl = CAN_PRIORITY; /* All interrupts share the same priority. */
879
879
880
880
if (p_cfg->error_irq == FSP_INVALID_VECTOR) {
881
- if (last_interrupt_index + CAN_INTERRUPT_COUNT >= PROG_IRQ_NUM) {
881
+ if (last_interrupt_index + CAN_INTERRUPT_COUNT > PROG_IRQ_NUM) {
882
882
rv = false ;
883
883
goto end_config;
884
884
}
@@ -936,7 +936,7 @@ bool IRQManager::addPeripheral(Peripheral_t p, void *cfg) {
936
936
p_cfg->ipl = CAN_PRIORITY; /* All interrupts share the same priority. */
937
937
938
938
if (p_cfg->error_irq == FSP_INVALID_VECTOR) {
939
- if (last_interrupt_index + CANFD_INTERRUPT_COUNT >= PROG_IRQ_NUM) {
939
+ if (last_interrupt_index + CANFD_INTERRUPT_COUNT > PROG_IRQ_NUM) {
940
940
rv = false ;
941
941
goto end_config;
942
942
}
@@ -975,7 +975,7 @@ bool IRQManager::addPeripheral(Peripheral_t p, void *cfg) {
975
975
sdmmc_cfg_t *sd_cfg = (sdmmc_cfg_t *)cfg;
976
976
/* SDCARD_ACCESS */
977
977
if (sd_cfg->access_irq == FSP_INVALID_VECTOR) {
978
- if (last_interrupt_index + SD_INTERRUPT_COUNT >= PROG_IRQ_NUM){
978
+ if (last_interrupt_index + SD_INTERRUPT_COUNT > PROG_IRQ_NUM){
979
979
rv = false ;
980
980
goto end_config;
981
981
}
0 commit comments