[Bug 1888339] Re: [Potential Regression] ptrace-tar from powerpc in ubuntu_kernel_selftests failed on B/E/F

2020-08-25 Thread Thadeu Lima de Souza Cascardo
*** This bug is a duplicate of bug 1888332 ***
https://bugs.launchpad.net/bugs/1888332

Same issue as LP: #1888332. If we use DSCR privileged MSR when writing
in the tracee, it will set dscr_inherit, which will properly restore the
DSCR that is written by the tracer.

Cascardo.

** This bug has been marked a duplicate of bug 1888332
   [Potential Regression] dscr_inherit_exec_test from powerpc in 
ubuntu_kernel_selftests failed on B/E/F

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1888339

Title:
  [Potential Regression] ptrace-tar from powerpc in
  ubuntu_kernel_selftests failed on B/E/F

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu-kernel-tests/+bug/1888339/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1888339] Re: [Potential Regression] ptrace-tar from powerpc in ubuntu_kernel_selftests failed on B/E/F

2020-08-25 Thread Po-Hsu Lin
A bisect for arch/powerpc/ shows this is the first bad commit:

$ git bisect bad
7d10952e8a56f87a53fc57594078555a9dfd4a07 is the first bad commit
commit 7d10952e8a56f87a53fc57594078555a9dfd4a07
Author: Michael Ellerman 
Date:   Thu May 28 00:58:42 2020 +1000

powerpc/64s: Save FSCR to init_task.thread.fscr after feature init

BugLink: https://bugs.launchpad.net/bugs/1885176

commit 912c0a7f2b5daa3cbb2bc10f303981e493de73bd upstream.

At boot the FSCR is initialised via one of two paths. On most systems
it's set to a hard coded value in __init_FSCR().

On newer skiboot systems we use the device tree CPU features binding,
where firmware can tell Linux what bits to set in FSCR (and HFSCR).

In both cases the value that's configured at boot is not propagated
into the init_task.thread.fscr value prior to the initial fork of init
(pid 1), which means the value is not used by any processes other than
swapper (the idle task).

For the __init_FSCR() case this is OK, because the value in
init_task.thread.fscr is initialised to something sensible. However it
does mean that the value set in __init_FSCR() is not used other than
for swapper, which is odd and confusing.

The bigger problem is for the device tree CPU features case it
prevents firmware from setting (or clearing) FSCR bits for use by user
space. This means all existing kernels can not have features
enabled/disabled by firmware if those features require
setting/clearing FSCR bits.

We can handle both cases by saving the FSCR value into
init_task.thread.fscr after we have initialised it at boot. This fixes
the bug for device tree CPU features, and will allow us to simplify
the initialisation for the __init_FSCR() case in a future patch.

Fixes: 5a61ef74f269 ("powerpc/64s: Support new device tree binding for 
discovering CPU features")
Cc: sta...@vger.kernel.org # v4.12+
Signed-off-by: Michael Ellerman 
Link: https://lore.kernel.org/r/20200527145843.2761782-3-...@ellerman.id.au
Signed-off-by: Greg Kroah-Hartman 
Signed-off-by: Kamal Mostafa 
Signed-off-by: Khalid Elmously 

:04 04 9c654d310ed9b7c4a1cf16620d120ec93624eda3 
05b34a61190e63ccde3b7d02e2183dc64b32c812 M  arch


$ git bisect log
git bisect start '--' 'arch/powerpc/'
\# bad: [f4daf25f7f8608d1c14c85ea0b73c9e1e1eb2dba] UBUNTU: Ubuntu-4.15.0-114.115
git bisect bad f4daf25f7f8608d1c14c85ea0b73c9e1e1eb2dba
\# good: [495149ddc61a5997857fda041ccd4c81cac46e00] UBUNTU: 
Ubuntu-4.15.0-112.113
git bisect good 495149ddc61a5997857fda041ccd4c81cac46e00
\# bad: [07ad1246146fa49430d2455bd45db1c8da4d521c] powerpc/perf/hv-24x7: Fix 
inconsistent output values incase multiple hv-24x7 events run
git bisect bad 07ad1246146fa49430d2455bd45db1c8da4d521c
\# good: [f30471f4138df69bd4585d91c1f31a282daa41e7] powerpc/64s: Don't let DT 
CPU features set FSCR_DSCR
git bisect good f30471f4138df69bd4585d91c1f31a282daa41e7
\# bad: [0e198dfae237e9a9654d87b7c6df12146feaec26] sched/core: Fix illegal RCU 
from offline CPUs
git bisect bad 0e198dfae237e9a9654d87b7c6df12146feaec26
\# bad: [7d10952e8a56f87a53fc57594078555a9dfd4a07] powerpc/64s: Save FSCR to 
init_task.thread.fscr after feature init
git bisect bad 7d10952e8a56f87a53fc57594078555a9dfd4a07
\# first bad commit: [7d10952e8a56f87a53fc57594078555a9dfd4a07] powerpc/64s: 
Save FSCR to init_task.thread.fscr after feature init

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1888339

Title:
  [Potential Regression] ptrace-tar from powerpc in
  ubuntu_kernel_selftests failed on B/E/F

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu-kernel-tests/+bug/1888339/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1888339] Re: [Potential Regression] ptrace-tar from powerpc in ubuntu_kernel_selftests failed on B/E/F

2020-08-25 Thread Po-Hsu Lin
Note for Bionic P9, this test didn't fail on node baltar.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1888339

Title:
  [Potential Regression] ptrace-tar from powerpc in
  ubuntu_kernel_selftests failed on B/E/F

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu-kernel-tests/+bug/1888339/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1888339] Re: [Potential Regression] ptrace-tar from powerpc in ubuntu_kernel_selftests failed on B/E/F

2020-08-25 Thread Po-Hsu Lin
On Bionic P8, I can reproduce this issue against proposed kernel
(4.15.0-114.115) with source code in 4.15.0-112. Indicating this might
be a kernel issue instead of a test case issue.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1888339

Title:
  [Potential Regression] ptrace-tar from powerpc in
  ubuntu_kernel_selftests failed on B/E/F

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu-kernel-tests/+bug/1888339/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

[Bug 1888339] Re: [Potential Regression] ptrace-tar from powerpc in ubuntu_kernel_selftests failed on B/E/F

2020-08-24 Thread Po-Hsu Lin
This failure can be found on 4.15.0-114.115 / 4.15.0-114.115~16.04.1
PowerPC as well


** Summary changed:

- [Potential Regression] ptrace-tar from powerpc in ubuntu_kernel_selftests 
failed on E/F
+ [Potential Regression] ptrace-tar from powerpc in ubuntu_kernel_selftests 
failed on B/E/F

** Tags added: 4.15 bionic xenial

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1888339

Title:
  [Potential Regression] ptrace-tar from powerpc in
  ubuntu_kernel_selftests failed on B/E/F

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu-kernel-tests/+bug/1888339/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs