{"id":"CVE-2026-31567","state":"PUBLISHED","title":"PM: sleep: Drop spurious WARN_ON() from pm_restore_gfp_mask()","description":"In the Linux kernel, the following vulnerability has been resolved:\n\nPM: sleep: Drop spurious WARN_ON() from pm_restore_gfp_mask()\n\nCommit 35e4a69b2003f (\"PM: sleep: Allow pm_restrict_gfp_mask()\nstacking\") introduced refcount-based GFP mask management that warns\nwhen pm_restore_gfp_mask() is called with saved_gfp_count == 0.\n\nSome hibernation paths call pm_restore_gfp_mask() defensively where\nthe GFP mask may or may not be restricted depending on the execution\npath. For example, the uswsusp interface invokes it in\nSNAPSHOT_CREATE_IMAGE, SNAPSHOT_UNFREEZE, and snapshot_release().\nBefore the stacking change this was a silent no-op; it now triggers\na spurious WARNING.\n\nRemove the WARN_ON() wrapper from the !saved_gfp_count check while\nretaining the check itself, so that defensive calls remain harmless\nwithout producing false warnings.\n\n[ rjw: Subject tweak ]","publishedAt":"2026-04-24T14:35:47.453Z","updatedAt":"2026-05-23T16:05:25.080Z","severity":null,"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"35e4a69b2003f20a69e7d19ae96ab1eef1aa8e8d","status":"affected","lessThan":"3025ca5daa9d682b629c0c958b538e41deeb559d","versionType":"git"},{"version":"35e4a69b2003f20a69e7d19ae96ab1eef1aa8e8d","status":"affected","lessThan":"f19d1323aa3dd7ead469aef47d9085f8939565d9","versionType":"git"},{"version":"35e4a69b2003f20a69e7d19ae96ab1eef1aa8e8d","status":"affected","lessThan":"a8d51efb5929ae308895455a3e496b5eca2cd143","versionType":"git"},{"version":"4ddf7293928cb619077724b7d828734da8181e6c","status":"affected","versionType":"git"},{"version":"6.17.8","status":"affected","lessThan":"6.18","versionType":"semver"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["kernel/power/main.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.18","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.18","versionType":"semver"},{"version":"6.18.21","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"6.19.11","status":"unaffected","lessThanOrEqual":"6.19.*","versionType":"semver"},{"version":"7.0","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["kernel/power/main.c"]}],"references":["https://git.kernel.org/stable/c/3025ca5daa9d682b629c0c958b538e41deeb559d","https://git.kernel.org/stable/c/f19d1323aa3dd7ead469aef47d9085f8939565d9","https://git.kernel.org/stable/c/a8d51efb5929ae308895455a3e496b5eca2cd143"],"weaknesses":[],"ingestedAt":"2026-10-29T20:11:40.391Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2026/31xxx/CVE-2026-31567.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2026-31567","state":"PUBLISHED","datePublished":"2026-04-24T14:35:47.453Z","dateUpdated":"2026-05-23T16:05:25.080Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2026-03-09T15:48:24.117Z"},"containers":{"cna":{"title":"PM: sleep: Drop spurious WARN_ON() from pm_restore_gfp_mask()","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\nPM: sleep: Drop spurious WARN_ON() from pm_restore_gfp_mask()\n\nCommit 35e4a69b2003f (\"PM: sleep: Allow pm_restrict_gfp_mask()\nstacking\") introduced refcount-based GFP mask management that warns\nwhen pm_restore_gfp_mask() is called with saved_gfp_count == 0.\n\nSome hibernation paths call pm_restore_gfp_mask() defensively where\nthe GFP mask may or may not be restricted depending on the execution\npath. For example, the uswsusp interface invokes it in\nSNAPSHOT_CREATE_IMAGE, SNAPSHOT_UNFREEZE, and snapshot_release().\nBefore the stacking change this was a silent no-op; it now triggers\na spurious WARNING.\n\nRemove the WARN_ON() wrapper from the !saved_gfp_count check while\nretaining the check itself, so that defensive calls remain harmless\nwithout producing false warnings.\n\n[ rjw: Subject tweak ]"}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"35e4a69b2003f20a69e7d19ae96ab1eef1aa8e8d","status":"affected","lessThan":"3025ca5daa9d682b629c0c958b538e41deeb559d","versionType":"git"},{"version":"35e4a69b2003f20a69e7d19ae96ab1eef1aa8e8d","status":"affected","lessThan":"f19d1323aa3dd7ead469aef47d9085f8939565d9","versionType":"git"},{"version":"35e4a69b2003f20a69e7d19ae96ab1eef1aa8e8d","status":"affected","lessThan":"a8d51efb5929ae308895455a3e496b5eca2cd143","versionType":"git"},{"version":"4ddf7293928cb619077724b7d828734da8181e6c","status":"affected","versionType":"git"},{"version":"6.17.8","status":"affected","lessThan":"6.18","versionType":"semver"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["kernel/power/main.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.18","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.18","versionType":"semver"},{"version":"6.18.21","status":"unaffected","lessThanOrEqual":"6.18.*","versionType":"semver"},{"version":"6.19.11","status":"unaffected","lessThanOrEqual":"6.19.*","versionType":"semver"},{"version":"7.0","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["kernel/power/main.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/3025ca5daa9d682b629c0c958b538e41deeb559d"},{"url":"https://git.kernel.org/stable/c/f19d1323aa3dd7ead469aef47d9085f8939565d9"},{"url":"https://git.kernel.org/stable/c/a8d51efb5929ae308895455a3e496b5eca2cd143"}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-05-23T16:05:25.080Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.18","versionEndExcluding":"6.18.21"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.18","versionEndExcluding":"6.19.11"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.18","versionEndExcluding":"7.0"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.17.8"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}