Fix a race condition with AMD PMF and Thinkpad-ACPI

Bug #1993242 reported by You-Sheng Yang
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
HWE Next
Fix Released
Undecided
Unassigned
linux (Ubuntu)
Fix Released
Undecided
Unassigned
Jammy
Invalid
Undecided
Unassigned
Kinetic
Invalid
Undecided
Unassigned
Lunar
Fix Released
Undecided
Unassigned
linux-oem-6.0 (Ubuntu)
Invalid
Undecided
Unassigned
Jammy
Fix Released
High
You-Sheng Yang
Kinetic
Invalid
Undecided
Unassigned
Lunar
Invalid
Undecided
Unassigned

Bug Description

[SRU Justification]

[Impact]

Depending on module load order there is a possibility that the AMT mode
selected initially by PMF will be incorrect if thinkpad_acpi has loaded
first.

[Fix]

To avoid this issue adjust the initialization order in the PMF driver.
Commit 22ee98cb696e ("platform/x86/amd/pmf: install notify handler after
acpi init") takes the work, but it depends on two more commits that were
tagged as fixes for commits landed in bug 1987670.

[Test Case]

1. blacklist both amd-pmf and thinkpad-acpi
2. load thinkpad-acpi first
3. Load amd-pmf with dynamic debugging enabled

[Where problems could occur]

The first two parts are trivial, and the third one may have to receive
tests to find out if it has some other interference due to the load
order.

[Other Info]

AMD PMF targets oem-6.0 or above and has included in v6.1-rc1.

========== original bug report ==========

Depending on module load order there is a possibility that the AMT mode selected initially by PMF will be incorrect if thinkpad_acpi has loaded first.

To avoid this issue adjust the initialization order in the PMF driver.

https://github.com/torvalds/linux/commit/22ee98cb696e95b05a188756d479d382d93559ef

You-Sheng Yang (vicamo)
tags: added: amd oem-priority originate-from-1992403
You-Sheng Yang (vicamo)
Changed in linux-oem-6.0 (Ubuntu Kinetic):
status: New → Invalid
description: updated
Revision history for this message
You-Sheng Yang (vicamo) wrote :

This depends on a few more AMD PMF fixes:
* c2f7edf81a82 ("platform/x86/amd/pmf: Fix undefined reference to platform_profile")
* ea522b806162 ("platform/x86/amd/pmf: Fix clang unused variable warning")

These two commits also have Fixes tag for commits previously landed in bug 1987670.

Changed in linux-oem-6.0 (Ubuntu Jammy):
status: New → Confirmed
You-Sheng Yang (vicamo)
Changed in linux-oem-6.0 (Ubuntu Jammy):
status: Confirmed → In Progress
importance: Undecided → High
assignee: nobody → You-Sheng Yang (vicamo)
Revision history for this message
You-Sheng Yang (vicamo) wrote :
description: updated
Timo Aaltonen (tjaalton)
Changed in linux-oem-6.0 (Ubuntu Jammy):
status: In Progress → Fix Committed
Changed in linux (Ubuntu Jammy):
status: New → Invalid
Changed in linux (Ubuntu Kinetic):
status: New → Invalid
Changed in linux (Ubuntu Lunar):
status: New → Invalid
status: Invalid → Triaged
Timo Aaltonen (tjaalton)
tags: added: verification-needed-jammy
Revision history for this message
You-Sheng Yang (vicamo) wrote :

verified linux-oem-6.0/jammy version 6.0.0-1008.8.

tags: added: verification-done-jammy
removed: verification-needed-jammy
Changed in linux (Ubuntu Lunar):
status: Triaged → Fix Released
Revision history for this message
You-Sheng Yang (vicamo) wrote :

These commits is already in v6.1, so they will be in lunar generic kernel once released.

Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (48.0 KiB)

This bug was fixed in the package linux-oem-6.0 - 6.0.0-1008.8

---------------
linux-oem-6.0 (6.0.0-1008.8) jammy; urgency=medium

  * jammy/linux-oem-6.0: 6.0.0-1008.8 -proposed tracker (LP: #1996347)

  * Packaging resync (LP: #1786013)
    - debian/dkms-versions -- update from kernel-versions (main/2022.11.14)

  * Fix a race condition with AMD PMF and Thinkpad-ACPI (LP: #1993242)
    - platform/x86/amd/pmf: Fix undefined reference to platform_profile
    - platform/x86/amd/pmf: Fix clang unused variable warning
    - platform/x86/amd/pmf: install notify handler after acpi init

  * Screen freeze after resuming from suspend (nvme0: I/O timeout)
    (LP: #1996048)
    - SAUCE: PCI: vmd: Disable MSI remapping after suspend

  * Fibocom WWAN FM350-GL suspend error (notebook not suspend) (LP: #1990700)
    - net: wwan: t7xx: Add AP CLDMA

  * Add some ACPI device IDs for Intel HID device (LP: #1995453)
    - platform/x86/intel/hid: Add some ACPI device IDs

  * amd_sfh modprobe fails when no sensor reported from AMD MP2 (LP: #1993240)
    - HID: amd_sfh: Change dev_err to dev_dbg for additional debug info

  * Jammy update: v6.0.9 upstream stable release (LP: #1996785)
    - drm/i915/gvt: Add missing vfio_unregister_group_dev() call
    - m68k: Rework BI_VIRT_RNG_SEED as BI_RNG_SEED
    - KVM: debugfs: Return retval of simple_attr_open() if it fails
    - drm/i915: Allow more varied alternate fixed modes for panels
    - drm/i915: Simplify intel_panel_add_edid_alt_fixed_modes()
    - drm/i915/sdvo: Grab mode_config.mutex during LVDS init to avoid WARNs
    - drm/amd/display: Acquire FCLK DPM levels on DCN32
    - drm/amd/display: Limit dcn32 to 1950Mhz display clock
    - drm/amd/display: Set memclk levels to be at least 1 for dcn32
    - drm/amdkfd: handle CPU fault on COW mapping
    - drm/amdkfd: Fix NULL pointer dereference in svm_migrate_to_ram()
    - cxl/region: Recycle region ids
    - HID: wacom: Fix logic used for 3rd barrel switch emulation
    - hwspinlock: qcom: correct MMIO max register for newer SoCs
    - phy: stm32: fix an error code in probe
    - wifi: cfg80211: silence a sparse RCU warning
    - wifi: cfg80211: fix memory leak in query_regdb_file()
    - soundwire: qcom: reinit broadcast completion
    - soundwire: qcom: check for outanding writes before doing a read
    - ALSA: arm: pxa: pxa2xx-ac97-lib: fix return value check of
      platform_get_irq()
    - spi: mediatek: Fix package division error
    - bpf, verifier: Fix memory leak in array reallocation for stack state
    - bpf, sockmap: Fix the sk->sk_forward_alloc warning of sk_stream_kill_queues
    - wifi: mac80211: fix general-protection-fault in ieee80211_subif_start_xmit()
    - wifi: mac80211: Set TWT Information Frame Disabled bit as 1
    - bpftool: Fix NULL pointer dereference when pin {PROG, MAP, LINK} without
      FILE
    - HID: hyperv: fix possible memory leak in mousevsc_probe()
    - drm/vc4: hdmi: Fix HSM clock too low on Pi4
    - bpf, sock_map: Move cancel_work_sync() out of sock lock
    - PCI: hv: Fix the definition of vector in hv_compose_msi_msg()
    - bpf: Add helper macro bpf_for_each_reg_in_vstate
    - bpf: Fix wrong reg type conversi...

Changed in linux-oem-6.0 (Ubuntu Jammy):
status: Fix Committed → Fix Released
You-Sheng Yang (vicamo)
Changed in hwe-next:
status: New → 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.