mirror of
https://github.com/torvalds/linux.git
synced 2026-09-28 20:12:01 +02:00
iio: dac: ltc2664: Use devm_mutex_init()
Use devm_mutex_init() which is helpful with CONFIG_DEBUG_MUTEXES. Signed-off-by: David Carlier <devnexen@gmail.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
This commit is contained in:
parent
81227f33a8
commit
be186094ee
|
|
@ -675,7 +675,9 @@ static int ltc2664_probe(struct spi_device *spi)
|
|||
|
||||
st->chip_info = chip_info;
|
||||
|
||||
mutex_init(&st->lock);
|
||||
ret = devm_mutex_init(dev, &st->lock);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
st->regmap = devm_regmap_init_spi(spi, <c2664_regmap_config);
|
||||
if (IS_ERR(st->regmap))
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user