[En-Nut-Discussion] Cortex ih_xxx_interuptY code duplication, continued

Ole Reinhardt ole.reinhardt at embedded-it.de
Thu Jul 19 13:26:39 CEST 2012

Hi Uwe,

> if we accept the additional redirection for a common IrqCtl() function,
> placement of IQR_HANDLER could be eased with a macro like

But using this macro would result in duplicate code (flash space) again,
wouldn't it?

What about my idea to use the totally same code for all IRQs by changing
the API a little and pass the sig_xxx struct to IrqCtl and to the signal
handler as well (which could then read the users argument from the

Unfortunately my approach would need changes in the NutRegisterIrq as
well. So we would have to adjust all platforms accordingly.

@Harald: What do you think about this idea?

Best regards,



Thermotemp GmbH, Embedded-IT

Embedded Hard-/ Software and Open Source Development, 
Integration and Consulting


Geschäftsstelle Siegen - Steinstraße 67 - D-57072 Siegen - 
tel +49 (0)271 5513597, +49 (0)271-73681 - fax +49 (0)271 736 97

Hauptsitz - Hademarscher Weg 7 - 13503 Berlin
Tel +49 (0)30 4315205 - Fax +49 (0)30 43665002
Geschäftsführer: Jörg Friedrichs, Ole Reinhardt
Handelsregister Berlin Charlottenburg HRB 45978 UstID DE 156329280 

More information about the En-Nut-Discussion mailing list