Added proper support for disabling interrupts