Issue #2323759 by Crell, dawehner: Modularize kernel exception handling.