In the Linux kernel, the following vulnerability has been resolved:
rapidio: fix possible name leaks when rioadddevice() fails
Patch series "rapidio: fix three possible memory leaks".
This patchset fixes three name leaks in error handling. - patch #1 fixes two name leaks while rioadddevice() fails. - patch #2 fixes a name leak while rioregistermport() fails.
This patch (of 2):
If rioadddevice() returns error, the name allocated by devsetname() need be freed. It should use putdevice() to give up the reference in the error path, so that the name can be freed in kobjectcleanup(), and the 'rdev' can be freed in rioreleasedev().