Re: [PATCH v6 1/3] spi: spi-nxp-fspi: check return value of devm_mutex_init()

From: Mark Brown
Date: Tue Jun 10 2025 - 07:46:28 EST


On Tue, Jun 10, 2025 at 12:57:37PM +0300, Andy Shevchenko wrote:
> On Mon, Jun 09, 2025 at 09:59:46PM +0100, Mark Brown wrote:

> > I don't understand the comment about leaking here? We might end up with
> > an unitialised mutex but how would we leak anything?

> In case if the mutex_init() allocates something that needs to be freed
> (in the future).

I don't see how checking the return value impacts that? The management
via devm is still there either way.

Attachment: signature.asc
Description: PGP signature