Message ID | 20241030174132.2113286-2-andriy.shevchenko@linux.intel.com |
---|---|
State | Superseded |
Headers | show |
Series | gpio: Check for error from devm_mutex_init() | expand |
diff --git a/drivers/gpio/gpio-mpsse.c b/drivers/gpio/gpio-mpsse.c index 3ab6651d2226..9ef24449126a 100644 --- a/drivers/gpio/gpio-mpsse.c +++ b/drivers/gpio/gpio-mpsse.c @@ -430,8 +430,13 @@ static int gpio_mpsse_probe(struct usb_interface *interface, if (err) return err; - devm_mutex_init(dev, &priv->io_mutex); - devm_mutex_init(dev, &priv->irq_mutex); + err = devm_mutex_init(dev, &priv->io_mutex); + if (err) + return err; + + err = devm_mutex_init(dev, &priv->irq_mutex); + if (err) + return err; priv->gpio.label = devm_kasprintf(dev, GFP_KERNEL, "gpio-mpsse.%d.%d",