~vicamo/+git/ubuntu-kernel:bug-1847451/turbostat-cml/disco

Last commit made on 2019-11-20
Get this branch:
git clone -b bug-1847451/turbostat-cml/disco https://git.launchpad.net/~vicamo/+git/ubuntu-kernel
Only You-Sheng Yang can upload to this branch. If you are You-Sheng Yang please log in for upload directions.

Branch merges

Branch information

Name:
bug-1847451/turbostat-cml/disco
Repository:
lp:~vicamo/+git/ubuntu-kernel

Recent commits

5438f17... by You-Sheng Yang

Bug 1847451: tools/power turbostat: Add Cometlake support

5db6923... by Chen Yu <email address hidden>

tools/power turbostat: Add Cometlake support

From a turbostat point of view, Cometlake is like Kabylake.

Suggested-by: Rui Zhang <email address hidden>
Signed-off-by: Chen Yu <email address hidden>
Signed-off-by: Len Brown <email address hidden>
(backported from commit 68973b44c86040ccd145d0dfe2143c839ff6ee45)
Signed-off-by: You-Sheng Yang <email address hidden>

e421062... by Connor Kuehl

UBUNTU: Ubuntu-5.0.0-37.40

Signed-off-by: Connor Kuehl <email address hidden>

42ab31a... by Connor Kuehl

UBUNTU: link-to-tracker: update tracking bug

BugLink: https://bugs.launchpad.net/bugs/1852253
Properties: no-test-build
Signed-off-by: Connor Kuehl <email address hidden>

be37135... by tglx

x86/timer: Skip PIT initialization on modern chipsets

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

Recent Intel chipsets including Skylake and ApolloLake have a special
ITSSPRC register which allows the 8254 PIT to be gated. When gated, the
8254 registers can still be programmed as normal, but there are no IRQ0
timer interrupts.

Some products such as the Connex L1430 and exone go Rugged E11 use this
register to ship with the PIT gated by default. This causes Linux to fail
to boot:

  Kernel panic - not syncing: IO-APIC + timer doesn't work! Boot with
  apic=debug and send a report.

The panic happens before the framebuffer is initialized, so to the user, it
appears as an early boot hang on a black screen.

Affected products typically have a BIOS option that can be used to enable
the 8254 and make Linux work (Chipset -> South Cluster Configuration ->
Miscellaneous Configuration -> 8254 Clock Gating), however it would be best
to make Linux support the no-8254 case.

Modern sytems allow to discover the TSC and local APIC timer frequencies,
so the calibration against the PIT is not required. These systems have
always running timers and the local APIC timer works also in deep power
states.

So the setup of the PIT including the IO-APIC timer interrupt delivery
checks are a pointless exercise.

Skip the PIT setup and the IO-APIC timer interrupt checks on these systems,
which avoids the panic caused by non ticking PITs and also speeds up the
boot process.

Thanks to Daniel for providing the changelog, initial analysis of the
problem and testing against a variety of machines.

Reported-by: Daniel Drake <email address hidden>
Signed-off-by: Thomas Gleixner <email address hidden>
Tested-by: Daniel Drake <email address hidden>
Cc: <email address hidden>
Cc: <email address hidden>
Cc: <email address hidden>
Cc: <email address hidden>
Cc: <email address hidden>
Link: https://<email address hidden>

(backported from commit c8c4076723daca08bf35ccd68f22ea1c6219e207)
Signed-off-by: You-Sheng Yang <email address hidden>
Acked-by: Stefan Bader <email address hidden>
Acked-by: Connor Kuehl <email address hidden>
Signed-off-by: Stefan Bader <email address hidden>

dfdb284... by Matt Roper <email address hidden>

drm/i915/cml: Add second PCH ID for CMP

BugLink: http://bugs.launchpad.net/bugs/1848491

The CMP PCH ID we have in the driver is correct for the CML-U machines we have
in our CI system, but the CML-S and CML-H CI machines appear to use a
different PCH ID, leading our driver to detect no PCH for them.

