]> asedeno.scripts.mit.edu Git - linux.git/commit
arm64: traps: simplify die() and __die()
authorMark Rutland <mark.rutland@arm.com>
Thu, 3 Nov 2016 20:23:06 +0000 (20:23 +0000)
committerCatalin Marinas <catalin.marinas@arm.com>
Fri, 11 Nov 2016 18:25:43 +0000 (18:25 +0000)
commit876e7a38e8788773aac768091aaa3b42e470c03b
tree76833f601cc880238ea990a5ae9651f28cc9b6fb
parenta9ea0017ebe8889dfa136cac2aa7ae0ee6915e1f
arm64: traps: simplify die() and __die()

In arm64's die and __die routines we pass around a thread_info, and
subsequently use this to determine the relevant task_struct, and the end
of the thread's stack. Subsequent patches will decouple thread_info from
the stack, and this approach will no longer work.

To figure out the end of the stack, we can use the new generic
end_of_stack() helper. As we only call __die() from die(), and die()
always deals with the current task, we can remove the parameter and have
both acquire current directly, which also makes it clear that __die
can't be called for arbitrary tasks.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Tested-by: Laura Abbott <labbott@redhat.com>
Cc: Will Deacon <will.deacon@arm.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
arch/arm64/kernel/traps.c