Bug 2334677 (CVE-2024-56699) - CVE-2024-56699 kernel: s390/pci: Fix potential double remove of hotplug slot
Summary: CVE-2024-56699 kernel: s390/pci: Fix potential double remove of hotplug slot
Keywords:
Status: NEW
Alias: CVE-2024-56699
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
low
low
Target Milestone: ---
Assignee: Product Security DevOps Team
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2024-12-28 10:01 UTC by OSIDB Bzimport
Modified: 2024-12-29 06:49 UTC (History)
4 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed:
Embargoed:


Attachments (Terms of Use)

Description OSIDB Bzimport 2024-12-28 10:01:59 UTC
In the Linux kernel, the following vulnerability has been resolved:

s390/pci: Fix potential double remove of hotplug slot

In commit 6ee600bfbe0f ("s390/pci: remove hotplug slot when releasing the
device") the zpci_exit_slot() was moved from zpci_device_reserved() to
zpci_release_device() with the intention of keeping the hotplug slot
around until the device is actually removed.

Now zpci_release_device() is only called once all references are
dropped. Since the zPCI subsystem only drops its reference once the
device is in the reserved state it follows that zpci_release_device()
must only deal with devices in the reserved state. Despite that it
contains code to tear down from both configured and standby state. For
the standby case this already includes the removal of the hotplug slot
so would cause a double removal if a device was ever removed in
either configured or standby state.

Instead of causing a potential double removal in a case that should
never happen explicitly WARN_ON() if a device in non-reserved state is
released and get rid of the dead code cases.

Comment 1 Avinash Hanwate 2024-12-29 06:46:22 UTC
Upstream advisory:
https://lore.kernel.org/linux-cve-announce/2024122836-CVE-2024-56699-a3d3@gregkh/T


Note You need to log in before you can comment on or make changes to this bug.