Import Source
https://github.com/microsoft/AzureLinuxVulnerabilityData/blob/main/osv/AZL-71350.json
JSON Data
https://api.osv.dev/v1/vulns/AZL-71350
Upstream
Published
2025-09-15T15:15:41Z
Modified
2026-04-21T04:36:34.292036Z
Summary
CVE-2022-50304 affecting package kernel 5.15.200.1-1
Details

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

mtd: core: fix possible resource leak in init_mtd()

I got the error report while inject fault in init_mtd():

sysfs: cannot create duplicate filename '/devices/virtual/bdi/mtd-0' Call Trace: <TASK> dumpstacklvl+0x67/0x83 sysfswarndup+0x60/0x70 sysfscreatedirns+0x109/0x120 kobjectaddinternal+0xce/0x2f0 kobjectadd+0x98/0x110 deviceadd+0x179/0xc00 devicecreategroupsvargs+0xf4/0x100 devicecreate+0x7b/0xb0 bdiregisterva.part.13+0x58/0x2d0 bdiregister+0x9b/0xb0 initmtd+0x62/0x171 [mtd] dooneinitcall+0x6c/0x3c0 doinitmodule+0x58/0x222 loadmodule+0x268e/0x27d0 _dosysfinitmodule+0xd5/0x140 dosyscall64+0x37/0x90 entrySYSCALL64afterhwframe+0x63/0xcd </TASK> kobjectaddinternal failed for mtd-0 with -EEXIST, don't try to register things with the same name in the same directory. Error registering mtd class or bdi: -17

If initmtdchar() fails in initmtd(), mtdbdi will not be unregistered, as a result, we can't load the mtd module again, to fix this by calling bdiunregister(mtdbdi) after outprocfs label.

References

Affected packages

Azure Linux:2 / kernel

Package

Name
kernel
Purl
pkg:rpm/azure-linux/kernel

Affected ranges

Type
ECOSYSTEM
Events
Introduced
0Unknown introduced version / All previous versions are affected
Last affected
5.15.200.1-1

Database specific

source
"https://github.com/microsoft/AzureLinuxVulnerabilityData/blob/main/osv/AZL-71350.json"