Skip to content
OpenAdvisories
Unscored CVE-2021-47005 EUVD-2021-33653GHSA-43jg-wxfj-4rf7

PCI: endpoint: Fix NULL pointer dereference for ->get_features()

Published Feb 28, 2024 · Updated May 11, 2026 · Assigned by Linux

Description

In the Linux kernel, the following vulnerability has been resolved:

PCI: endpoint: Fix NULL pointer dereference for ->get_features()

get_features ops of pci_epc_ops may return NULL, causing NULL pointer
dereference in pci_epf_test_alloc_space function. Let us add a check for
pci_epc_feature pointer in pci_epf_test_bind before we access it to avoid
any such NULL pointer dereference and return -ENOTSUPP in case
pci_epc_feature is not found.

When the patch is not applied and EPC features is not implemented in the
platform driver, we see the following dump due to kernel NULL pointer
dereference.

Call trace:
pci_epf_test_bind+0xf4/0x388
pci_epf_bind+0x3c/0x80
pci_epc_epf_link+0xa8/0xcc
configfs_symlink+0x1a4/0x48c
vfs_symlink+0x104/0x184
do_symlinkat+0x80/0xd4
__arm64_sys_symlinkat+0x1c/0x24
el0_svc_common.constprop.3+0xb8/0x170
el0_svc_handler+0x70/0x88
el0_svc+0x8/0x640
Code: d2800581 b9403ab9 f9404ebb 8b394f60 (f9400400)
---[ end trace a438e3c5a24f9df0 ]---

Affected products

VendorProductAffectedFixed
Linux Linux 5.1 5.10.38

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Debian 14 linux 5.10.38-1 —
Debian 13 linux 5.10.38-1 —
Debian 12 linux 5.10.38-1 —
ReleasePackageFixed inAdvisory
Ubuntu 24.04 LTS linux-raspi-realtime No fix yet —
Ubuntu 22.04 LTS linux-realtime +1 No fix yet —
Show 2 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
Ubuntu Pro FIPS 20.04 LTS linux-aws-fips +2 No fix yet —
Ubuntu Pro FIPS-updates 20.04 LTS linux-aws-fips +2 No fix yet —
ReleasePackageFixed inAdvisory
SLES 15 SP3 kernel-64kb +6 5.3.18-150300.59.153.2 SUSE-SU-2024:0857-1
SLES 15 SP3 kernel-default-base 5.3.18-150300.59.153.2.150300.18.90.2 SUSE-SU-2024:0857-1
SLES 15 SP3 kernel-syms 5.3.18-150300.59.153.1 SUSE-SU-2024:0857-1
SLES 15 SP2 kernel-default-base 5.3.18-150200.24.183.1.150200.9.93.2 SUSE-SU-2024:0926-1
SLES 15 SP2 kernel-docs +5 5.3.18-150200.24.183.1 SUSE-SU-2024:0926-1
Show 9 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
SLES for SAP 15 SP3 kernel-default-base 5.3.18-150300.59.153.2.150300.18.90.2 SUSE-SU-2024:0857-1
SLES for SAP 15 SP3 kernel-docs +4 5.3.18-150300.59.153.2 SUSE-SU-2024:0857-1
SLES for SAP 15 SP3 kernel-syms 5.3.18-150300.59.153.1 SUSE-SU-2024:0857-1
SLES for SAP 15 SP2 kernel-default-base 5.3.18-150200.24.183.1.150200.9.93.2 SUSE-SU-2024:0926-1
SLES for SAP 15 SP2 kernel-docs +5 5.3.18-150200.24.183.1 SUSE-SU-2024:0926-1
SLE Micro 5.2 kernel-default 5.3.18-150300.59.153.2 SUSE-SU-2024:0857-1
SLE Micro 5.2 kernel-default-base 5.3.18-150300.59.153.2.150300.18.90.2 SUSE-SU-2024:0857-1
SLE Micro 5.2 kernel-rt +1 5.3.18-150300.161.1 SUSE-SU-2024:0856-1
SLE Micro 5.1 kernel-default 5.3.18-150300.59.153.2 SUSE-SU-2024:0857-1
SLE Micro 5.1 kernel-default-base 5.3.18-150300.59.153.2.150300.18.90.2 SUSE-SU-2024:0857-1
SLE Micro 5.1 kernel-rt +1 5.3.18-150300.161.1 SUSE-SU-2024:0856-1
SLE Live Patching 15 SP3 kernel-default 5.3.18-150300.59.153.2 SUSE-SU-2024:0857-1
SLE Live Patching 15 SP3 kernel-livepatch-SLE15-SP3_Update_42 1-150300.7.3.2 SUSE-SU-2024:0857-1
SLE Live Patching 15 SP2 kernel-default 5.3.18-150200.24.183.1 SUSE-SU-2024:0926-1
SLE Live Patching 15 SP2 kernel-livepatch-SLE15-SP2_Update_46 1-150200.5.3.2 SUSE-SU-2024:0926-1
SLE HPC 15 SP3 kernel-64kb +5 5.3.18-150300.59.153.2 SUSE-SU-2024:0857-1
SLE HPC 15 SP3 kernel-default-base 5.3.18-150300.59.153.2.150300.18.90.2 SUSE-SU-2024:0857-1
SLE HPC 15 SP3 kernel-syms 5.3.18-150300.59.153.1 SUSE-SU-2024:0857-1
SLE HPC 15 SP2 kernel-default-base 5.3.18-150200.24.183.1.150200.9.93.2 SUSE-SU-2024:0926-1
SLE HPC 15 SP2 kernel-docs +5 5.3.18-150200.24.183.1 SUSE-SU-2024:0926-1
SUSE Enterprise Storage 7.1 kernel-64kb +5 5.3.18-150300.59.153.2 SUSE-SU-2024:0857-1
SUSE Enterprise Storage 7.1 kernel-default-base 5.3.18-150300.59.153.2.150300.18.90.2 SUSE-SU-2024:0857-1
SUSE Enterprise Storage 7.1 kernel-syms 5.3.18-150300.59.153.1 SUSE-SU-2024:0857-1

Advisories 3

References