Most interrupt lists have gaps. Usually because a chip is available in many configuration with different peripherals. Sometimes sources are reserved to ensure you can grow in the future without reshuffling the interrupt map. Even the RISC-V definition of interrupts has this. Therefore, a top level parameter is needed to mask out certain sources.
parameter [N_SOURCE-1:0] MASK = {N_SOURCE{1'b1}}