summaryrefslogtreecommitdiff
path: root/drivers/spi/spi-bcm2835.c
diff options
context:
space:
mode:
authorMark Brown <broonie@kernel.org>2020-05-20 19:55:07 +0300
committerMark Brown <broonie@kernel.org>2020-05-20 19:55:07 +0300
commitc38a4905caaf78fd7ce8ecece6d3a966933968db (patch)
treeae20ccf59b023dc977a7ff06a960c91d71f0e036 /drivers/spi/spi-bcm2835.c
parent73da2352075adb24868229f9463736a5dd331b95 (diff)
parentb9dd3f6d417258ad0beeb292a1bc74200149f15d (diff)
downloadlinux-c38a4905caaf78fd7ce8ecece6d3a966933968db.tar.xz
Merge branch 'for-5.7' of https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi into spi-5.8
Diffstat (limited to 'drivers/spi/spi-bcm2835.c')
-rw-r--r--drivers/spi/spi-bcm2835.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/spi/spi-bcm2835.c b/drivers/spi/spi-bcm2835.c
index cad3458e23ed..06d2782d38ec 100644
--- a/drivers/spi/spi-bcm2835.c
+++ b/drivers/spi/spi-bcm2835.c
@@ -1351,7 +1351,7 @@ static int bcm2835_spi_probe(struct platform_device *pdev)
goto out_dma_release;
}
- err = devm_spi_register_controller(&pdev->dev, ctlr);
+ err = spi_register_controller(ctlr);
if (err) {
dev_err(&pdev->dev, "could not register SPI controller: %d\n",
err);
@@ -1378,6 +1378,8 @@ static int bcm2835_spi_remove(struct platform_device *pdev)
bcm2835_debugfs_remove(bs);
+ spi_unregister_controller(ctlr);
+
/* Clear FIFOs, and disable the HW block */
bcm2835_wr(bs, BCM2835_SPI_CS,
BCM2835_SPI_CS_CLEAR_RX | BCM2835_SPI_CS_CLEAR_TX);