In the Linux kernel, the following vulnerability has been resolved:
mISDN: fix possible memory leak in mISDNregisterdevice()
Afer commit 1fa5ae857bb1 ("driver core: get rid of struct device's busid string array"), the name of device is allocated dynamically, add putdevice() to give up the reference, so that the name can be freed in kobject_cleanup() when the refcount is 0.
Set device class before putdevice() to avoid null release() function WARN message in devicerelease().