{"id":"CVE-2022-50712","state":"PUBLISHED","title":"devlink: hold region lock when flushing snapshots","description":"In the Linux kernel, the following vulnerability has been resolved:\n\ndevlink: hold region lock when flushing snapshots\n\nNetdevsim triggers a splat on reload, when it destroys regions\nwith snapshots pending:\n\n  WARNING: CPU: 1 PID: 787 at net/core/devlink.c:6291 devlink_region_snapshot_del+0x12e/0x140\n  CPU: 1 PID: 787 Comm: devlink Not tainted 6.1.0-07460-g7ae9888d6e1c #580\n  RIP: 0010:devlink_region_snapshot_del+0x12e/0x140\n  Call Trace:\n   <TASK>\n   devl_region_destroy+0x70/0x140\n   nsim_dev_reload_down+0x2f/0x60 [netdevsim]\n   devlink_reload+0x1f7/0x360\n   devlink_nl_cmd_reload+0x6ce/0x860\n   genl_family_rcv_msg_doit.isra.0+0x145/0x1c0\n\nThis is the locking assert in devlink_region_snapshot_del(),\nwe're supposed to be holding the region->snapshot_lock here.","publishedAt":"2025-12-24T12:22:37.676Z","updatedAt":"2026-05-11T19:24:03.573Z","severity":null,"assigner":"Linux","products":["Linux Linux"],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"2dec18ad826f52658f7781ee995d236cc449b678","status":"affected","lessThan":"49383d4e59bb704341aaa1d51440ccce58270e61","versionType":"git"},{"version":"2dec18ad826f52658f7781ee995d236cc449b678","status":"affected","lessThan":"6298cab4d80bfdb6fe01fe31fd9f0ba26317fdae","versionType":"git"},{"version":"2dec18ad826f52658f7781ee995d236cc449b678","status":"affected","lessThan":"b4cafb3d2c740f8d1b1234b43ac4a60e5291c960","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/core/devlink.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.0","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.0","versionType":"semver"},{"version":"6.0.16","status":"unaffected","lessThanOrEqual":"6.0.*","versionType":"semver"},{"version":"6.1.2","status":"unaffected","lessThanOrEqual":"6.1.*","versionType":"semver"},{"version":"6.2","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/core/devlink.c"]}],"references":["https://git.kernel.org/stable/c/49383d4e59bb704341aaa1d51440ccce58270e61","https://git.kernel.org/stable/c/6298cab4d80bfdb6fe01fe31fd9f0ba26317fdae","https://git.kernel.org/stable/c/b4cafb3d2c740f8d1b1234b43ac4a60e5291c960"],"weaknesses":[],"ingestedAt":"2026-10-29T20:05:26.763Z","source":{"repository":"CVEProject/cvelistV5","path":"cves/2022/50xxx/CVE-2022-50712.json","commit":"556c9d3a8cd17e218bb8e452ba7cd619a384ff47"},"raw":{"dataType":"CVE_RECORD","dataVersion":"5.2","cveMetadata":{"cveId":"CVE-2022-50712","state":"PUBLISHED","datePublished":"2025-12-24T12:22:37.676Z","dateUpdated":"2026-05-11T19:24:03.573Z","assignerShortName":"Linux","assignerOrgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateReserved":"2025-12-24T12:20:40.328Z"},"containers":{"cna":{"title":"devlink: hold region lock when flushing snapshots","descriptions":[{"lang":"en","value":"In the Linux kernel, the following vulnerability has been resolved:\n\ndevlink: hold region lock when flushing snapshots\n\nNetdevsim triggers a splat on reload, when it destroys regions\nwith snapshots pending:\n\n  WARNING: CPU: 1 PID: 787 at net/core/devlink.c:6291 devlink_region_snapshot_del+0x12e/0x140\n  CPU: 1 PID: 787 Comm: devlink Not tainted 6.1.0-07460-g7ae9888d6e1c #580\n  RIP: 0010:devlink_region_snapshot_del+0x12e/0x140\n  Call Trace:\n   <TASK>\n   devl_region_destroy+0x70/0x140\n   nsim_dev_reload_down+0x2f/0x60 [netdevsim]\n   devlink_reload+0x1f7/0x360\n   devlink_nl_cmd_reload+0x6ce/0x860\n   genl_family_rcv_msg_doit.isra.0+0x145/0x1c0\n\nThis is the locking assert in devlink_region_snapshot_del(),\nwe're supposed to be holding the region->snapshot_lock here."}],"affected":[{"vendor":"Linux","product":"Linux","defaultStatus":"unaffected","versions":[{"version":"2dec18ad826f52658f7781ee995d236cc449b678","status":"affected","lessThan":"49383d4e59bb704341aaa1d51440ccce58270e61","versionType":"git"},{"version":"2dec18ad826f52658f7781ee995d236cc449b678","status":"affected","lessThan":"6298cab4d80bfdb6fe01fe31fd9f0ba26317fdae","versionType":"git"},{"version":"2dec18ad826f52658f7781ee995d236cc449b678","status":"affected","lessThan":"b4cafb3d2c740f8d1b1234b43ac4a60e5291c960","versionType":"git"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/core/devlink.c"]},{"vendor":"Linux","product":"Linux","defaultStatus":"affected","versions":[{"version":"6.0","status":"affected"},{"version":"0","status":"unaffected","lessThan":"6.0","versionType":"semver"},{"version":"6.0.16","status":"unaffected","lessThanOrEqual":"6.0.*","versionType":"semver"},{"version":"6.1.2","status":"unaffected","lessThanOrEqual":"6.1.*","versionType":"semver"},{"version":"6.2","status":"unaffected","lessThanOrEqual":"*","versionType":"original_commit_for_fix"}],"repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","programFiles":["net/core/devlink.c"]}],"references":[{"url":"https://git.kernel.org/stable/c/49383d4e59bb704341aaa1d51440ccce58270e61"},{"url":"https://git.kernel.org/stable/c/6298cab4d80bfdb6fe01fe31fd9f0ba26317fdae"},{"url":"https://git.kernel.org/stable/c/b4cafb3d2c740f8d1b1234b43ac4a60e5291c960"}],"providerMetadata":{"shortName":"Linux","orgId":"416baaa9-dc9f-4396-8d5f-8c081fb06d67","dateUpdated":"2026-05-11T19:24:03.573Z"},"cpeApplicability":[{"nodes":[{"operator":"OR","negate":false,"cpeMatch":[{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.0","versionEndExcluding":"6.0.16"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.0","versionEndExcluding":"6.1.2"},{"vulnerable":true,"criteria":"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*","versionStartIncluding":"6.0","versionEndExcluding":"6.2"}]}]}],"x_generator":{"engine":"bippy-1.2.0"}}}}}