<div dir="ltr"><div style="font-family:arial,helvetica,sans-serif" class="gmail_default">Hi,</div><div style="font-family:arial,helvetica,sans-serif" class="gmail_default"><br></div><div style="font-family:arial,helvetica,sans-serif" class="gmail_default">I was looking at arch code setting up page fault handling in the kernel and came away with a couple of questions.</div><div style="font-family:arial,helvetica,sans-serif" class="gmail_default"><br></div><div style="font-family:arial,helvetica,sans-serif" class="gmail_default">Can hardware interrupts (non-NMI) occur during page faults? On x86, I notice that the page fault handler is set up with an interrupt gate which should clear the IF (Interrupt Enable) bit - disabling maskable interrupts in the process. I also don't see interrupts being enabled later in the handler (arch/x86/mm/fault.c:do_page_fault).<br></div><div style="font-family:arial,helvetica,sans-serif" class="gmail_default"><br></div><div style="font-family:arial,helvetica,sans-serif" class="gmail_default">However, from a quick skim, it doesn't look like the same rule is followed on ARM (32-bit) where local IRQs are enabled after we enter the page fault handler (arch/arm/mm/fault.c:do_page_fault).</div><div><br></div><div><div style="font-family:arial,helvetica,sans-serif" class="gmail_default">Is there a general policy for interrupt handling during page faults? I would have guessed that (non-threaded) interrupts be disabled during page faults because of the possibility of a recursive lock acquire or stack overflow if the interrupt handler itself page faults.</div><div style="font-family:arial,helvetica,sans-serif" class="gmail_default"><br></div><div style="font-family:arial,helvetica,sans-serif" class="gmail_default">Is there an arch-specific factor involved which prevents (AFAICT) interrupts being serviced while the page fault is in progress on x86 but not on ARM or did I miss something in my reading of the code?</div><div style="font-family:arial,helvetica,sans-serif" class="gmail_default"><br></div><div style="font-family:arial,helvetica,sans-serif" class="gmail_default"><br></div><div style="font-family:arial,helvetica,sans-serif" class="gmail_default">Shrikant<br></div></div></div>