Re: [PATCH] misc: tps6594-pfsm: Add NULL check in tps6594_pfsm_probe
From: Arnd Bergmann
Date: Thu Apr 10 2025 - 06:56:36 EST
On Thu, Apr 10, 2025, at 12:52, Charles Han wrote:
> + if (!pfsm->miscdev.name) {
> + devm_kfree(dev, pfsm);
> + return -ENOMEM;
> + }
Since this is the probe function, you don't need to call devm_kfree()
but just let devres take care of it.
Arnd