{"id":"CVE-2022-50337","aliases":["CVE-2022-50337"],"related":[],"kind":"vulnerability","state":"published","title":"ocxl: fix pci device refcount leak when calling get_function_0()","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\nocxl: fix pci device refcount leak when calling get_function_0()\n\nget_function_0() calls pci_get_domain_bus_and_slot(), as comment\nsays, it returns a pci device with refcount increment, so after\nusing it, pci_dev_put() needs be called.\n\nGet the device reference when get_function_0() is not called, so\npci_dev_put() can be called in the error path and callers\nunconditionally. And add comment above get_dvsec_vendor0() to tell\ncallers to call pci_dev_put().","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\nocxl: fix pci device refcount leak when calling get_function_0()\n\nget_function_0() calls pci_get_domain_bus_and_slot(), as comment\nsays, it returns a pci device with refcount increment, so after\nusing it, pci_dev_put() needs be called.\n\nGet the device reference when get_function_0() is not called, so\npci_dev_put() can be called in the error path and callers\nunconditionally. And add comment above get_dvsec_vendor0() to tell\ncallers to call pci_dev_put().","source":"cvelist"}],"published":"2025-09-15T14:49:52.919Z","modified":"2026-11-05T20:17:35.770Z","severity":{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"},"severities":[{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H","score":5.5,"rating":"MEDIUM"}],"cwes":[],"affected":[{"ranges":[{"type":"git","introduced":"87db7579ebd5ded337056eb765542eb2608f16e3","fixed":"a40e1b0a922a53fa925ea8b296e3de30a31ed028","status":"affected"},{"type":"git","introduced":"87db7579ebd5ded337056eb765542eb2608f16e3","fixed":"37a13b274e4513c757e50c002ddcbf4bc89adbb2","status":"affected"},{"type":"git","introduced":"87db7579ebd5ded337056eb765542eb2608f16e3","fixed":"9a1b3148975b71fdc194e62612478346bbe618cd","status":"affected"},{"type":"git","introduced":"87db7579ebd5ded337056eb765542eb2608f16e3","fixed":"40ff4c2335a98f0ee96b099bfd70b8e6644f321f","status":"affected"},{"type":"git","introduced":"87db7579ebd5ded337056eb765542eb2608f16e3","fixed":"27158c72678b39ee01cc01de1aba6b51c71abe2f","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"5.9","status":"affected"},{"type":"semver","introduced":"0","fixed":"5.9","status":"unaffected"},{"type":"semver","introduced":"5.10.163","lastAffected":"5.10.*","status":"unaffected"},{"type":"semver","introduced":"5.15.86","lastAffected":"5.15.*","status":"unaffected"},{"type":"semver","introduced":"6.0.16","lastAffected":"6.0.*","status":"unaffected"},{"type":"semver","introduced":"6.1.2","lastAffected":"6.1.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"6.2","lastAffected":"*","status":"unaffected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"status":"affected","introduced":"5.9","fixed":"5.10.163"},{"status":"affected","introduced":"5.11","fixed":"5.15.86"},{"status":"affected","introduced":"5.16","fixed":"6.0.16"},{"status":"affected","introduced":"6.1","fixed":"6.1.2"}],"vendor":"linux","product":"linux_kernel","cpe":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://git.kernel.org/stable/c/a40e1b0a922a53fa925ea8b296e3de30a31ed028","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/37a13b274e4513c757e50c002ddcbf4bc89adbb2","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/9a1b3148975b71fdc194e62612478346bbe618cd","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/40ff4c2335a98f0ee96b099bfd70b8e6644f321f","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/27158c72678b39ee01cc01de1aba6b51c71abe2f","tags":["patch"],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"partial","date":"2026-11-05T20:10:19.633Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2022-50337","url":"https://www.cve.org/CVERecord?id=CVE-2022-50337","licence":"CVE Terms of Use","modified":"2026-11-05T20:10:36.146Z"},{"source":"nvd","name":"NVD","id":"CVE-2022-50337","url":"https://nvd.nist.gov/vuln/detail/CVE-2022-50337","licence":"Public domain","modified":"2026-11-05T20:17:35.770Z"}],"updatedAt":"2026-11-25T22:58:21.170Z","epss":{"score":0.00166,"percentile":0.06102,"date":"2026-12-02T12:00:21.000Z"}}