Skip to content

Commit 7bcd069

Browse files
raffi-gcarlescufi
authored andcommitted
gen_isr_tables: Add meaningful error message
When using direct isrs, a vector table is needed. However, if none is present , i.e. `CONFIG_GEN_IRQ_VECTOR_TABLE=n`, this script failed. The given error message was not helpful (`'NoneType' has no len()`). This change makes it clearer, where to look for the problem. Signed-off-by: Greter Raffael <[email protected]>
1 parent 78faf5e commit 7bcd069

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

scripts/build/gen_isr_tables.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -358,6 +358,10 @@ def main():
358358

359359
for irq, flags, func, param in intlist["interrupts"]:
360360
if flags & ISR_FLAG_DIRECT:
361+
if not vt:
362+
error("Direct Interrupt %d declared with parameter 0x%x "
363+
"but no vector table in use"
364+
% (irq, param))
361365
if param != 0:
362366
error("Direct irq %d declared, but has non-NULL parameter"
363367
% irq)

0 commit comments

Comments
 (0)