]> git.baikalelectronics.ru Git - kernel.git/commit
ARM: 7368/1: fault.c: correct how the tsk->[maj|min]_flt gets incremented
authorKautuk Consul <consul.kautuk@gmail.com>
Mon, 2 Apr 2012 17:19:49 +0000 (18:19 +0100)
committerRussell King <rmk+kernel@arm.linux.org.uk>
Tue, 10 Apr 2012 08:27:42 +0000 (09:27 +0100)
commit91e48d998648ec11e210e6508bebaf02bd096896
tree3b88ae41a4d4571a48d03ad90c8955f3fffec77e
parentd4786110d8858b609ef8b1df33057dc754469f22
ARM: 7368/1: fault.c: correct how the tsk->[maj|min]_flt gets incremented

commit 12bb25fc74e5245a3b7a7f4004158d9e1ebfc76e was done by me
to make the page fault handler retryable as well as interruptible.

Due to this commit, there is a mistake in the way in which
tsk->[maj|min]_flt counter gets incremented for VM_FAULT_ERROR:
If VM_FAULT_ERROR is returned in the fault flags by handle_mm_fault,
then either maj_flt or min_flt will get incremented. This is wrong
as in the case of a VM_FAULT_ERROR we need to be skip ahead to the
error handling code in do_page_fault.

Added a check after the call to __do_page_fault() to check for
(fault & VM_FAULT_ERROR).

Signed-off-by: Kautuk Consul <consul.kautuk@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
arch/arm/mm/fault.c