diff options
author | Mark Brown <broonie@kernel.org> | 2020-05-30 02:03:51 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2020-05-30 02:03:51 +0300 |
commit | 0c0c5b8fabe596a7322f0b9b93b88f489b3f4bb3 (patch) | |
tree | b137f835d2b336cbb68977ca16169b8f1ed14286 /drivers/spi/spi.c | |
parent | 9cb1fd0efd195590b828b9b865421ad345a4a145 (diff) | |
parent | 65e318e17358a3fd4fcb5a69d89b14016dee2f06 (diff) | |
download | linux-0c0c5b8fabe596a7322f0b9b93b88f489b3f4bb3.tar.xz |
Merge remote-tracking branch 'spi/for-5.7' into spi-linus
Diffstat (limited to 'drivers/spi/spi.c')
-rw-r--r-- | drivers/spi/spi.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/spi/spi.c b/drivers/spi/spi.c index c92c89467e7e..299384c91917 100644 --- a/drivers/spi/spi.c +++ b/drivers/spi/spi.c @@ -2111,6 +2111,7 @@ static int acpi_spi_add_resource(struct acpi_resource *ares, void *data) } lookup->max_speed_hz = sb->connection_speed; + lookup->bits_per_word = sb->data_bit_length; if (sb->clock_phase == ACPI_SPI_SECOND_PHASE) lookup->mode |= SPI_CPHA; @@ -2760,6 +2761,8 @@ void spi_unregister_controller(struct spi_controller *ctlr) struct spi_controller *found; int id = ctlr->bus_num; + device_for_each_child(&ctlr->dev, NULL, __unregister); + /* First make sure that this controller was ever added */ mutex_lock(&board_lock); found = idr_find(&spi_master_idr, id); @@ -2772,7 +2775,6 @@ void spi_unregister_controller(struct spi_controller *ctlr) list_del(&ctlr->list); mutex_unlock(&board_lock); - device_for_each_child(&ctlr->dev, NULL, __unregister); device_unregister(&ctlr->dev); /* free bus id */ mutex_lock(&board_lock); |