From: Mark Brown Date: Thu, 14 Oct 2021 13:15:46 +0000 (+0100) Subject: Merge branch 'spi-5.15' into spi-5.16 X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=531558b56be514f7e98b9ea2997b6197ee1af360;p=linux.git Merge branch 'spi-5.15' into spi-5.16 --- 531558b56be514f7e98b9ea2997b6197ee1af360 diff --cc drivers/spi/spi.c index 50591de16e0f5,926b68aa45d3e..72826bdab2704 --- a/drivers/spi/spi.c +++ b/drivers/spi/spi.c @@@ -635,11 -626,16 +629,11 @@@ static int spi_add_device(struct spi_de /* Set the bus ID string */ spi_dev_set_name(spi); - mutex_lock(&spi_add_lock); - /* We need to make sure there's no other device with this - * chipselect **BEFORE** we call setup(), else we'll trash - * its configuration. Lock against concurrent add() calls. - */ + mutex_lock(&ctlr->add_lock); status = __spi_add_device(spi); - mutex_unlock(&spi_add_lock); + mutex_unlock(&ctlr->add_lock); return status; } -EXPORT_SYMBOL_GPL(spi_add_device); static int spi_add_device_locked(struct spi_device *spi) {