[V2] powerpc/fscr: Enable interrupts earlier before calling get_user()
Michael Ellerman
patch-notifications at ellerman.id.au
Thu Apr 12 00:49:28 AEST 2018
On Thu, 2018-03-29 at 06:23:37 UTC, Anshuman Khandual wrote:
> The function get_user() can sleep while trying to fetch instruction
> from user address space and causes the following warning from the
> scheduler.
>
> BUG: sleeping function called from invalid context
>
> Though interrupts get enabled back but it happens bit later after
> get_user() is called. This change moves enabling these interrupts
> earlier covering the function get_user(). While at this, lets check
> for kernel mode and crash as this interrupt should not have been
> triggered from the kernel context.
>
> Signed-off-by: Anshuman Khandual <khandual at linux.vnet.ibm.com>
Applied to powerpc fixes, thanks.
https://git.kernel.org/powerpc/c/709b973c844c0b4d115ac3a227a2e5
cheers
More information about the Linuxppc-dev
mailing list