mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-11-20 08:38:24 +08:00
sparc: Use page_fault_out_of_memory() for VM_FAULT_OOM.
As noted by Nick Piggin. Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
9a926d86b2
commit
a923c28fc5
@ -319,9 +319,10 @@ no_context:
|
||||
*/
|
||||
out_of_memory:
|
||||
up_read(&mm->mmap_sem);
|
||||
printk("VM: killing process %s\n", tsk->comm);
|
||||
if (from_user)
|
||||
do_group_exit(SIGKILL);
|
||||
if (from_user) {
|
||||
pagefault_out_of_memory();
|
||||
return;
|
||||
}
|
||||
goto no_context;
|
||||
|
||||
do_sigbus:
|
||||
|
@ -447,9 +447,10 @@ handle_kernel_fault:
|
||||
out_of_memory:
|
||||
insn = get_fault_insn(regs, insn);
|
||||
up_read(&mm->mmap_sem);
|
||||
printk("VM: killing process %s\n", current->comm);
|
||||
if (!(regs->tstate & TSTATE_PRIV))
|
||||
do_group_exit(SIGKILL);
|
||||
if (!(regs->tstate & TSTATE_PRIV)) {
|
||||
pagefault_out_of_memory();
|
||||
return;
|
||||
}
|
||||
goto handle_kernel_fault;
|
||||
|
||||
intr_or_no_mm:
|
||||
|
Loading…
Reference in New Issue
Block a user