Cc: Rodrigo Vivi <email address hidden>
Cc: Anusha Srivatsa <email address hidden>
References: 729ae330a0f2e2 ("drm/i915/cml: Introduce Comet Lake PCH")
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=111461
Signed-off-by: Matt Roper <email address hidden>
Acked-by: Chris Wilson <email address hidden>
Signed-off-by: Chris Wilson <email address hidden>
Link: https://patchwork.<email address hidden>
(backported from commit 8698ba53cd7173c32320ebbef4d389d41ebb5780)
Signed-off-by: Timo Aaltonen <email address hidden>
Acked-by: Stefan Bader <email address hidden>
Acked-by: Connor Kuehl <email address hidden>
Signed-off-by: Stefan Bader <email address hidden>

0a1fc42... by Andy Whitcroft

efi: efi_get_memory_map -- increase map headroom

We are seeing some EFI based machines failing to boot hard in the EFI
stub:

    exit_boot() failed!
    efi_main() failed!

This seems to occur when the bootloader (grub2 in this case) has had
to manipulate some additional files due to a change in the way MAAS
boots the machines. We tracked this down to the memory map dance
efi_get_memory_map(). Basically we attempt to close boot services and
it informs us it cannot do so because it failed to record the updated
memory map. This occurs when there is insufficient space in the passed
memory map buffer to record changes during the operation. At the point
when this occurs we are unable to call the allocation functions to
reallocate the buffer so we panic.

To avoid this we allocate some additional entries in the buffer to cover
any additional entries. This headroom is currently insufficient for
these machines under this use case. Increase EFI_MMAP_NR_SLACK_SLOTS to
provide space for more memory map modifications.

BugLink: https://bugs.launchpad.net/bugs/1851810
Signed-off-by: Andy Whitcroft <email address hidden>
Acked-by: Stefan Bader <email address hidden>
Acked-by: Seth Forshee <email address hidden>
Signed-off-by: Stefan Bader <email address hidden>

6fa7f85... by Christian Brauner

UBUNTU: SAUCE: seccomp: fix SECCOMP_USER_NOTIF_FLAG_CONTINUE test

The ifndef for SECCOMP_USER_NOTIF_FLAG_CONTINUE was placed under the
ifndef for the SECCOMP_FILTER_FLAG_NEW_LISTENER feature. This will not
work on systems that do support SECCOMP_FILTER_FLAG_NEW_LISTENER but do not
support SECCOMP_USER_NOTIF_FLAG_CONTINUE. So move the latter ifndef out of
the former ifndef's scope.

2019-10-20 11:14:01 make run_tests -C seccomp
make: Entering directory '/usr/src/perf_selftests-x86_64-rhel-7.6-0eebfed2954f152259cae0ad57b91d3ea92968e8/tools/testing/selftests/seccomp'
gcc -Wl,-no-as-needed -Wall seccomp_bpf.c -lpthread -o seccomp_bpf
seccomp_bpf.c: In function ‘user_notification_continue’:
seccomp_bpf.c:3562:15: error: ‘SECCOMP_USER_NOTIF_FLAG_CONTINUE’ undeclared (first use in this function)
  resp.flags = SECCOMP_USER_NOTIF_FLAG_CONTINUE;
               ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
seccomp_bpf.c:3562:15: note: each undeclared identifier is reported only once for each function it appears in
Makefile:12: recipe for target 'seccomp_bpf' failed
make: *** [seccomp_bpf] Error 1
make: Leaving directory '/usr/src/perf_selftests-x86_64-rhel-7.6-0eebfed2954f152259cae0ad57b91d3ea92968e8/tools/testing/selftests/seccomp'

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

