powerpc/kernel: Initialize load_tm on task creation
authorBreno Leitao <leitao@debian.org>
Mon, 5 Jun 2017 14:40:59 +0000 (11:40 -0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 14 Jun 2017 13:06:03 +0000 (15:06 +0200)
commit6e6d89e18e53062987b2d14223f34abf64046ab7
tree3b74cdefc5ea3d66c61c7b0aa80ea80eb3fd9fbc
parent2cfdf4fd3292d05eeca5d59307bf231b94df1d4b
powerpc/kernel: Initialize load_tm on task creation

commit 7f22ced4377628074e2ac25f41a88f98eb3b03f1 upstream.

Currently tsk->thread.load_tm is not initialized in the task creation
and can contain garbage on a new task.

This is an undesired behaviour, since it affects the timing to enable
and disable the transactional memory laziness (disabling and enabling
the MSR TM bit, which affects TM reclaim and recheckpoint in the
scheduling process).

Fixes: 5d176f751ee3 ("powerpc: tm: Enable transactional memory (TM) lazily for userspace")
Signed-off-by: Breno Leitao <leitao@debian.org>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/powerpc/kernel/process.c