Unverified Commit 21ea2743 authored by Pan Bian's avatar Pan Bian Committed by Mark Brown
Browse files

spi: atmel: Put allocated master before return



The allocated master is not released. Goto error handling label rather
than directly return.

Fixes: 5e9af37e ("spi: atmel: introduce probe deferring")
Signed-off-by: default avatarPan Bian <bianpan2016@163.com>
Fixes: 5e9af37e ("spi: atmel: introduce probe deferring")
Reviewed-by: default avatarTudor Ambarus <tudor.ambarus@microchip.com>
Link: https://lore.kernel.org/r/20210120050025.25426-1-bianpan2016@163.com


Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent 258ea99f
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1590,7 +1590,7 @@ static int atmel_spi_probe(struct platform_device *pdev)
		if (ret == 0) {
			as->use_dma = true;
		} else if (ret == -EPROBE_DEFER) {
			return ret;
			goto out_unmap_regs;
		}
	} else if (as->caps.has_pdc_support) {
		as->use_pdc = true;