Thread (19 messages) 19 messages, 4 authors, 2026-01-23

Re: [PATCH v3 2/5] i2c: xiic: switch to managed version of mutex_init

From: Andy Shevchenko <hidden>
Date: 2026-01-23 08:30:11
Also in: linux-i2c, lkml

On Fri, Jan 23, 2026 at 08:02:45AM +0000, Abdurrahman Hussain via B4 Relay wrote:
Simplify the error path by switching to a managed version of mutex_init.
...
-	mutex_init(&i2c->lock);
+	ret = devm_mutex_init(&pdev->dev, &i2c->lock);
+	if (ret < 0)
+		return ret;
Should use 'dev' instead (see comment on the patches 1 and 5).

-- 
With Best Regards,
Andy Shevchenko


Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help