# CVE-2022-49353: powerpc/papr\_scm: don't requests stats with '0' sized stats buffer

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** MEDIUM 5.5
- **CVSS:** 5.5 (v3.1, CNA) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: None; Integrity impact: None; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.24% (percentile 9, 2026-11-26)
- **CWE:** CWE-476
- **Published:** 2025-02-26T02:11:04.982Z
- **Modified:** 2026-06-17T05:17:48.163Z

## Who should check

- Anyone running Linux \>= b073096df4dec70d0436321b7093bad27ae91f9e, \< e1295aab2ebcda1c1a9ed342baedc080e5c393e5; \>= 0e0946e22f3665d27325d389ff45ade6e93f3678, \< 07bf9431b1590d1cd7a8d62075d0b50b073f0495
- Anyone running Linux \>= 5.18.3, \< 5.18.4

## Description

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

powerpc/papr\_scm: don't requests stats with '0' sized stats buffer

Sachin reported \[1\] that on a POWER-10 lpar he is seeing a kernel panic being
reported with vPMEM when papr\_scm probe is being called. The panic is of the
form below and is observed only with following option disabled(profile) for the
said LPAR 'Enable Performance Information Collection' in the HMC:

 Kernel attempted to write user page (1c) - exploit attempt? (uid: 0)
 BUG: Kernel NULL pointer dereference on write at 0x0000001c
 Faulting instruction address: 0xc008000001b90844
 Oops: Kernel access of bad area, sig: 11 \[\#1\]
\<snip\>
 NIP \[c008000001b90844\] drc\_pmem\_query\_stats+0x5c/0x270 \[papr\_scm\]
 LR \[c008000001b92794\] papr\_scm\_probe+0x2ac/0x6ec \[papr\_scm\]
 Call Trace:
       0xc00000000941bca0 (unreliable)
       papr\_scm\_probe+0x2ac/0x6ec \[papr\_scm\]
       platform\_probe+0x98/0x150
       really\_probe+0xfc/0x510
       \_\_driver\_probe\_device+0x17c/0x230
\<snip\>
 ---\[ end trace 0000000000000000 \]---
 Kernel panic - not syncing: Fatal exception

On investigation looks like this panic was caused due to a 'stat\_buffer' of
size==0 being provided to drc\_pmem\_query\_stats() to fetch all performance
stats-ids of an NVDIMM. However drc\_pmem\_query\_stats() shouldn't have been called
since the vPMEM NVDIMM doesn't support and performance stat-id's. This was caused
due to missing check for 'p-\>stat\_buffer\_len' at the beginning of
papr\_scm\_pmu\_check\_events() which indicates that the NVDIMM doesn't support
performance-stats.

Fix this by introducing the check for 'p-\>stat\_buffer\_len' at the beginning of
papr\_scm\_pmu\_check\_events().

\[1\] https://lore.kernel.org/all/6B3A522A-6A5F-4CC9-B268-0C63AA6E07D3@linux.ibm.com

## Affected and fixed versions

- Linux: \>= b073096df4dec70d0436321b7093bad27ae91f9e, \< e1295aab2ebcda1c1a9ed342baedc080e5c393e5; \>= 0e0946e22f3665d27325d389ff45ade6e93f3678, \< 07bf9431b1590d1cd7a8d62075d0b50b073f0495 (cvelist)
- Linux: \>= 5.18.3, \< 5.18.4 (cvelist)

## Mitigation

- Upgrade Linux to 07bf9431b1590d1cd7a8d62075d0b50b073f0495 or later.
- Upgrade Linux to 5.18.4 or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2022-49353. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2022-49353.md
Affected: Linux >= b073096df4dec70d0436321b7093bad27ae91f9e, < e1295aab2ebcda1c1a9ed342baedc080e5c393e5; >= 0e0946e22f3665d27325d389ff45ade6e93f3678, < 07bf9431b1590d1cd7a8d62075d0b50b073f0495; Linux >= 5.18.3, < 5.18.4
Fixed in: Linux 07bf9431b1590d1cd7a8d62075d0b50b073f0495, Linux 5.18.4

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2022-49353 being exploited?

There is no confirmed exploitation: CVE-2022-49353 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.24% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2022-49353?

Medium: CVSS 5.5 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2022-49353?

Linux \>= b073096df4dec70d0436321b7093bad27ae91f9e, \< e1295aab2ebcda1c1a9ed342baedc080e5c393e5; \>= 0e0946e22f3665d27325d389ff45ade6e93f3678, \< 07bf9431b1590d1cd7a8d62075d0b50b073f0495; Linux \>= 5.18.3, \< 5.18.4.

### Is there a fix for CVE-2022-49353?

Yes. Fixed in Linux 07bf9431b1590d1cd7a8d62075d0b50b073f0495, Linux 5.18.4. Upgrade Linux to 07bf9431b1590d1cd7a8d62075d0b50b073f0495 or later. Upgrade Linux to 5.18.4 or later.

### How do I check if I'm affected by CVE-2022-49353?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- patch: <https://git.kernel.org/stable/c/e1295aab2ebcda1c1a9ed342baedc080e5c393e5>
- patch: <https://git.kernel.org/stable/c/07bf9431b1590d1cd7a8d62075d0b50b073f0495>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2022-49353>

HTML: <https://flawdb.com/CVE-2022-49353> · JSON: <https://flawdb.com/api/v1/entries/CVE-2022-49353>
