Skip to content

Commit a8a3136

Browse files
tititiou36broonie
authored andcommitted
spi: mpfs: Fix an error handling path in mpfs_spi_probe()
mpfs_spi_init() calls mpfs_spi_enable_ints(), so mpfs_spi_disable_ints() should be called if an error occurs after calling mpfs_spi_init(), as already done in the remove function. Fixes: 9ac8d17 ("spi: add support for microchip fpga spi controllers") Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr> Link: https://patch.msgid.link/eb35f168517cc402ef7e78f26da02863e2f45c03.1765612110.git.christophe.jaillet@wanadoo.fr Signed-off-by: Mark Brown <broonie@kernel.org>
1 parent 8f0b4cc commit a8a3136

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

drivers/spi/spi-mpfs.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -577,6 +577,7 @@ static int mpfs_spi_probe(struct platform_device *pdev)
577577

578578
ret = devm_spi_register_controller(&pdev->dev, host);
579579
if (ret) {
580+
mpfs_spi_disable_ints(spi);
580581
mpfs_spi_disable(spi);
581582
return dev_err_probe(&pdev->dev, ret,
582583
"unable to register host for SPI controller\n");

0 commit comments

Comments
 (0)