]> git.itanic.dy.fi Git - linux-stable/commit
sparc64: Take ctx_alloc_lock properly in hugetlb_setup().
authorDavid S. Miller <davem@davemloft.net>
Wed, 25 May 2016 19:51:20 +0000 (12:51 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 24 Jun 2016 17:22:04 +0000 (10:22 -0700)
commit859f30806733299db9759a0b394cf320346ca5c9
treea64af525808adc84f41944cfe84b5022acff87ba
parent4bf8d0467c45ade31c32e95ce48158713e426417
sparc64: Take ctx_alloc_lock properly in hugetlb_setup().

[ Upstream commit 9ea46abe22550e3366ff7cee2f8391b35b12f730 ]

On cheetahplus chips we take the ctx_alloc_lock in order to
modify the TLB lookup parameters for the indexed TLBs, which
are stored in the context register.

This is called with interrupts disabled, however ctx_alloc_lock
is an IRQ safe lock, therefore we must take acquire/release it
properly with spin_{lock,unlock}_irq().

Reported-by: Meelis Roos <mroos@linux.ee>
Tested-by: Meelis Roos <mroos@linux.ee>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/sparc/mm/init_64.c