Reported-by: kernel test robot <email address hidden>
Fixes: 0eebfed2954f ("seccomp: test SECCOMP_USER_NOTIF_FLAG_CONTINUE")
Cc: <email address hidden>
Signed-off-by: Christian Brauner <email address hidden>
Reviewed-by: Tycho Andersen <email address hidden>
Signed-off-by: Manoj Iyer <email address hidden>
Acked-by: Stefan Bader <email address hidden>
Acked-by: Connor Kuehl <email address hidden>
Signed-off-by: Stefan Bader <email address hidden>

012a23d... by Christian Brauner

UBUNTU: SAUCE: seccomp: rework define for SECCOMP_USER_NOTIF_FLAG_CONTINUE

Switch from BIT(0) to (1UL << 0).
First, there are already two different forms used in the header, so there's
no need to add a third. Second, the BIT() macros is kernel internal and
afaict not actually exposed to userspace. Maybe there's some magic there
I'm missing but it definitely causes issues when compiling a program that
tries to use SECCOMP_USER_NOTIF_FLAG_CONTINUE. It currently fails in the
following way:

 # github.com/lxc/lxd/lxd
 /usr/bin/ld: $WORK/b001/_x003.o: in function
 `__do_user_notification_continue':
 lxd/main_checkfeature.go:240: undefined reference to `BIT'
 collect2: error: ld returned 1 exit status

Switching to (1UL << 0) should prevent that and is more in line what is
already done in the rest of the header.

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

Cc: Kees Cook <email address hidden>
Cc: Andy Lutomirski <email address hidden>
Signed-off-by: Christian Brauner <email address hidden>
Link: https://<email address hidden>
Signed-off-by: Kees Cook <email address hidden>
(cherry picked from commit 23b2c96fad21886c53f5e1a4ffedd45ddd2e85ba
 git.kernel.org/pub/scm/linux/kernel/git/kees/linux.git)
Signed-off-by: Manoj Iyer <email address hidden>
Acked-by: Stefan Bader <email address hidden>
Acked-by: Connor Kuehl <email address hidden>
Signed-off-by: Stefan Bader <email address hidden>

f3414a8... by Christian Brauner

UBUNTU: SAUCE: seccomp: avoid overflow in implicit constant conversion

USER_NOTIF_MAGIC is assigned to int variables in this test so set it to INT_MAX
to avoid warnings:

seccomp_bpf.c: In function ‘user_notification_continue’:
seccomp_bpf.c:3088:26: warning: overflow in implicit constant conversion [-Woverflow]
 #define USER_NOTIF_MAGIC 116983961184613L
                          ^
seccomp_bpf.c:3572:15: note: in expansion of macro ‘USER_NOTIF_MAGIC’
  resp.error = USER_NOTIF_MAGIC;
               ^~~~~~~~~~~~~~~~

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

Fixes: 6a21cc50f0c7 ("seccomp: add a return code to trap to userspace")
Signed-off-by: Christian Brauner <email address hidden>
Reviewed-by: Tyler Hicks <email address hidden>
Cc: Andy Lutomirski <email address hidden>
Cc: Will Drewry <email address hidden>
Cc: Shuah Khan <email address hidden>
Cc: Alexei Starovoitov <email address hidden>
Cc: Daniel Borkmann <email address hidden>
Cc: Martin KaFai Lau <email address hidden>
Cc: Song Liu <email address hidden>
Cc: Yonghong Song <email address hidden>
Cc: Tycho Andersen <email address hidden>
Cc: <email address hidden>
Cc: <email address hidden>
Cc: <email address hidden>
Cc: <email address hidden>
Reviewed-by: Tycho Andersen <email address hidden>
Link: https://<email address hidden>
Signed-off-by: Kees Cook <email address hidden>
(cherry picked from commit 223e660bc7638d126a0e4fbace4f33f2895788c4
 git.kernel.org/pub/scm/linux/kernel/git/kees/linux.git)
Signed-off-by: Manoj Iyer <email address hidden>
Acked-by: Stefan Bader <email address hidden>
Acked-by: Connor Kuehl <email address hidden>
Signed-off-by: Stefan Bader <email address hidden>