Bug 12578 - test_qemu_efi (oeqa.selftest.wic.Wic) fails on Fedora27 in master
Summary: test_qemu_efi (oeqa.selftest.wic.Wic) fails on Fedora27 in master
Status: RESOLVED FIXED
Alias: None
Product: OE-Core
Classification: Build System, Metadata & Runtime
Component: core (show other bugs)
Version: 2.5
Hardware: x86 Multiple
: Medium+ normal
Target Milestone: 2.5 M4
Assignee: California Sullivan
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2018-03-01 22:35 UTC by California Sullivan
Modified: 2018-03-30 16:15 UTC (History)
3 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: Regression (Used to work)
Verified:
Documentation change: No (bug/feature does not impact docs)


Attachments
error log (6.98 KB, text/plain)
2018-03-01 22:35 UTC, California Sullivan
no flags Details
bisect log (1.78 KB, text/plain)
2018-03-01 22:36 UTC, California Sullivan
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description California Sullivan 2018-03-01 22:35:35 UTC
Created attachment 4221 [details]
error log

This started failing on master between 2.5_M2 and HEAD. Unlike bug 12440, ovmf builds successfully. Visually, I see qemu exiting immediately after the bootloader stage (grub-efi seems OK).

I was able to reproduce the failure outside of this specific test via the following configuration options in local.conf:
MACHINE = "qemux86"
MACHINE_FEATURES_append = " efi"
IMAGE_FSTYPES += "wic"
WKS_FILE = "mkefidisk.wks"

And the following commands:
bitbake core-image-minimal ovmf
runqemu wic ovmf

Changing MACHINE to qemux86-64 the error doesn't occur. It also doesn't occur with intel-core2-32 MACHINE from meta-intel, which uses the intel-linux kernel at v4.14.18.

Adding kvm to the runqemu command also allows it to run successfully.
Comment 1 California Sullivan 2018-03-01 22:36:23 UTC
Created attachment 4222 [details]
bisect log
Comment 2 California Sullivan 2018-03-07 17:30:14 UTC
Bisect on the kernel:

git bisect start
# good: [ae0fb21fdde3df106d7dad76620bdf39721425e2] perf: x86-32: explicitly include <errno.h>
git bisect good ae0fb21fdde3df106d7dad76620bdf39721425e2
# bad: [47cfdc0923bd6af61cea53e7bd6d9a23761efd32] Merge tag 'v4.14.18' into v4.14/standard/base
git bisect bad 47cfdc0923bd6af61cea53e7bd6d9a23761efd32
# good: [345dc6d499d8509ec9cc4b9b5b84a070ac87e0d5] drm/omap: Fix error handling path in 'omap_dmm_probe()'
git bisect good 345dc6d499d8509ec9cc4b9b5b84a070ac87e0d5
# good: [a65710dc584c1c424eb358a1f6e8c01d706e9f81] x86/msr: Add definitions for new speculation control MSRs
git bisect good a65710dc584c1c424eb358a1f6e8c01d706e9f81
# bad: [437ac7b6868da05620764c143c0e4f7aa91e8fc7] x86: Introduce barrier_nospec
git bisect bad 437ac7b6868da05620764c143c0e4f7aa91e8fc7
# good: [76f06358ec400cd5f7c8260fd290e7a7ee20fbcf] ASoC: pcm512x: add missing MODULE_DESCRIPTION/AUTHOR/LICENSE
git bisect good 76f06358ec400cd5f7c8260fd290e7a7ee20fbcf
# bad: [74ae346691dd34d49a5e733af40ca25a4dd42245] x86/spectre: Check CONFIG_RETPOLINE in command line parser
git bisect bad 74ae346691dd34d49a5e733af40ca25a4dd42245
# good: [a358df03279e806f8f4217eacf813c5b6c3578ee] objtool: Improve retpoline alternative handling
git bisect good a358df03279e806f8f4217eacf813c5b6c3578ee
# good: [23a4ca4e749a300a29abff1e304c55b55b6e59a3] objtool: Warn on stripped section symbol
git bisect good 23a4ca4e749a300a29abff1e304c55b55b6e59a3
# bad: [04e073072d1494ce9f60cc2db68fb79aee4283dd] x86/mm: Fix overlap of i386 CPU_ENTRY_AREA with FIX_BTMAP
git bisect bad 04e073072d1494ce9f60cc2db68fb79aee4283dd
# first bad commit: [04e073072d1494ce9f60cc2db68fb79aee4283dd] x86/mm: Fix overlap of i386 CPU_ENTRY_AREA with FIX_BTMAP


This is rather surprising, as this same commit fixed a similar issue with meta-intel's core2-32 kernel, rather than causing it. See bug 12536.
Comment 3 California Sullivan 2018-03-08 10:09:21 UTC
Using intel-core2-32's generated .config, the problem does not reproduce.

Given that it is only this one exact configuration (qemux86, ovmf, qemux86's .config, only Fedora 27 so far, no KVM), it seems like we've hit a perfect storm of a corner case, and I really can't say where the issue is just yet.
Comment 4 California Sullivan 2018-03-08 10:48:48 UTC
I was able to find an upstream commit that fixes this: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git/commit/?id=945fd17ab6bab8a4d05da6c3170519fbcfe62ddb

It unfortunately hasn't hit any stable branches yet.
Comment 5 California Sullivan 2018-03-29 08:02:11 UTC
Fixed here: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git/commit/?h=linux-4.14.y&id=71978491bb6600d39ef68f421c23aeb11c10053f

In v4.14.25. Bruce has sent a kernel update upgrading to v4.14.30, which will incorporate this fix.