test_sysctl in bpf from ubuntu_kernel_selftests make net test fails to build on eoan

Bug #1862263 reported by Sultan Alsawaf
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
ubuntu-kernel-tests
Fix Released
Undecided
Po-Hsu Lin
linux (Ubuntu)
Fix Released
Undecided
Unassigned
Eoan
Fix Released
Undecided
Po-Hsu Lin

Bug Description

== SRU Justification ==
Commit 7541c87c ("bpf: Allow narrow loads of bpf_sysctl fields with
offset > 0") applied to Eoan tree via stable-update process brought a
member called "seek" to tools/testing/selftests/bpf/test_sysctl.c:
   .seek = 4,

However we don't have the commit that declares it, so the compilation
failed with:
    test_sysctl.c:181:4: error: ‘struct sysctl_test’ has no member named ‘seek’
      181 | .seek = 4,
          | ^~~~

== Fix ==
* d895a0f1 ("bpf: fix accessing bpf_sysctl.file_pos on s390")

Only Eoan is affected.

== Test ==
Patch tested against the affected kernels, the bpf test can be built
without any issue.

== Regression Potential ==
Low, changes limited to testing tools.

==Original Bug Report ==
test_sysctl.c:181:4: error: ‘struct sysctl_test’ has no member named ‘seek’
    181 | .seek = 4,
        | ^~~~

This affects all arches. Kernel 5.3.0-40.32.

CVE References

description: updated
Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote : Missing required logs.

This bug is missing log files that will aid in diagnosing the problem. While running an Ubuntu kernel (not a mainline or third-party kernel) please enter the following command in a terminal window:

apport-collect 1862263

and then change the status of the bug to 'Confirmed'.

If, due to the nature of the issue you have encountered, you are unable to run this command, please add a comment stating that fact and change the bug status to 'Confirmed'.

This change has been made by an automated script, maintained by the Ubuntu Kernel Team.

Changed in linux (Ubuntu):
status: New → Incomplete
Changed in linux (Ubuntu Eoan):
status: New → Incomplete
tags: added: eoan
Po-Hsu Lin (cypressyew)
summary: - test_sysctl in ubuntu_kernel_selftests fails to build on eoan
+ test_sysctl in net from ubuntu_kernel_selftests fails to build on eoan
Revision history for this message
Po-Hsu Lin (cypressyew) wrote :

To be clear, it's the bpf test that's causing this problem.

gcc -g -Wall -O2 -I../../../include/uapi -I../../../lib -I../../../lib/bpf -I../../../../include/generated -I../../../include -Dbpf_prog_load=bpf_prog_test_load -Dbpf_load_program=bpf_test_load_program test_tcpnotify_user.c /home/ubuntu/ubuntu-eoan/tools/testing/selftests/bpf/test_stub.o /home/ubuntu/ubuntu-eoan/tools/testing/selftests/bpf/libbpf.a cgroup_helpers.c trace_helpers.c -lcap -lelf -lrt -lpthread -o /home/ubuntu/ubuntu-eoan/tools/testing/selftests/bpf/test_tcpnotify_user
test_tcpnotify_user.c: In function ‘main’:
test_tcpnotify_user.c:153:2: warning: ignoring return value of ‘system’, declared with attribute warn_unused_result [-Wunused-result]
  153 | system(test_script);
      | ^~~~~~~~~~~~~~~~~~~
test_tcpnotify_user.c:158:2: warning: ignoring return value of ‘system’, declared with attribute warn_unused_result [-Wunused-result]
  158 | system(test_script);
      | ^~~~~~~~~~~~~~~~~~~
test_tcpnotify_user.c:163:2: warning: ignoring return value of ‘system’, declared with attribute warn_unused_result [-Wunused-result]
  163 | system(test_script);
      | ^~~~~~~~~~~~~~~~~~~
gcc -g -Wall -O2 -I../../../include/uapi -I../../../lib -I../../../lib/bpf -I../../../../include/generated -I../../../include -Dbpf_prog_load=bpf_prog_test_load -Dbpf_load_program=bpf_test_load_program test_sock_fields.c /home/ubuntu/ubuntu-eoan/tools/testing/selftests/bpf/test_stub.o /home/ubuntu/ubuntu-eoan/tools/testing/selftests/bpf/libbpf.a cgroup_helpers.c -lcap -lelf -lrt -lpthread -o /home/ubuntu/ubuntu-eoan/tools/testing/selftests/bpf/test_sock_fields
gcc -g -Wall -O2 -I../../../include/uapi -I../../../lib -I../../../lib/bpf -I../../../../include/generated -I../../../include -Dbpf_prog_load=bpf_prog_test_load -Dbpf_load_program=bpf_test_load_program test_sysctl.c /home/ubuntu/ubuntu-eoan/tools/testing/selftests/bpf/test_stub.o /home/ubuntu/ubuntu-eoan/tools/testing/selftests/bpf/libbpf.a cgroup_helpers.c -lcap -lelf -lrt -lpthread -o /home/ubuntu/ubuntu-eoan/tools/testing/selftests/bpf/test_sysctl
test_sysctl.c:181:4: error: ‘struct sysctl_test’ has no member named ‘seek’
  181 | .seek = 4,
      | ^~~~
test_sysctl.c:181:11: warning: initialization of ‘const char *’ from ‘int’ makes pointer from integer without a cast [-Wint-conversion]
  181 | .seek = 4,
      | ^
test_sysctl.c:181:11: note: (near initialization for ‘tests[7].newval’)
make[1]: *** [../lib.mk:138: /home/ubuntu/ubuntu-eoan/tools/testing/selftests/bpf/test_sysctl] Error 1
make[1]: Leaving directory '/home/ubuntu/ubuntu-eoan/tools/testing/selftests/bpf'
make: *** [Makefile:137: all] Error 2

We need some module in bpf, so this was triggered in the beginning of the net test.

summary: - test_sysctl in net from ubuntu_kernel_selftests fails to build on eoan
+ test_sysctl in bpf from ubuntu_kernel_selftests make net test fails to
+ build on eoan
Revision history for this message
Po-Hsu Lin (cypressyew) wrote :
tags: added: 5.3 sru-20200127 ubuntu-kernel-selftests
Po-Hsu Lin (cypressyew)
Changed in linux (Ubuntu):
status: Incomplete → Fix Released
Changed in linux (Ubuntu Eoan):
status: Incomplete → In Progress
Changed in ubuntu-kernel-tests:
status: New → In Progress
assignee: nobody → Po-Hsu Lin (cypressyew)
Changed in linux (Ubuntu Eoan):
assignee: nobody → Po-Hsu Lin (cypressyew)
Po-Hsu Lin (cypressyew)
description: updated
Changed in linux (Ubuntu Eoan):
status: In Progress → Fix Committed
Po-Hsu Lin (cypressyew)
Changed in ubuntu-kernel-tests:
status: In Progress → Fix Released
status: Fix Released → In Progress
Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote :

This bug is awaiting verification that the kernel in -proposed solves the problem. Please test the kernel and update this bug with the results. If the problem is solved, change the tag 'verification-needed-eoan' to 'verification-done-eoan'. If the problem still exists, change the tag 'verification-needed-eoan' to 'verification-failed-eoan'.

If verification is not done by 5 working days from today, this fix will be dropped from the source code, and this bug will be closed.

See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you!

tags: added: verification-needed-eoan
Revision history for this message
Po-Hsu Lin (cypressyew) wrote :

Passed on node rizzo with 5.3.0-41.33

tags: added: verification-done-eoan
removed: verification-needed-eoan
Changed in ubuntu-kernel-tests:
status: In Progress → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (48.0 KiB)

This bug was fixed in the package linux - 5.3.0-42.34

---------------
linux (5.3.0-42.34) eoan; urgency=medium

  * eoan/linux: 5.3.0-42.34 -proposed tracker (LP: #1865111)

  * CVE-2020-2732
    - KVM: nVMX: Don't emulate instructions in guest mode
    - KVM: nVMX: Refactor IO bitmap checks into helper function
    - KVM: nVMX: Check IO instruction VM-exit conditions

linux (5.3.0-41.33) eoan; urgency=medium

  * eoan/linux: 5.3.0-41.33 -proposed tracker (LP: #1863294)

  * CVE-2019-3016
    - x86/kvm: Be careful not to clear KVM_VCPU_FLUSH_TLB bit
    - x86/kvm: Introduce kvm_(un)map_gfn()
    - x86/kvm: Cache gfn to pfn translation
    - x86/KVM: Make sure KVM_VCPU_FLUSH_TLB flag is not missed
    - x86/KVM: Clean up host's steal time structure

  * Reduce s2idle power consumption when ethernet cable is connected on e1000e
    (LP: #1859126)
    - e1000e: Add support for S0ix

  * alsa/sof: let legacy hda driver and sof driver co-exist (LP: #1837828)
    - ASoC: Intel: Skylake: move NHLT header to common directory
    - ALSA: hda: move parts of NHLT code to new module
    - ALSA: hda: intel-nhlt: handle NHLT VENDOR_DEFINED DMIC geometry
    - ASoC: Intel: Skylake: use common NHLT module
    - ALSA: hda/intel: stop probe if DMICS are detected on Skylake+ platforms
    - [Config] Enable SND_HDA_INTEL_DETECT_DMIC

  * USB key cannot be detected by hotplug on Sunix USB Type-A 3.1 Gen 2 card
    [1b21:2142] (LP: #1858988)
    - SAUCE: PCI: Avoid ASMedia XHCI USB PME# from D0 defect

  * ipsec interfaces: fix sending with bpf_redirect() / AF_PACKET sockets
    (LP: #1860969)
    - vti[6]: fix packet tx through bpf_redirect()
    - xfrm interface: fix packet tx through bpf_redirect()

  * peripheral devices on Dell WD19TB cannot be detected after suspend resume
    (LP: #1859407)
    - PCI: irq: Introduce rearm_wake_irq()
    - ACPICA: Return u32 from acpi_dispatch_gpe()
    - ACPI: EC: Return bool from acpi_ec_dispatch_gpe()
    - ACPI: PM: Set s2idle_wakeup earlier and clear it later
    - PM: sleep: Simplify suspend-to-idle control flow
    - ACPI: EC: Rework flushing of pending work

  * Dell XPS 13 (7390) Display Flickering - 19.10 (LP: #1849947)
    - SAUCE: drm/i915: Disable PSR by default on all platforms

  * Root can lift kernel lockdown via USB/IP (LP: #1861238)
    - Revert "UBUNTU: SAUCE: (efi-lockdown) Add a SysRq option to lift kernel
      lockdown"

  * [CML-H] Add intel_thermal_pch driver support Comet Lake -H (LP: #1853219)
    - thermal: intel: intel_pch_thermal: Add Comet Lake (CML) platform support

  * Eoan update: upstream stable patchset 2020-02-07 (LP: #1862429)
    - ARM: dts: meson8: fix the size of the PMU registers
    - clk: qcom: gcc-sdm845: Add missing flag to votable GDSCs
    - dt-bindings: reset: meson8b: fix duplicate reset IDs
    - ARM: dts: imx6q-dhcom: fix rtc compatible
    - clk: Don't try to enable critical clocks if prepare failed
    - ASoC: msm8916-wcd-digital: Reset RX interpolation path after use
    - iio: buffer: align the size of scan bytes to size of the largest element
    - USB: serial: simple: Add Motorola Solutions TETRA MTP3xxx and MTP85xx
    - USB: serial: option: Add support for Quec...

Changed in linux (Ubuntu Eoan):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.