Messages in this thread | | | Date | Thu, 17 Aug 2023 08:06:15 -0700 | From | Dan Williams <> | Subject | RE: [PATCH] drivers: nvdimm: fix memleak |
| |
[ add Kajol and Madhavan ]
Konstantin Meskhidze wrote: > Memory pointed by 'nd_pmu->pmu.attr_groups' is allocated in function > 'register_nvdimm_pmu' and is lost after 'kfree(nd_pmu)' call in function > 'unregister_nvdimm_pmu'.
Yes, looks like a real issue, but also completely avoidable by using statically defined groups.
My fault for not catching this earlier, but Kajol, why is nd_perf not using statically defined sysfs attribute groups?
| |