Re: [PATCH v2] nvdimm/pmem: Fix leak on dax_add_host() failure

2024-02-16 Thread Mathieu Desnoyers
On 2024-02-15 09:43, Mathieu Desnoyers wrote: Fix a leak on dax_add_host() error, where "goto out_cleanup_dax" is done before setting pmem->dax_dev, which therefore issues the two following calls on NULL pointers: Hi Andrew, I notice that you should update the patch you have in your tree

[PATCH v2] nvdimm/pmem: Fix leak on dax_add_host() failure

2024-02-15 Thread Mathieu Desnoyers
Fix a leak on dax_add_host() error, where "goto out_cleanup_dax" is done before setting pmem->dax_dev, which therefore issues the two following calls on NULL pointers: out_cleanup_dax: kill_dax(pmem->dax_dev); put_dax(pmem->dax_dev); Signed-off-by: Mathieu Desnoyers Reviewed-by: