Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f885135a authored by Wei Yongjun's avatar Wei Yongjun Committed by Mark Brown
Browse files

spi: coldfire-qspi: remove redundant return value check of platform_get_resource()



Remove unneeded error handling on the result of a call
to platform_get_resource() when the value is passed to
devm_ioremap_resource().

Signed-off-by: default avatarWei Yongjun <yongjun_wei@trendmicro.com.cn>
Signed-off-by: default avatarMark Brown <broonie@linaro.org>
parent 9a3ced19
Loading
Loading
Loading
Loading
+0 −6
Original line number Diff line number Diff line
@@ -397,12 +397,6 @@ static int mcfqspi_probe(struct platform_device *pdev)
	mcfqspi = spi_master_get_devdata(master);

	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
	if (!res) {
		dev_dbg(&pdev->dev, "platform_get_resource failed\n");
		status = -ENXIO;
		goto fail0;
	}

	mcfqspi->iobase = devm_ioremap_resource(&pdev->dev, res);
	if (IS_ERR(mcfqspi->iobase)) {
		status = PTR_ERR(mcfqspi->iobase);