Bug 2358224 (CVE-2025-22017) - CVE-2025-22017 kernel: devlink: fix xa_alloc_cyclic() error handling
Summary: CVE-2025-22017 kernel: devlink: fix xa_alloc_cyclic() error handling
Keywords:
Status: NEW
Alias: CVE-2025-22017
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Product Security DevOps Team
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2025-04-08 09:01 UTC by OSIDB Bzimport
Modified: 2025-04-09 09:17 UTC (History)
4 users (show)

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


Attachments (Terms of Use)

Description OSIDB Bzimport 2025-04-08 09:01:34 UTC
In the Linux kernel, the following vulnerability has been resolved:

devlink: fix xa_alloc_cyclic() error handling

In case of returning 1 from xa_alloc_cyclic() (wrapping) ERR_PTR(1) will
be returned, which will cause IS_ERR() to be false. Which can lead to
dereference not allocated pointer (rel).

Fix it by checking if err is lower than zero.

This wasn't found in real usecase, only noticed. Credit to Pierre.


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