I am working with AVR-GCC and using Ob Dev's AVR-USB driver. It has a spec for maximum time that interrupts can be disabled. The recommended solution is to sei in your interrupt routines. I am just trying to keep my ISR as short as possible. I believe I am under the spec for my clock frequency but would like a little more cushion . Here is the assembler that was generated from my ISR code.
PUSH R1 PUSH R0 IN R0,0x3F PUSH R0 CLR R1 PUSH R24 IN R24,0x05 STS 0x0091,R24 LDI R24,0x01 STS 0x0078,R24 POP R24 POP R0 OUT 0X3F,R0 POP R0 POP R1 RETI
I feel fairy certain that I can shorten this to:
PUSH R24 IN R24,0x05 STS 0x0091,R24 LDI R24,0x01 STS 0x0078,R24 POP R24 RETI
Am I right?