[PATCH v2] bus: fsl-mc: fix an error handling in fsl_mc_device_add()

Haoxiang Li lihaoxiang at isrc.iscas.ac.cn
Fri Jan 23 22:35:29 AEDT 2026


Hi, Ioana:

On Fri, 23 Jan 2026 13:10:46 +0200, Ioana Ciornei wrote:
> Is there any reason why you didn't go with Christophe's suggestion from
> https://lore.kernel.org/all/b7f7e968-a683-4e1e-8ccc-5dd19f0f15c5@kernel.org/ ?

> It's perfectly valid to call put_device() even though device_add() was
> not called, meaning from the other code paths.

Actually, I totally agree with that suggestion. However, I submit a same fix
several months ago and got a reply:
https://lore.kernel.org/all/2025052622-nautical-suitably-486c@gregkh/

I didn't figure out why. And if you agree with the Christophe's suggestion,
I will resubmit a patch v3.

Thanks,
Haoxiang Li 



More information about the Linuxppc-dev mailing list